Home / How To / How to install Teamspeak 3 Server on CentOS 8

How to install Teamspeak 3 Server on CentOS 8



TeamSpeak is a voice server or VOIP application for real-time, real-time voice chat platforms via the Internet. TeamSpeak is lightweight and uses a very low bandwidth and can handle thousands of users at the same time. It is often used for games, education, training and chatting with friends and family. TeamSpeak is completely free. You just need to download and set up your own server and use the clients according to your needs.

In this tutorial, we will show you how to install and configure TeamSpeak server on CentOS 8 server.

Prerequisites

  • A server running CentOS 8.
  • A root password is configured on your server.

Getting Started

By default, SELinux is enabled on the CentOS 8 server. So you have to disable it first.

You can do this by editing / etc / selinux / config file:

  nano / etc / selinux / config 

Make the following changes:

  SELINUX = disabled

Save and close the file. Then restart the system to apply the changes.

Next, you need to install some dependencies on your server. You can install them all with the following command:

  dnf install nano wget perl takes net-tools bzip2 

Once all dependencies have been installed, you can proceed to the next step.

Install TeamSpeak

Before you install TeamSpeak, you must add a user for TeamSpeak. You can create it with the following command:

  adduser teamspeak -d / opt / teamspeak 

Next, download the latest version of TeamSpeak with the following command:

  wget http://dl.4players.de/ ts / releases / 3.8.0 / teamspeak3-server_linux_amd64-3.8.0.tar.bz2 

When the download is complete, extract the downloaded file with the following command:

  takes xvf teamspeak3-server_linux_amd64-3.8.0. tar.bz2 

Then move the contents of the extracted directory to / opt / teamspeak:

  etc. teamspeak3-server_linux_amd64 / * / opt / teamspeak / 

Then you must create a file named ". ts3server_license_accepted" in the directory / opt / teamspeak to accept the license agreement.

  touch /opt/teamspeak/.ts3server_license_acceptedebrit1
9659010??Next, change the ownership of the / opt / teamspeak directory to TeamSpeak users with the following command:

  chown-R teamspeak: / opt / teamspeak 

Create a Systemd TeamSpeak file

Next, you need to create a system service file to manage the TeamSpeak service. You can create it with the following command:

  nano /lib/systemd/system/teamspeak.service tu 1919919010 Add the following lines: 

  [Unit]
Description = Team Speak 3 Server
After = network.target
[Service]
WorkingDirectory = / opt / teamspeak /
User = teamspeak
The group = teamspeak
Type = forking
ExecStart = / opt / teamspeak / ts3server_startscript.sh start inifile = ts3server.ini
ExecStop = / opt / teamspeak / ts3server_startscript.sh stop
PidFile = / opt / teamspeak / ts3server.pid
RestartSec = 15
Restart = always
[Install]
WantedBy = multi-user.target

Save and close the file. Then reload the system daemon with the following command:

  systemctl - system daemon-reload 

Then start the TeamSpeak service and enable it after system startup with the following command:

  systemctl start teamspeak 
systemctl enable teamspeak

You can now check the status of the TeamSpeak service with the following command:

  systemctl status teamspeak 

You should see the following output:

? teamspeak.service - Team Speak 3 Server
Loaded: loaded (/usr/lib/systemd/system/teamspeak.service; disabled; vendor setting: disabled)
Active: active (running) since Sun 2019-10-27 12:51:44 EDT; 5s ago
Process: 1298 ExecStart = / opt / teamspeak / ts3server_startscript.sh start inifile = ts3server.ini (code = terminated, status = 0 / SUCCESS)
Main PID: 1305 (ts3server)
Details: 12 (limit: 5060)
Memory: 25.3M
CGroup: /system.slice/teamspeak.service
?? 1305 ./ts3server inifile = ts3server.ini daemon = 1 pid_file = ts3server.pid

October 27 12:51:44 centos8 systemd [1]: Launch Team Speak 3 Server ...
October 27 12:51:44 centos8 ts3server_startscript.sh [1298]: Launch TeamSpeak 3 server
Oct 27 12:51:44 centos8 ts3server_startscript.sh [1298]: TeamSpeak 3 server started, for details see log file
Oct 27 12:51:44 centos8 systemd [1]: Started Team Speak 3 Server.

Then you must retrieve the privileged key. You will require it when connecting to the TeamSpeak server from a TeamSpeak client. You can see it with the following command:

  cat / opt / teamspeak / logs / * 

You should get the following output:

  2019-10-27 17: 06: 00.334499 | INFO | | | Preparation time for puzzles: 4434
2019-10-27 17: 06: 00.335662 | INFO | FileManager | | listens on 0.0.0.0:30033, [::]: 30033
2019-10-27 17: 06: 00.337563 | INFO | VirtualSvrMgr | | run monthly
2019-10-27 17: 06: 00.337837 | INFO | VirtualSvrMgr | | reset virtual server traffic statistics
2019-10-27 17: 06: 00.376549 | INFO | Question | | listens to query at 0.0.0.0:10011, [::]: 10011
2019-10-27 17: 06: 00.377080 | INFO | Question | | listens to query ssh at 0.0.0.0:10022, [::]: 10022
2019-10-27 17: 06: 00.377152 | INFO | Question | | creates QUERY_SSH_RSA_HOST_KEY file: ssh_host_rsa_key
2019-10-27 17: 06: 06.649531 | INFO | CIDRManager | | updated query_ip_whitelist ips: 127.0.0.1/32, :: 1/128,
2019-10-27 17: 06: 00.374048 | INFO | VirtualServer | 1 | listens on 0.0.0.0:9987, [::]: 9987
2019-10-27 17: 06: 00.375751 | WARNING | VirtualServer | 1 | --------------------------------- ----------------- ------
2019-10-27 17: 06: 00.375818 | WARNING | VirtualServer | 1 | ServerAdmin permission key created, use the line below
2019-10-27 17: 06: 00.375857 | WARNING | VirtualServer | 1 |  token = 2y8a9yBz5aRlyDUwaBfgw8lq4FtQVT47pyAeU4Ja 
2019-10-27 17: 06: 00.375894 | WARNING | VirtualServer | 1 | --------------------------------- ----------------- ------

Setup Firewall for TeamSpeak

TeamSpeak is now installed and running. Then TeamSpeak listens to a port 9987 (UDP), 10011 (TCP) and 30033 (TCP). So you have to allow these ports from the firewall. You can allow them with the following commands:

  firewall-cmd - zone = public --add-port = 9987 / udp --permanent 
firewall-cmd --zone = public --add-port = 10011 / tcp --permanent
firewall-cmd --zone = public --add-port = 30033 / tcp --permanent
firewall-cmd - load

Conclusion

Congratulations! you have installed and configured the TeamSpeak server on CentOS 8 server. You can now download the TeamSpeak client, connect to the TeamSpeak server and start chatting with friends and family.


Source link