Ventrilo Server Setup Information.
Version 2.0.0
(c)Copyright 1999-2003 Flagship Industries, Inc.
===================================

This document is divided into different sections.

1) Requirements - The basic requirements and general operational information about the server and what is expected before it can run.

2) INI File settings - All of the possible options and parameters in the ventrilo_srv.ini file.

3) USR File settings - Format of predefined user login names and parameters.

4) Server program - How its run and any special options associated with the specific platform version of the server.

5) NT Service program - How to configure and setup the NT Service.

6) Console/RCON commands - Server administration commands.


1) Requirements

The Ventrilo server is designed to be scalable, in that multiple copies of the server can be started on the same machine. Each instance of the Ventrilo server running on the same machine must be assigned a unique TCP/IP port number in it's corresponding INI file.

CPU utilization by the Ventrilo server is negligible so just about any low end machine can be used. However, servers will require better upload and download bandwidth capacities due to the nature of voice communication. The more concurrent clients connected to a server (and in the same channel) the greater the bandwidth utilization.

Note to Server Administrators:

Starting with version 2.0.0 Ventrilo is no longer free. As a consequence of this, once the server is started there is a limited time span in which a client can request Admin rights to the server. After this time has elapsed you will no longer be able to login as a server administrator if you have not purchased a client side registration key. However, you can get back to an administratable state by restarting the server, or the preferred way is to purchase a registration key to make your client fully compliant and functional with no restrictions. The grace period is several hours and should be enough time, including restarts, for you to decide whether or not Ventrilo is worth purchasing.

On this same subject unregistered clients will have limited functionality as well. They should be able to use the full features of the program until a certain elapsed time is reached at which point the client will appear to stop working. This is intentional and not a program bug or error. In order to solve this, and if you have decided to use Ventrilo for all future communications, then you should encourage your users to purchase their own registration keys.

Be advised, duplicate registration keys are not allowed, and since each person needs to purchase their own key they should take all possible measures to assure that the key remains private. Flagship Industries, its partners and associates are not responsible for someone giving out their registration key. See the Client EULA and the Server LICENSE file for complete details regarding this and other licensing issues.


2) INI File settings

The "ventrilo_srv.ini" file has two categories:

Server - General configuration info.
Intf – Accept connections only from specific IP interfaces

Note: Version 1.x of the server had five categories. The Admins, Authenticate and Channels topics have been removed as they are replaced by the automatically generated CHN file and the admin generated USR file.

Each category is contained in [ brackets ] and each option is entered using key=value formatting. This document will use the settings included in the example INI file.

[Server]

Name=Server 1

This is the name of the server that appears at the top of the active user list when someone connects. (Required)

Comment=Welcome

The comment that appears next to the server's name in the same way that a user can assign a comment to their login names. (Optional)

Port=3784

This is the TCP/IP port number that the server will listen on waiting for clients to connect. If you start multiple instances of the server on the same computer then they must have different INI files with unique TCP port numbers assigned to them. (Required)

Auth=0

This is the authentication mode. (Required)

0 = No authentication and anyone can connect.
1 = Global password authentication.
2 = Specific user/password authentication. See section #3 for further details.

Duplicates=1

Enables or disables duplicate login names. (Required)

0 = Disables duplicates.
1 = Allows duplicate login names.

If disabled and someone logs in with a user name identical to that of a currently connected user, the server will disconnect the first user. This setting should only be used when Auth=2 for sanity reasons but it can be disabled for any Auth mode. Note: When this option is set to 0 it creates problems for clients that had auto-reconnect enabled, however, starting with version 2.0.0 this is nolonger a problem.

AdminPassword=

This is the remote server administration password. Leaving this option blank will disable remote admin logins. This password is used by normal login accounts and they activate a menu option to have admin rights assigned to their login. (Optional)

Password=

This is the global login password for when Auth=1. All users connecting to this server must have this password, otherwise the server will send back an error message saying that they could not be authenticated. (Optional)

MaxClients=32

This option specifies the maximum number of clients that can be connected to the server at the same time. The server has a hard coded maximum limit of 100 clients (as of version 1.03), however, your servers network connection might not be able to handle a large number of simultaneous connections. (Required)

SendBuffer=0

Introduced with version 1.03, this option specifies the size of the TCP outbound buffers to each client. The value is in bytes.

Starting with version 1.05 a value of 0 will force the program to use a default value of 131072 bytes. If you have a smaller value then I recommend setting it to 0 and let the program use its default.

In the servers log file there will be a line starting with "MSG_CONN" when a new client connects. At the end of this line will be two pairs of numbers (A,B) (C,D). The A number is the buffer size as defined by your platform. The B number is the buffer size as reported by the system after the Ventrilo server has changed it. The number could be larger or smaller depending on the platform.

RecvBuffer=0

Introduced with version 1.05, this option specifies the size of the TCP inbound buffers for each client. The value is in bytes.

A value of 0 will force the program to use it's default settings of 131072 bytes per client connection.

In the servers log file there will be a line starting with "MSG_CONN" when a new client connects. At the end of this line will be two pairs of numbers (A,B) (C,D). The C number is the buffer size as defined by your platform. The D number is the buffer size as reported by the system after the Ventrilo server has changed it. The number could be larger or smaller depending on the platform.

Diag=0

0 = Diagnostics off.
1 = Diagnostics on.

Introduced with version 1.03, this option turns on more diagnostic information to be used when troubleshooting problems. However, its mostly for developer use. Starting with version 2.0.0 this option has become almost useless for ordinary users. If you turn it on don't expect much.

LogonTimeout=5

Introduced with version 1.05, this option specifies in seconds how long a client has to logon to the server before it is automatically disconnected. Once logged on the option has no meaning. Prior to version 1.05 the server used a hard coded value of 3 seconds and occasionally clients would be kicked as soon as connected due to latency in TCP setup times.

CloseStd=1

0 = Don't close standard input, output and error handles.
1 = Close standard input, output and error handles.

Introduced with version 1.07, this option instructs the server to close or leave-intact the standard input, output and error file handles when starting in daemon mode. At the time of this writing the Ventrilo server is compiled on RedHat 7.2 systems but there seems to be an incompatibility with closing these standard file handles on RedHat80 systems thus causing the program to crash. Setting this option to 0 will force the program to leave the file handles open and prevent it from crashing on RH80 systems. The only downside to this will be if the program was started in daemon mode via an SSH terminal session. When you "exit" the terminal session it will hang waiting for all file handles in spawned processes to close, and you will be forced to manually kill the SSH terminal program. This doesn't seem to happen with normal xterm, gnome-terminal or telnet sessions. *shrug*

Note: Starting with version 2.0.0 this doesn't seem to be an issue anymore due to changes made to the build process. However, the option remains available in case it is needed in the future.

FilterWave=0

0 = Allow wave file binds to replicate.
1 = Filter out (prevent) wave file binds from replicating.

Introduced with version 1.07, this option enables or disables filtering of wave file binds being replicated to other users.

FilterTTS=0

0 = Allow TTS binds to replicate.
1 = Filter out (prevent) TTS binds from replicating.

Introduced with version 1.07, this option enables or disables filtering of Text-to-speech binds being replicated to other users.

TimeStamp=0

0 = Disable console timestamp's.
1 = Enable console timestamp's.

Introduced with version 1.07, this option enables or disables timestamp's being displayed in console messages. This includes remote consoles.

PingRate=10

Introduced with version 1.07, this option allows the administrator to change the interval at which the server pings the clients. The value is specified in seconds and defaults to 10. Setting to a lower value might be useful for diagnosing problem clients especially when the remote console command "pingtrace" is used.

ExtraBuffer=0

Introduced with version 2.0.0, this option allows the administrator to give each outbound client data stream additional buffer space but it's allocated and controlled by the server instead of relying on the TCP stack implementation. A value of 0 instructs the server to use it's default value of 128K bytes of extra buffer space.

ChanWidth=0

Introduced with version 2.0.0, this option specifies a maximum number of parallel sub-channels that can be created in each channel. It has no effect on root level channels which only server admin's can create. A value of 0 means there is no limit.

ChanDepth=0

Introduced with version 2.0.0, this option specifies the maximum number of nested sub-channels (depth) that can be created. A value of 0 means the server will use it's default max value of 8 nested channels.

ChanClients=0

Introduced with version 2.0.0, this option specifies the maximum number of clients allowed in any channel. A value of 0 means there is no limit to the number of clients per channel.

DisableMaxClients=1

0=Allow remote consoles to change "maxclients" value.
1=Disable (prevent) remote consoles from changing the "maxclients" value.

Introduced with version 2.0.0, this option prevents remote console commands (those type into the chat window when logged in with server admin rights) from dynamically changing the real "maxclients" allowed by the server. However, if the server was started in a non-daemon mode the local console can still change the maxclients.

DisableQuit=1

0=Allow remote consoles to issue the "quit" command.
1=Disable (prevent) remote console from issuing the "quit" command.

Introduced with version 2.0.0, this option prevents remote console commands (those typed into the chat window when logged in with server admin rights) from issuing the "quit" command which would instruct the server to exit the system. However, if the server was started in a non-daemon mode the local console can still issue the quit command.

VoiceCodec=0

Introduced with version 2.0.0, this option tells the server which codec all clients must use. The value is a 0 based index into a list of possible codecs. To see the list of currently supported codec types issue the command "ventrilo_srv -?" and the program will display a table of codecs and their associated formats.

VoiceFormat=1

Introduced with version 2.0.0, this option is the second part of VoiceCodec. Each codec can have one or more possible formats that control the quality and bandwidth usage of the specified codec. To see the list of currently supported codec formats issue the command "ventrilo_srv -?" and the program will display a table of codecs and their associated formats.

SilentLobby=0

0 = Allow replication.
1 = Suppress replication, thus making the lobby silent.

Introduced with version 2.0.0, this option allows or suppresses replication of voice, wave binds and tts binds when the client is in the main lobby.

[Intf]

This section allows for controlling which interfaces the server will accept client connections from. If you do not specify anything in this section then the server will accept client connections from all available interfaces.

Note: Starting with version 2.0.0 the "Count=" key is nolonger needed. The only thing that is required is that each key must be unique but can be anything you want them to be. The following examples use the key name "Intf" followed by a number to make the key unique. The interfaces can now be specified as host names or IP numbers.

Intf1=192.168.0.31

Intf2=external.mydomain.com

Intf3=internal.mydomain.com

Intf4=127.0.0.1

 


3) USR File settings

The "ventrilo_srv.usr" file is used for specifying user login names and other associated details unique to each definition. The users login name must be in brackets like this [Flagship]. Similar to the INI file described above each topic will have the following keys for defining details about each specific user. Using the login names of Flagship and Defiant a USR file might look something like the following.

[Flagship]
UserPassword=test1
ServerAdmin=1

[Defiant]
UserPassword=test2
ServerAdmin=0

WARNING: Using this file can be dangerous because Login and Password information is stored in a clear-text format on the server. Should the computer running the ventrilo server be compromised you will be exposed to potential misuse of server admin facilities and login info. It is strongly recommended that Ventrilo login account names and passwords be completely different from other formal system accounts like system shells, unix systems or windows login accounts. You implement at your own risk. Then again, if your box is compromised you probably have much larger issues to worry about.

By defining a specific user you are reserving that users name as a possible login and requires that the client provide the password that matches the "UserPassword" as shown above. This is the case no matter which Auth mode is being used as defined in the INI file.

If Auth=1 then the passwords shown for each listed user take precedence over the "Password" defined in the INI file.

If Auth=2 then only users defined in this file are allowed to connect to the server.

In the examples above the user Flagship would have server admin rights automatically assigned to him as soon as he connects to the server. Please note the warning above as this option can be dangerous.

At the time of this writing this file is created and edited by hand. Future versions might have external interfaces to automate the process.

Note: Starting with version 2.0.0 all passwords (server admin, global, user, channel and channel admin) are case sensitive. Version 1.x passwords were NOT case sensitive.

 


4) Server program

All servers, no matter which platform, are designed to be run in a console window. However, the UNIX'ish based versions can be started in daemon mode and the Windows NT based versions can be started via a separate Ventrilo Service program.

Starting with version 1.03 there are two different ways to start a server. The original way requires you to change the current working directory before starting the server. A new optional mechanism uses the "-f" command line option to specify the location of the required files without changing the working directory.

General information about starting a server.

When the program starts it will read the contents of the INI file and validate the information for completeness. If any of the configuration information is incorrect the server will automatically terminate. If the server refuses to start after reading the config info you can check the "ventrilo_srv.log" for details.

After starting the server it will record its Process ID, or PID, to a file named "ventrilo_srv.pid" in the current or filename-prefixed directory. This is useful should you need to manually kill a server that is misbehaving, not as if that will ever happen.

To start a server in daemon mode append a "-d" to the command line.

To get command line help and a list of voice codec/format options append the "-?" to the command line.

Method 1: Original and default way.

To start a server you must first change your current working directory to that of the "ventrilo_srv.ini" file that you plan on using.

To start a standalone server, not a service or a daemon, simply execute the appropriate server program for the given platform, assuming the working directory has been set first.

Method 2: Path and filename prefix.

Starting with version 1.03 you can use the "-f" command line option to specify the path and prefix name to be used for all files. This requires that all files use a unique name for each server that is started on the same machine. When used in this mode the server will use the path/prefix immediately following the "-f" parameter and tack on extensions for each of the files to be read or written by the server. At the time of this writing there are 6 different files used by a server. Version 2.0.0 introduced numbers 5 and 6.

1) ventrilo_srv.ini (Read before starting up and required)
2) ventrilo_srv.ban (Read and written but not required)
3) ventrilo_srv.pid (Written once as soon as the server starts).
4) ventrilo_srv.log (Appended to by the server when ever a log message is generated)
5) ventrilo_srv.usr (Read each time a client connects).
6) ventrilo_srv.chn (Read before program starts, updated when channels are added/deleted)

When using the "-f" you don't need to change the working directory but you must provide a path/prefix to be used for reading and writing these files. For example, lets assume you are running the Linux version and have the server installed in the directory "/home/ventrilo" along with all of the necessary files. To start the server with the "-f" option you would simply issue the following command.

/home/ventrilo/ventrilo_srv -f/home/ventrilo/ventrilo_srv

Notice there is no space following the "-f" option. The above line assumes you are using the default file names. Now, lets assume you are running two servers on the same machine. Each server would need to have its own port number assigned to it. Thus, we recommend naming the files by the port numbers. To start both servers using the "-f" option you issue the following commands.

/home/ventrilo/ventrilo_srv -f/home/ventrilo/3784 -d
/
home/ventrilo/ventrilo_srv -f/home/ventrilo/4000 -d

The first server would read/write files using the names: 3784.ini, 3784.ban, 3784.pid, 3784.log, 3784.usr and 3784.chn

While the second server would read/write files using the names: 4000.ini, 4000.ban, 4000.pid, 4000.log, 4000.usr and 4000.chn

The "-d" on those examples will start the servers in daemon mode on UNIX'ish systems.

Linux notes:

If you have an automated system for restarting a Linux based Ventrilo server then you will need to wait about 1 to 2 minutes after the server is stopped and before you restart it. There’s a problem with creating the initial network stream shortly after a server is killed and when a new one is started. Waiting for about 2 minutes should make it work correctly. This seems to be less of a problem starting with version 1.03 because of the architectural change, but it probably wouldn't be a bad idea to continue the delay.

Example startup scripts:

The following script is an example of starting Linux based server(s) from the "/etc/rc.d/rc.local" file when a system is booted. Notice that they are started with the specific user account called "ventrilo" and the process priority is bumped to higher then normal.

# Startup ventrilo servers.

VENPATH=/home/ventrilo
VENBIN=$VENPATH/ventrilo_srv

su ventrilo -c "$VENBIN -f$VENPATH/3784 -d"
su ventrilo -c "$VENBIN -f$VENPATH/4000 -d"

renice -5 `cat $VENPATH/3784.pid`
renice -5 `cat $VENPATH/4000.pid`

Note: Those are GRAVE characters around the `cat ... pid` strings. A.K.A backwards apostrophe.

The "renice" command is used to bump the priority of the daemon process thus preventing it from being starved for CPU time if the same machine is used for running other programs like FTP or WEB servers. The Windows version of the server does this automatically. However, in a *NIX environment only the "root" user is allowed to bump process priority.


5) NT Service program

When running the server on a Windows NT/2000/XP platform you also have the option of executing it as an NT Service that will run in the background and can be started up automatically when the computer is started.

The Ventrilo server doesn’t actually run as a service, instead there is another program called "ventrilo_svc.exe" that is the real service program. This service program is responsible for starting up the "ventrilo_srv.exe" server program after the service is loaded.

One advantage to doing it this way is that the service program will restart the server if an admin shuts it down or if the program were to crash due to a bug.

Another advantage to this technique is that the service program can launch multiple copies of the server with each one running a different port number and configuration or even different versions.

To register the Service program with the Service Control Manager simply open a console window and change directories to where you installed the files. Now type the following command:

ventrilo_svc –i

This will install the service and mark it for automatic startup the next time you reboot your system. After you have completed the following registry configuration options you can issue a “net start ventrilo” in the console window to manually start the Ventrilo service program.

If you want to uninstall the service from your system or want to install a new version, simply perform the following commands in this order.

net stop ventrilo
ventrilo_svc –u

The "–u" option will tell the service program to uninstall it self from the systems Service Control Manager.

In order for the service to function properly you also need to setup a few registry entries that define each of the servers that you want the service program to start. When you issued the “–i” option it also created an example registry entry for a single server under the key:

HKEY_LOCAL_MACHINE\Software\Ventrilo

There should be at least one value and one sub-key created in here. The value is called EXE and points to the full path and filename of the Ventrilo server program. This is the global entry and is used if the individual server sub-key’s don’t specify one.

The sub-key names can be anything you want them to be. At installation time the "–i" option created a single sub-key called Server1. In side this key will be 3 string values.

The WorkDir value is required (if the Prefix value isn't used) for each sub-key and must be unique for each server if you want the service to start multiple instances of the server.

The Prefix value is required (if WorkDir is not specified) and is only used in the unique sub-keys for each server. When this option is set it activates the "-f" command line parameter discussed in section 4 of this document. Do not include the "-f" in the Prefix's value as the service program will automatically tack that on. All you need to do is create this value and give it a fully qualified path and prefix file name. If the Prefix value exists and contains anything other then a blank string then the WorkDir option will be ignored.

You can also specify an EXE value for defining a specific copy of the server to be started up by the service. This is useful if you are running different versions of the Ventrilo server. If an EXE value exists in the sub-key then it takes precedence over the global EXE value higher up. If they are both missing then the service will not start anything.

It's recommended that you name the sub-key’s with the same name that you would assign each server in its "ventrilo_srv.ini" file or possibly by it's port number, however this is not required and you can name the sub-key's what ever you want.

Another feature of the service program is the ability to run in debug mode. This lets you test your registry entries and INI file configurations before starting it as a real service where its harder to diagnose problems. To do this first make sure that the real service is not currently running and then start the "ventrilo_svc.exe" with the following command line.

net stop ventrilo
ventrilo_svc –d

When the service starts in debug mode all of its output will show up in the console window where you typed in the command. It will then start each instance of the servers you have defined in their own console windows. If the service and all servers are happy then they should stay open and running. If not, you can go look at each servers log file for any possible problems. Don’t forget, you can also start the servers manually as mentioned earlier in the document.


6) Console/RCON commands

The following commands can be typed into a servers console window if it was started manually. These same commands can be sent to the server from a remote clients chat window by preceding them with the text "/rcon ". For example "/rcon status". But it does require that the remote client be logged in with the admin rights. The following is a list of all of the console commands and brief descriptions on their meaning and use. Some examples show the < and > around the parmaters. Do not include these characters when typing the command.

auth < 0 | 1 | 2 >

Introduced with version 1.03, allows the authorization mode to be changed dynamically.

banadd <ip> <reason>

Adds an IP address and a reason for the banning to the ban list and ban file.

bandel <ip>

Deletes an IP address from the ban list. Starting with version 1.03 this command will automatically update the ban file.

banlist

This option will display all of the banned IP address, the user name of the IP address, the admin who banned them and a reason why.

clientkick <uid>

Instructs the server to disconnect a user where <uid> is the users connection ID number.

clientstatus <uid>

Introduced with version 1.03, this option will output more detailed information about a specified client.

comment <text>

This option allows the server's comment string to be changed dynamically. The <text> can be anything you want.

diag < 0 | 1 >

Introduced with version 1.03, allows the diagnostic mode to be changed dynamically.

filtertts < 0 | 1 >

Introduced with version 1.07, enables or disables filtering out of TTS binds.

filterwave < 0 | 1 >

Introduced with version 1.07, enables or disables filtering out of wave file binds.

help

Displays the list of possible console commands.

kickall

Introduced with version 1.03, kicks all clients connected to the server. If issued via an "/rcon" command from an admining client, that client is exempted from the kick.

loggrep <lines> <search text>

Introduced with version 1.07, allows the servers log file to be searched for a specific piece of text. If lines is 0 then all matching entries will be displayed, otherwise only the last number of <lines> specified matching the search will be displayed. The search string does NOT support regular expressions and all comparisons are case sensitive.

WARNING: Using this command may cause the server to momentarily interrupt voice communication for all clients depending on the size of the log file. It's also possible that the results will be too long and potentially flood the requesters connection with too much information, thus causing the server to disconnect you. It is probably best that you always specify a number of <lines> to limit the results.

maxclients <#>

Introduced with version 1.03, allows the maxclients value to be changed dynamically.

monitor < 0 | 1 >

This option is only valid when requested from a remote client using the "/rcon" option in the chat window. It instructs the server to send all status and log messages to the client that typed this command. The monitor command is turned on by setting the value to 1, and turned off by a value of 0. Prior to version 1.03 the monitor command was a toggle.

name

Introduced with version 2.0.0, this option will display the server's name and current comment. Usefull for when you start multiple servers on the Linux platform using the "screen" program.

password <newpassword>

Introduced with version 1.03, allows the global login password to be changed dynamically.

pingrate <1..10>

Introduced with version 1.07, allows for changing the interval (specified in seconds) that the server will ping the clients.

pingtrace < -2 | -1 | 0 | 1..n >

Introduced with version 1.07, allows for tracing the ping results as they are reported back from the clients. This option is only valid when issued by remote clients and does not work from the server's console window.

-2 = Display the ping results for those clients that are in the same channel.
-1 = Display the ping results for all clients.
0 = Ping tracing disabled.
1..n = Display the ping results for a specific client (specifies the UID)

quit

Forces the server to shutdown. If the server was started by an NT Service control program then it will be automatically restarted in 10 seconds.

serverstatus

Introduced with version 1.03, output detailed status information about the server and specified interfaces.

status

Displays the user id, channel id, login name and IP address for all of the connected users.

timestamp < 0 | 1 >

Introduced with version 1.07, enables or disables displaying timestamp's on console and remote console server messages.

tts <text>

This option will send out a Text-to-speech message to all users connected to the server, no matter which channel they are currently in. The <text> can be anything you want. This command and the comment command could be very useful if you are hosting a server that is reserved for a specific amount of time and you want to send TTS messages informing the connected users about how much time remains before the server is shutdown.

version

Displays the application version of the server.