Forum

Results 1 to 1 of 1
  1. #1
    Join Date
    August 2017
    Posts
    1

    Install teamspeak 3 server on Debian 8

    Hello,

    A lot of people seem to have trouble setting up a teamspeak 3 server so I wrote a little tutorial to help those people.

    The following list is not (yet) covered by me in this tutorial, maybe I will update this later. For now: Google is your friend.
    TODO:
    • securing ssh connection
    • proper firewall configuration


    For this setup I have a basic Debian 8 on a Virtual Machine with root access over ssh.

    • Step 1: Create a user.

    This will create a user called "teamspeak", that has no password and without being asked for input. (I recommend using a certificate instead of password)
    Code:
    adduser --disabled-password --gecos "" teamspeak
    • Step 2: Create a folder.

    This will create a folder for the teamspeak 3 server and grand rights to the user "teamspeak".
    Code:
    mkdir /opt/teamspeak
    chown teamspeak:teamspeak /opt/teamspeak/
    chmod 0770 /opt/teamspeak/
    • Step 3: Create a service script.

    Create a script to manage the teamspeak 3 server.
    Code:
    vim /etc/systemd/system/teamspeak3server.service
    Press the "insert"-button and enter the following code:
    Code:
    [Unit]
    Description=Teamspeak 3 Server
    
    [Service]
    ExecStart=/opt/teamspeak/ts3server_startscript.sh start
    ExecStop=/opt/teamspeak/ts3server_startscript.sh stop
    PIDFile=/opt/teamspeak/ts3server.pid
    Type=forking
    User=teamspeak
    Group=teamspeak
    
    [Install]
    WantedBy=multi-user.target
    Save and close the file by pressing the "escape"-button and typing:
    Code:
    :wq
    Set proper rights and reload the systemctl daemon.
    Code:
    chmod 664 /etc/systemd/system/teamspeak3server.service
    systemctl daemon-reload
    systemctl enable teamspeak3server.service
    • Step 4: Grant proper rights.

    Grand user "teamspeak" sudo rights to manage the service.
    Code:
    visudo
    Search for and add the following lines:
    Code:
    # Cmnd alias specification
    Cmnd_Alias TEAMSPEAK_CMDS = /bin/systemctl start teamspeak3server, /bin/systemctl stop teamspeak3server, /bin/systemctl restart teamspeak3server, /bin/systemctl status teamspeak3server
    
    # User privilege specification
    teamspeak ALL=NOPASSWD: TEAMSPEAK_CMDS, /sbin/reboot
    Press the following button combination: "Ctrl + X", press the "Y"-button and press the "Enter"-button.

    • Step 5: Setup actual teamspeak 3 server.

    Download and install teamspeak 3 server.

    While in terminal as "root" now login as user "teamspeak" by typing the following:
    Code:
    sudo -iu teamspeak
    Download, unpack, move and remove archive:
    Code:
    wget http://dl.4players.de/ts/releases/3.0.13.8/teamspeak3-server_linux_amd64-3.0.13.8.tar.bz2
    tar xfv teamspeak3-server_linux_amd64-3.0.13.8.tar.bz2
    mv ~/teamspeak3-server_linux_amd64/* /opt/teamspeak/
    rm -rf ~/teamspeak3-server_linux_amd64*
    Now startup your server with the following command, this will generate some important keys that will have to save to a file on the server itself (less secure) or on your pc (recommended):
    Code:
    /opt/teamspeak/ts3server_startscript.sh start
    When you saved the output to file I recommend to reboot the physical server to test the automatic start function, type:
    Code:
    sudo reboot
    After this you can manage the "teamspeak 3 server"-service as user "teamspeak" with the following commands:
    Code:
    sudo systemctl start teamspeak3server
    sudo systemctl stop teamspeak3server
    sudo systemctl restart teamspeak3server
    sudo systemctl status teamspeak3server
    Now you can try to connect to your teamspeak server using the client, you will need the generated key you have saved earlier.


    Regards,
    MagicJohnson
    Last edited by MagicJohnson; August 11th, 2017 at 05:29 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [Resolved] TS3 Server (64 bit) Install fails on Debian 8
    By Nebuluski in forum Linux / FreeBSD
    Replies: 2
    Last Post: March 23rd, 2016, 12:49 AM
  2. Install Teamspeak on Linux / Debian
    By jsvenancio in forum Linux
    Replies: 5
    Last Post: May 27th, 2014, 12:54 PM
  3. Linux Debian Lenny TS3 SERVER Quick Install Script
    By killerkeks in forum Tools / Web Based
    Replies: 0
    Last Post: January 3rd, 2011, 01:05 PM
  4. Debian 5 install problem
    By DATE65 in forum Linux / FreeBSD
    Replies: 3
    Last Post: February 11th, 2010, 09:32 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •