NAME

autonap.conf - config file for AutoNap.pl


DESCRIPTION

The autonap.conf is the central file which AutoNap will get most of its options from. It is not strictly necessary when you run AutoNap in interactive mode (that is, running it without the -a switch) in which case you can hand all relevant parameters to AutoNap via command line.

It is, however, necessary to set one up if you want to use AutoNap's non-interacting mode.


SYNTAX

The syntax is as basic as imaginable. Generally speaking you have key/value pairs in this file with predefined keys and certain rules how the values may look depending on each key. Each key/value pair is supposed to be on a single line and split with a '=' without any whitespaces in between, in the form key=value

There is one other directive you need to give in the file, namely the name of the section enclosed in square brackets. See KEYS AND SECTIONS for a list of all supported items and their description.


KEYS AND SECTIONS

Currently, autonap.conf can have up to four different sections: account, misc, random and auto. Variables of each section have the section's abbreviated (or not) name prefixed to it split by an underline. The beginning of a common autonap.conf file might therefore look like this:


        [account]
        acc_network=MusicCity
        acc_user=foo
        ...

SECTION [account]

Valid key-identifiers are:

acc_network: the network you want to log-in (tries any if you don't give one)

acc_user: your username

acc_pass: your password

acc_download_dir: location where AutoNap's downloads will go to

None of these are mandatory. When leaving out any or all of the above options, AutoNap will set some reasonable defaults. The download-directory would, for instance, then be /tmp.

SECTION [misc]

Not yet much in here:

misc_player: your preferred mp3 player in case you do streaming, you might need to specify further command line switches depending on which player your prefer. Default player is mpg123 which usually doesn't need any (at least not for me).

SECTION [random]

These variables are currently not used but internally more or less already implemented. They'll come to live quite soon:

rnd: toggles whether you want to use random searches and downloads at all

rnd_exclude_patterns: on the inside, AutoNap fills a huge array with expressions that are likely to produce rather unpredictable search results. But in order to make sure that none of these match a song or artist you definitely do not want, then you can try to filter these out. E.g.: if you detest anything from britney spears and, say, you already have 'back for good' from Take That (or you detest it as well;-), say:

rnd_exclude_pattern=britney::spears::take that +back +for +good

You see, a ``::'' relates to a logical OR while a '+' inside one of these pseudo-OR statements means an AND. AND NOT can be done with '-'. Technically speaking, both the '+' and '-' are part of the Napster-protocol which means you can also specify these when doing searches in the interactive mode as well as you can use them in any Napster/OpenNap client. It is a little bit different with ``::''. OR does not really exist on the server-side so using these in interactive mode is equal to making two separate searches. Due to this, it is not supported in interactive mode. In non-interactive mode, however, you can give as many ``::'' as you want . See the notes on auto_pattern in the next section.

SECTION [auto]

All of the following keys/values have an effect on how AutoNao will behave. So you should have a closer look at these. This is particularly important as some values may not work very well with slow connections:

auto_ping: Here we go, that's one of those you should use with care. When you set auto_ping=yes, AutoNap will ping each owner of each song measuring the time it takes to receive a reply. Even though this may appear to be useful, it slows down the whole procedure significantly. A Napster-ping is something totally different than pinging a remote host with the UNIX-ping. Replies usually take between three and five seconds. When search returned 50ish results, pinging will probably take more than two minutes on a modem-machine. Furthermore, it appears to me that these pings do not really elude much on the matter of reliability of downloads. I had it quite often that some of the remote parties had wonderfully quick ping replies, nevertheless the download either timed out or did not even initiate.

auto_max_downloads: Set auto_max_downloads=0 if you don't want any restrictions. All it does is keeping track of how many downloads have been made so far (only counting succesful ones) and exiting when the herewith specified limit has been reached.

auto_max_simultan: Unless you have a very good reason to set this one to anything different from 1, you should leave it at its default value. Whether making two parallel downloads or one after another usually takes the same time while there is a higher danger than one of the downloads times out when doing multiple at a time. Setting it to a higher value, though, can actually make sense when you have a luxury T1- or T3-connection because then the above statement about duration of downloads no longer necessarily applies. ;-)

auto_timeout: Experiment with this value and try to adjust it to your connection. When you set it too low (that is, less than 10) downloads may easily break because an inactivity of 10 seconds does happen quite frequently. Start with a value of 30 and see whether it fits your needs.

auto_pattern: The basic parameter controlling what to search and download. Patterns are in the form described above under rnd_exclude_patterns. But whereas random_exclude_patterns only filters the results of a single search, multiple patterns here will results in multiple searches. Consider the following combination of options:


        auto_ping=yes
        auto_pattern=spears::backstreet::beatles

On generic Napster-servers you will get the maximum number of hits (probably), that is 300. So, three lengthy searches are made and three hundred song owner's are pinged. It may well take over half an hour. It is even worse on servers that do not limit search hits to 100 such as some MusicCity servers do (I once had more than 700 hits when doing a search for beatles with a minimum linespeed of T1!). So, be specific with your patterns and use the '+' and '-' modifiers as much as possible.

auto_bitrate: You can set a range of values like auto_bitrate=112-160 which will only retrieve songs being in this range. Be however aware that multiple searches are done as well with the above example. If you want to take the (moderate) risk of perhaps getting a song with a too high bandwidth, just give something like auto_bitrate=112-112. In this case there is only one search performed since both values are the same. It will get songs with 112 kbs and above as internally a ``at least $BITRATE'' is sent to the server. This is far from optimal and will very surely be subject to some changes later.

auto_linespeed: Valid values are UNKOWN (the bottom of the range), 14K, 28K, 33K, 56K, 64K, 128K, CABLE, DSL, T1 and T3. These are also 'at least' and you cannot specify a range here as it probably does not make sense to only want to get songs from people with a linespeed between 128K and DSL. Again, my tests have shown that T1 is probably the value to go for. Anything below may cause trouble.

auto_length: This is supposed to prevent you from getting incomplete songs. So when you search for a song it is unlikely to be the whole song when length is only 30 secons. So specify a range here like auto_length=2:00-4:00


SEE ALSO

The AutoNap.pl(5) manpage

Have a look at the supplied sample autonap.conf that comes in the package and is usually installed into the installer's directory (which then probably will be ~root/).


AUTHOR AND COPYRIGHT

Tassilo von Parseval <Tassilo.Parseval@post.RWTH-Aachen.de>.

Copyright (c) 2001 Tassilo von Parseval. All rights reserved. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License (GPL).