Server Setup Guide

The TeamTalk 4 Server is available for both Windows and Linux. The server executables are located in the 'Server' sub-directory of the SDK. On Windows the server comes as both a console program (tt4srv.exe or tt4prosrv.exe) and an NT service (tt4svc.exe or tt4prosvc.exe). The Linux server (teamtalkd or teamtalkprod) can run as both a regular program and as a daemon.

This section outlines the following:

Configurating the TeamTalk Server

The TeamTalk server reads its configuration from an XML file, typically tt4svc.xml. This file can be edited manually (using an UTF-8 aware editor) or one can choose to use the -wizard option to the server executable.

Below is an example a server's configuration file:

<?xml version="1.0" encoding="UTF-8" ?>
<teamtalk version="4.0">
    <general>
        <server-name>TeamTalk Server</server-name>
        <motd>My login message to users</motd>
        <max-users>1000</max-users>
        <auto-save>true</auto-save>
        <bind-ip></bind-ip>
        <tcpport>10333</tcpport>
        <udpport>10333</udpport>
        <server-password></server-password>
        <server-log-maxsize>-1</server-log-maxsize>
        <login-attempts>10</login-attempts>
        <file-storage>
            <files-root>c:\temp</files-root>
            <max-diskusage>51200000</max-diskusage>
            <channel-diskquota>5120000</channel-diskquota>
        </file-storage>
        <user-rights>
            <channel-creation>true</channel-creation>
            <channel-operators>true</channel-operators>
            <channel-commands>true</channel-commands>
            <modify-subscriptions>true</modify-subscriptions>
            <client-broadcast>false</client-broadcast>
            <view-all-users>true</view-all-users>
            <guest-login>true</guest-login>
            <double-login>true</double-login>
            <forward-audio>true</forward-audio>
            <forward-video>true</forward-video>
        </user-rights>
        <bandwidth-limits>
            <audiocodec-bps-limit>0</audiocodec-bps-limit>
            <audiotx-limit>0</audiotx-limit>
            <videotx-limit>0</videotx-limit>
            <totaltx-limit>0</totaltx-limit>
        </bandwidth-limits>
    </general>
    <users>
        <user>
            <username>admin</username>
            <password>mypasswd</password>
            <user-type>2</user-type>
        </user>
    </users>
    <serverbans>
        <serverban address="192.168.11.44">
            <bantime>2009/10/12 12:48</bantime>
            <nickname>Benjamin</nickname>
            <username>ben</username>
            <channel-path>/Conf ABC</channel-path>
        </serverban>
    </serverbans>
</teamtalk>

Here is an explanation of each of the tags in the server configuration file:

Starting a TeamTalk Server

Try running the server executable to get an overview of the possible ways to run the server. Note that running the NT service will not give any output since an NT service doesn't have a user-interface. Also note the NT service must be run using the Windows Administrator account.

When running the server executable the following output will appear:

bdr@debian:~/projects/tt4srv$ ./teamtalkd

TeamTalk Server version 4.2.0.1479
Compiled on Oct 23 2011 22:40:14.

Copyright (c) 2002-2010, BearWare.dk

Usage: ./teamtalkd [OPTIONS]

Valid options:
  -d               Start TeamTalk Server as daemon.
  -daemon-pid      Print PID of daemon started with -d option.
  -nd              Start TeamTalk Server as non-daemon.
  -wizard          Run the setup-wizard to configure the server.
  -c [FILE]        Instead of loading tt4svc.xml from current directory
                   use this specified file.
  -wd [DIR]        Set working directory (where tt4svc.xml
                   is located and where the log file tt4svc.log
                   will be stored).
                   Current directory is the default location of 
                   tt4svc.xml and log file.
  -tcpport [PORT]  Override the <tcpport> setting in tt4svc.xml.
  -udpport [PORT]  Override the <udpport> setting in tt4svc.xml.
  -ip [IPADDR]     Override <bind-ip> setting in tt4svc.xml.
  -verbose         Output log information to console.
  --version        Displays version info.
  --help           Displays this message.

Examples: ./teamtalkd -nd
          ./teamtalkd -wd /home/bill/srv1 -ip 192.168.0.2 -nd
          ./teamtalkd -c /home/bill/srv1/tt4svc.xml -nd

Kind regards go to the people behind the ACE Framework, Speex, CELT
and Theora projects!

Report bugs to contact@bearware.dk

Here is an explanation of each of the options.

The NT service has additional options which are explained in the following section.

Installing the TeamTalk 4 NT Service

In addition to the options described in section Starting a TeamTalk Server the NT Service (tt4svc.exe or tt4prosvc.exe) also accepts the following parameters:

Note the above commands must be run using the Windows Administrator account. Right-click C:\Windows\system32\cmd.exe and choose "Run as Administrator".

Installing multiple NT Services

To install multiple TeamTalk 4 NT Services the sc.exe command can be used. Here is an example:

sc.exe create "TeamTalk Server 2" binPath= "C:\MyServer\tt4svc.exe -wd c:\MyServer" start= auto

The service in the above example will be called "TeamTalk Server 2" in the NT service list. Notice the spaces after binPath and start. For some strange reason these are required. To start the above service run:

sc.exe start "TeamTalk Server 2"

To stop it type:

sc.exe stop "TeamTalk Server 2"

To uninstall it type:

sc.exe delete "TeamTalk Server 2"

TeamTalk 4 PHP Admin for remote administration

The 'Server' sub-directory also contains a PHP script named tt4admin.php which can be used for remote administation of a TeamTalk server. The TeamTalk 4 PHP Admin must be executed in a console.

Here's an example of logging into a server and the available options:

C:\Projects\TT4PHPAdmin>php tt4admin.php
TeamTalk 4 PHP Admin!
Supports TeamTalk 4 protocol 4.2

Copyright (c) 2005-2010, BearWare.dk

This is a console application so don't put it on a webserver.
Type IP-address of TeamTalk server (prefix 'tls://' in TT4Pro): teamtalk.dyndns.dk
Type TCP port number of TeamTalk server: 10333
Connecting...
Connected!
Got user ID# 304
Server name is: TeamTalk Server
Your session will time out in 60 seconds
Type account username: admin
Type account password: ********
Type server password:

Logging in...
Log in successful!
Server updated...
Server name is: TeamTalk Server
Server password is:
Max users on server: 1000
User timeout: 60 seconds
Server's MOTD is: Please sign up for the newsletter on http://www.bearware.dk to
 get the latest updates.

If you would like to help out translating TeamTalk 4 to your language then pleas
e send an email to contact@bearware.dk.

Enjoy your stay!

What do you want to do now?
---------------------------- USERS -----------------------------
 1. List online users
 2. Kick user
 3. Move user
 4. Op/deop user
 5. List banned users
 6. Ban user
 7. Unban user
 8. Send text message to user
--------------------------- CHANNELS ---------------------------
10. List active channels
11. Create channel
12. Update channel
13. Delete channel
14. Send text message to channel
------------------------ USER ACCOUNTS -------------------------
20. List user accounts
21. Create user account
22. Delete user account
--------------------------- SERVER -----------------------------
30. Change server name
31. Change server password
32. Change maximum number of users
33. Change message of the day
34. Send text message to all users on server
35. Save server changes
36. Query server statistics
--------------------------- SESSION ----------------------------
50. Issue ping (extend session time)
51. Exit

Type option ID: 
Generated on Sun Mar 18 17:18:32 2012 for TeamTalk 4 C-API DLL by  doxygen 1.6.3