Coder Social home page Coder Social logo

ts3updatescript's People

Contributors

chrissd23 avatar dgibbs64 avatar sebbo94by avatar takemenl avatar tristan3 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ts3updatescript's Issues

Password error even if .password-file has correct password

I added serveradmin password to the stated file but the script still gives authentication error during --check command. I am sure that password is correct since I can login with stated password using Yatqa.

Wrong serveradmin password. Please set the correct one here: /usr/local/teamspeak3/.password-file

Censore serveradmin password in debug file

Multiple customers sends us their debug file, that we can help them better and faster. We always can see the "serveradmin" password in clear text, what's sometimes useful, but in the most cases not needed.

We haven't used them ever, but it's a security lack, if they send us the debug file with the password in clear text via ticket system or email, because everybody could steal it.

Update all documentations

The addons.teamspeak.com download page does not exist anymore. Remove it and make sure, that everything else is up2date.

Backups are restored to the wrong instance

A client reported me, that a rollback deployed the backup in the wrong instance, what caused an damaged/overwritten instance.

This needs to be checked as well as fixed, if it really occurs.

To improve the backup, database backups should be backuped twice and never deleted by the script.

script incompatible if user is a system user

I've configured my teamspeak with a ts3 user which is only a system user:

sudo adduser --system --disabled-login --no-create-home ts3

This makes your script incompatible because any ´su -c SCRIPT $USER´ commands are not working. Any plans to detect if the user is a system user?

I've made the required changes in my fork for hints:
dionysius@3a271ac

Feature: Dynamic cronjob

As for now the cron jobs are hard coded in the script. (CRONJOB_HOUR="3")

That's a bad thing i think, personally my servers do backups on 2 until 4 so when the cron job runs it only loads the system more and that's bad.

problem with --keep-backups option

It does not work due to tr -s deletes repeated characters:
$ echo --keep-backups | tr -s '[:upper:]' '[:lower:]'
Output: --kep-backups

BTW, you can replace tr with bash builtin function:
- case $(echo "$1" | tr -s '[:upper:]' '[:lower:]') in
+ case ${1,,} in

MariaDB support for TeamSpeak server version 3.0.11 and newer

TeamSpeak CHANGELOG:

=== Server Release 3.0.11 xx sep 2014
! Starting this release, the MySQL database plugin has been replaced by a MariaDB plugin. Please
read doc/update_mysql_to_mariadb.txt for instructions on how to update. Also note the default
character set for the database is now 'utf8mb4', which means the server needs to be at least
MySQL 5.5.3 or MariaDB 5.5 .

TSDNS: Decrease downtime while creating password backups and display backup message

The script is currently stopping the TSDNS server first and creating backups of temporary server passwords after this step. While TSDNS is stopped, nobody is able to connect to any server. For customers (clients) it looks like, if the server is offline.

Note: There is a parameter available to disable the backup of temporary passwords. Use this, if you want or have to decrease the downtime immediately and can't wait for the new release.

--disable-temporary-password-backup

The other important point is, that the script is backuping temporary server passwords, but isn't displaying any hint/message for this. There should be a small hint for. These passwords also should be restored after the TeamSpeak 3 and TSDNS server has been started to decrease the downtime.

Please answer: ([y]es/[n]o) yes
TSDNS stopped for update process.
Could not backup temporary server passwords. Don't worry. You may just don't had any.   <<===
TeamSpeak 3 server instance stopped for update process.
Deleting old log files.
Backup created successful.
TeamSpeak 3 server instance was updated successful.
TSDNS was started successful.
Scanned tsdns_settings.ini, number of entries: 1 normal and 0 wildcards
TeamSpeak 3 server instance was started successful.
Waiting 15 seconds to execute TeamSpeak 3 server and TSDNS health check...
TeamSpeak 3 server instance is still running.
TSDNS is still running.
Backup was deleted successful.

ts3server_startscript.sh isn't updated all the time (<3.0.11.4 update to >3.0.12)

Some customers have the problem, that they want to update their old 3.0.11.4 instance to 3.0.12.x, but the script returns always, that the server couldn't be started.
Could not start TeamSpeak 3 server instance.
The cause could be identified by the TS3UpdateScript debug parameter:
Could not locate binary file, aborting
The binary has been changed with the update to 3.0.12 and since that, the ts3server_startscript.sh script needs to use the new binary.

New release (5.2.0) does not work

bzip2: Compressed file ends unexpectedly;
        perhaps it is corrupted?  *Possible* reason follows.
bzip2: No such file or directory
        Input file = teamspeak3-server.tar.bz2, output file = teamspeak3-server.tar

It is possible that the compressed file(s) have become corrupted.
You can use the -tvv option to test integrity of such files.

You can use the `bzip2recover' program to attempt to recover
data from undamaged sections of corrupted files.

bzip2: Deleting output file teamspeak3-server.tar, if it exists.
cp: cannot stat 'teamspeak3-server__/*': No such file or directory
rm: cannot remove 'teamspeak3-server.tar': No such file or directory
chmod: cannot access 'ts3server_*': No such file or directory
chown: missing operand after ‘/’
Try 'chown --help' for more information.
TeamSpeak 3 server instance was updated successful.
Could not start TeamSpeak 3 server instance.
df: /files/: No such file or directory
grep: /ts3server_startscript.sh: No such file or directory
stat: missing operand
Try 'stat --help' for more information.
ls: cannot read symbolic link '/proc/2/exe': No such file or directory
ls: cannot read symbolic link '/proc/3/exe': No such file or directory
ls: cannot read symbolic link '/proc/5/exe': No such file or directory
ls: cannot read symbolic link '/proc/7/exe': No such file or directory
ls: cannot read symbolic link '/proc/8/exe': No such file or directory
ls: cannot read symbolic link '/proc/9/exe': No such file or directory
ls: cannot read symbolic link '/proc/10/exe': No such file or directory
ls: cannot read symbolic link '/proc/11/exe': No such file or directory
ls: cannot read symbolic link '/proc/12/exe': No such file or directory
ls: cannot read symbolic link '/proc/13/exe': No such file or directory
ls: cannot read symbolic link '/proc/14/exe': No such file or directory
ls: cannot read symbolic link '/proc/15/exe': No such file or directory
ls: cannot read symbolic link '/proc/17/exe': No such file or directory
ls: cannot read symbolic link '/proc/18/exe': No such file or directory
ls: cannot read symbolic link '/proc/19/exe': No such file or directory
ls: cannot read symbolic link '/proc/20/exe': No such file or directory
ls: cannot read symbolic link '/proc/21/exe': No such file or directory
ls: cannot read symbolic link '/proc/22/exe': No such file or directory
ls: cannot read symbolic link '/proc/24/exe': No such file or directory
ls: cannot read symbolic link '/proc/25/exe': No such file or directory
ls: cannot read symbolic link '/proc/26/exe': No such file or directory
ls: cannot read symbolic link '/proc/27/exe': No such file or directory
ls: cannot read symbolic link '/proc/28/exe': No such file or directory
ls: cannot read symbolic link '/proc/29/exe': No such file or directory
ls: cannot read symbolic link '/proc/30/exe': No such file or directory
ls: cannot read symbolic link '/proc/31/exe': No such file or directory
ls: cannot read symbolic link '/proc/32/exe': No such file or directory
ls: cannot read symbolic link '/proc/33/exe': No such file or directory
ls: cannot read symbolic link '/proc/34/exe': No such file or directory
ls: cannot read symbolic link '/proc/35/exe': No such file or directory
ls: cannot read symbolic link '/proc/36/exe': No such file or directory
ls: cannot read symbolic link '/proc/37/exe': No such file or directory
ls: cannot read symbolic link '/proc/38/exe': No such file or directory
ls: cannot read symbolic link '/proc/39/exe': No such file or directory
ls: cannot read symbolic link '/proc/40/exe': No such file or directory
ls: cannot read symbolic link '/proc/41/exe': No such file or directory
ls: cannot read symbolic link '/proc/42/exe': No such file or directory
ls: cannot read symbolic link '/proc/43/exe': No such file or directory
ls: cannot read symbolic link '/proc/44/exe': No such file or directory
ls: cannot read symbolic link '/proc/45/exe': No such file or directory
ls: cannot read symbolic link '/proc/48/exe': No such file or directory
ls: cannot read symbolic link '/proc/49/exe': No such file or directory
ls: cannot read symbolic link '/proc/90/exe': No such file or directory
ls: cannot read symbolic link '/proc/92/exe': No such file or directory
ls: cannot read symbolic link '/proc/93/exe': No such file or directory
ls: cannot read symbolic link '/proc/94/exe': No such file or directory
ls: cannot read symbolic link '/proc/95/exe': No such file or directory
ls: cannot read symbolic link '/proc/96/exe': No such file or directory
ls: cannot read symbolic link '/proc/97/exe': No such file or directory
ls: cannot read symbolic link '/proc/99/exe': No such file or directory
ls: cannot read symbolic link '/proc/101/exe': No such file or directory
ls: cannot read symbolic link '/proc/102/exe': No such file or directory
ls: cannot read symbolic link '/proc/134/exe': No such file or directory
ls: cannot read symbolic link '/proc/135/exe': No such file or directory
ls: cannot read symbolic link '/proc/137/exe': No such file or directory
ls: cannot read symbolic link '/proc/138/exe': No such file or directory
ls: cannot read symbolic link '/proc/178/exe': No such file or directory
ls: cannot read symbolic link '/proc/330/exe': No such file or directory
ls: cannot read symbolic link '/proc/331/exe': No such file or directory
ls: cannot read symbolic link '/proc/338/exe': No such file or directory
ls: cannot read symbolic link '/proc/339/exe': No such file or directory
ls: cannot read symbolic link '/proc/340/exe': No such file or directory
ls: cannot read symbolic link '/proc/341/exe': No such file or directory
ls: cannot read symbolic link '/proc/342/exe': No such file or directory
ls: cannot read symbolic link '/proc/362/exe': No such file or directory
ls: cannot read symbolic link '/proc/363/exe': No such file or directory
ls: cannot read symbolic link '/proc/388/exe': No such file or directory
ls: cannot read symbolic link '/proc/389/exe': No such file or directory
ls: cannot read symbolic link '/proc/390/exe': No such file or directory
ls: cannot read symbolic link '/proc/392/exe': No such file or directory
ls: cannot read symbolic link '/proc/393/exe': No such file or directory
ls: cannot read symbolic link '/proc/395/exe': No such file or directory
ls: cannot read symbolic link '/proc/396/exe': No such file or directory
ls: cannot read symbolic link '/proc/397/exe': No such file or directory
ls: cannot read symbolic link '/proc/398/exe': No such file or directory
ls: cannot read symbolic link '/proc/399/exe': No such file or directory
ls: cannot read symbolic link '/proc/429/exe': No such file or directory
ls: cannot read symbolic link '/proc/538/exe': No such file or directory
ls: cannot read symbolic link '/proc/620/exe': No such file or directory
ls: cannot read symbolic link '/proc/621/exe': No such file or directory
ls: cannot read symbolic link '/proc/1324/exe': No such file or directory
ls: cannot read symbolic link '/proc/5482/exe': No such file or directory
ls: cannot read symbolic link '/proc/5493/exe': No such file or directory
ls: cannot read symbolic link '/proc/6372/exe': No such file or directory
ls: cannot read symbolic link '/proc/8125/exe': No such file or directory
ls: cannot read symbolic link '/proc/9694/exe': No such file or directory
ls: cannot read symbolic link '/proc/9706/exe': No such file or directory
ls: cannot read symbolic link '/proc/9751/exe': No such file or directory
ls: cannot read symbolic link '/proc/9770/exe': No such file or directory
ls: cannot read symbolic link '/proc/9779/exe': No such file or directory
ls: cannot read symbolic link '/proc/9784/exe': No such file or directory
ls: cannot read symbolic link '/proc/9912/exe': No such file or directory
ls: cannot read symbolic link '/proc/10728/exe': No such file or directory
ls: cannot access '/proc/11160': No such file or directory
ls: cannot access '/proc/11160/task': No such file or directory
ls: cannot access '/proc/11160/fd': No such file or directory
ls: cannot access '/proc/11160/fdinfo': No such file or directory
ls: cannot access '/proc/11160/ns': No such file or directory
ls: cannot access '/proc/11160/net': No such file or directory
ls: cannot access '/proc/11160/attr': No such file or directory

Then fails. Fedora Server 24. Last release worked fine.

Update doesnt work.

On latest version (5.0.1) the instanceinfo is always wrong and thus the script cant download and update my instance.

It detects 127.0.0.1 as SERVERQUERY_IP, but I got two IPs and teamspeak is running on the secondary only. The script doesnt detect amd64 / linux as well.

Script just sits on collecting information

RUNNING SCRIPT WITH DEBUG OPTION! PARAMETER LIST: --check --debug lolzlo.txt [v5.2.2]
++ date +%s
+ TIME_MEASUREMENT_SELFTESTS_START=1473625647
+ '[' 0 -eq 1 ']'
+ echo -en '\e[sPerforming self-tests as preventive measures against possible failures'
�[sPerforming self-tests as preventive measures against possible failures+ echo -e '\e[u\e[87C[ \e[0;37m.. \e[0m]\n'
�[u�[87C[ �[0;37m.. �[0m]

+ SELF_TEST_STATUS=0
+ isBashCompletionInstalled
+ '[' -f /etc/bash_completion.d/ts3updatescript ']'
++ stat --format=%U /etc/bash_completion.d/ts3updatescript
+ [[ root == \r\o\o\t ]]
++ stat --format=%G /etc/bash_completion.d/ts3updatescript
+ [[ root == \r\o\o\t ]]
+ return 0
+ [[ ! -f configs/config.all ]]
+ checkConsistency
++ grep -v ORIGIN= ./TS3UpdateScript
++ head -202
++ cut -d ' ' -f 1
++ sha256sum
+ CHKSUM=33c8feaff76d8bc2930ac1ded78901683feadd145aba5e8467f7209c0f457567
+ ORIGIN=33c8feaff76d8bc2930ac1ded78901683feadd145aba5e8467f7209c0f457567
+ [[ 33c8feaff76d8bc2930ac1ded78901683feadd145aba5e8467f7209c0f457567 == \3\3\c\8\f\e\a\f\f\7\6\d\8\b\c\2\9\3\0\a\c\1\d\e\d\7\8\9\0\1\6\8\3\f\e\a\d\d\1\4\5\a\b\a\5\e\8\4\6\7\f\7\2\0\9\c\0\f\4\5\7\5\6\7 ]]
+ return 0
+ [[ 0 -eq 0 ]]
+ testInternetConnectivity www.ts3-tools.info
++ ping -w 1 www.ts3-tools.info
+ [[ -n PING www.ts3-tools.info (84.200.62.14) 56(84) bytes of data.
64 bytes from ipdc-vs00017.4g-server.eu (84.200.62.14): icmp_seq=1 ttl=58 time=5.52 ms

--- www.ts3-tools.info ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 5.523/5.523/5.523/0.000 ms ]]
+ return 0
+ testInternetConnectivity dl.4players.de
++ ping -w 1 dl.4players.de
+ [[ -n PING dl.dl1.4players.de (85.25.26.25) 56(84) bytes of data.

--- dl.dl1.4players.de ping statistics ---
1 packets transmitted, 0 received, 100% packet loss, time 0ms ]]
+ return 0
+ testInternetConnectivity github.com
++ ping -w 1 github.com
+ [[ -n PING github.com (192.30.253.112) 56(84) bytes of data.
64 bytes from 192.30.253.112: icmp_seq=1 ttl=55 time=90.9 ms

--- github.com ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 90.964/90.964/90.964/0.000 ms ]]
+ return 0
+ testInternetConnectivity raw.githubusercontent.com
++ ping -w 1 raw.githubusercontent.com
+ [[ -n PING prod.github.map.fastlylb.net (151.101.12.133) 56(84) bytes of data.
64 bytes from 151.101.12.133: icmp_seq=1 ttl=59 time=5.08 ms

--- prod.github.map.fastlylb.net ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 5.082/5.082/5.082/0.000 ms ]]
+ return 0
++ getLatestScriptVersion
+++ wget https://raw.githubusercontent.com/TS3Tools/TS3UpdateScript/master/docs/CHANGELOG.md --no-check-certificate -q -O -
+++ grep Version
+++ head -1
+++ grep -Eo '[0-9\.?]+'
++ LATEST_SCRIPT_VERSION=5.2.2
++ [[ -n 5.2.2 ]]
++ echo -n 5.2.2
+ LATEST_SCRIPT_VERSION=5.2.2
+ [[ 5.2.2 != 1 ]]
+ [[ 0 -eq 0 ]]
+ [[ -n 5.2.2 ]]
+ [[ 5.2.2 != \5\.\2\.\2 ]]
+ checkdeps bash which rsync wget grep sed unzip bzip2 gdb
+ CHECKDEPS_FAILED=0
+ for cmd in '"$@"'
++ echo bash
++ cut -d : -f 1
+ package_cmd=bash
++ echo bash
++ cut -d : -f 2
+ package=bash
+ [[ -z bash ]]
+ command -v bash
+ for cmd in '"$@"'
++ echo which
++ cut -d : -f 1
+ package_cmd=which
++ echo which
++ cut -d : -f 2
+ package=which
+ [[ -z which ]]
+ command -v which
+ for cmd in '"$@"'
++ echo rsync
++ cut -d : -f 1
+ package_cmd=rsync
++ echo rsync
++ cut -d : -f 2
+ package=rsync
+ [[ -z rsync ]]
+ command -v rsync
+ for cmd in '"$@"'
++ echo wget
++ cut -d : -f 1
+ package_cmd=wget
++ echo wget
++ cut -d : -f 2
+ package=wget
+ [[ -z wget ]]
+ command -v wget
+ for cmd in '"$@"'
++ echo grep
++ cut -d : -f 1
+ package_cmd=grep
++ echo grep
++ cut -d : -f 2
+ package=grep
+ [[ -z grep ]]
+ command -v grep
+ for cmd in '"$@"'
++ echo sed
++ cut -d : -f 1
+ package_cmd=sed
++ echo sed
++ cut -d : -f 2
+ package=sed
+ [[ -z sed ]]
+ command -v sed
+ for cmd in '"$@"'
++ echo unzip
++ cut -d : -f 1
+ package_cmd=unzip
++ echo unzip
++ cut -d : -f 2
+ package=unzip
+ [[ -z unzip ]]
+ command -v unzip
+ for cmd in '"$@"'
++ echo bzip2
++ cut -d : -f 1
+ package_cmd=bzip2
++ echo bzip2
++ cut -d : -f 2
+ package=bzip2
+ [[ -z bzip2 ]]
+ command -v bzip2
+ for cmd in '"$@"'
++ echo gdb
++ cut -d : -f 1
+ package_cmd=gdb
++ echo gdb
++ cut -d : -f 2
+ package=gdb
+ [[ -z gdb ]]
+ command -v gdb
+ [[ 0 -eq 1 ]]
+ return 0
+ '[' -f /etc/debian_version ']'
+ checkdeps lsb_release
+ CHECKDEPS_FAILED=0
+ for cmd in '"$@"'
++ echo lsb_release
++ cut -d : -f 1
+ package_cmd=lsb_release
++ echo lsb_release
++ cut -d : -f 2
+ package=lsb_release
+ [[ -z lsb_release ]]
+ command -v lsb_release
+ [[ 0 -eq 1 ]]
+ return 0
+ '[' 0 -eq 1 ']'
+ '[' 0 -eq 1 ']'
+ [[ 0 -eq 1 ]]
+ [[ 0 -eq 1 ]]
+ scriptSettingsChanged
++ grep ADMINISTRATOR_EMAILS /root/TS3UpdateScript-master/configs/config.all
++ cut -d = -f 2
++ cut -d ' ' -f 1
++ md5sum
+ ADMIN_EMAIL_MD5SUM=8246f9d5dadbd6e513f460005f9460bf
+ [[ 8246f9d5dadbd6e513f460005f9460bf != \1\6\0\d\f\a\4\2\c\0\c\b\8\e\2\5\3\1\1\b\6\a\f\f\3\a\4\d\5\3\6\1 ]]
+ return 0
++ date +%s
+ TIME_MEASUREMENT_SELFTESTS_END=1473625651
+ [[ 0 -eq 1 ]]
+ '[' 0 -eq 1 ']'
+ echo -e '\e[u\e[87C[ \e[0;32mOK \e[0m]\n'
�[u�[87C[ �[0;32mOK �[0m]

+ [[ -f SELF_TEST_STATUS.txt ]]
+ [[ 0 -eq 0 ]]
+ [[ 0 -eq 0 ]]
++ date +%s
+ TIME_MEASUREMENT_COLLECTING_INFORMATION_START=1473625651
+ COLLECTING_INFORMATION_STATUS=0
+ '[' 0 -eq 1 ']'
+ echo -en '\e[sCollecting necessary information for further tasks'
�[sCollecting necessary information for further tasks+ echo -e '\e[u\e[87C[ \e[0;37m.. \e[0m]\n'
�[u�[87C[ �[0;37m.. �[0m]

+ findTS3ServerInstances
+ [[ 0 == \2 ]]
+ find / -name ts3server_startscript.sh
+ grep -Eiv '/tmp/TS3Tools/TS3UpdateScript|/var/backups/TS3Tools/TS3UpdateScript'
+ sort
+ head -1
+ [[ -s TS3InstancePaths.txt ]]
+ return 0
++ getLatestTSServerVersion
++ TS3_SERVER_VERSION=0
++ [[ 0 -eq 1 ]]
++ [[ 0 -eq 1 ]]
+++ getLatestStableTS3ServerVersion
+++ wget -t 3 -T 10 'http://dl.4players.de/ts/releases/?C=M;O=D' -q -O -
+++ sort -V -r
+++ grep -Eo '<a href=\".*\/\">.*\/<\/a>'
+++ grep -i dir
+++ uniq
+++ grep -Eo '[0-9\.?]+'
+++ [[ 0 -ne 0 ]]
+++ read release
+++ [[ 3.0.19.4 =~ ^[3-9]+\.[0-9]+\.1[2-9]+\.?[0-9]*$ ]]
+++ wget --spider -q http://dl.4players.de/ts/releases/3.0.19.4/teamspeak3-server_linux_amd64-3.0.19.4.tar.bz2
+++ [[ 8 == 0 ]]
+++ read release
+++ [[ 3.0.19.3 =~ ^[3-9]+\.[0-9]+\.1[2-9]+\.?[0-9]*$ ]]
+++ wget --spider -q http://dl.4players.de/ts/releases/3.0.19.3/teamspeak3-server_linux_amd64-3.0.19.3.tar.bz2
+++ [[ 8 == 0 ]]
+++ read release
+++ [[ 3.0.19.2 =~ ^[3-9]+\.[0-9]+\.1[2-9]+\.?[0-9]*$ ]]
+++ wget --spider -q http://dl.4players.de/ts/releases/3.0.19.2/teamspeak3-server_linux_amd64-3.0.19.2.tar.bz2
+++ [[ 8 == 0 ]]
+++ read release
+++ [[ 3.0.19.1 =~ ^[3-9]+\.[0-9]+\.1[2-9]+\.?[0-9]*$ ]]
+++ wget --spider -q http://dl.4players.de/ts/releases/3.0.19.1/teamspeak3-server_linux_amd64-3.0.19.1.tar.bz2
+++ [[ 8 == 0 ]]
+++ read release
+++ [[ 3.0.19 =~ ^[3-9]+\.[0-9]+\.1[2-9]+\.?[0-9]*$ ]]
+++ wget --spider -q http://dl.4players.de/ts/releases/3.0.19/teamspeak3-server_linux_amd64-3.0.19.tar.bz2

[BPA] Add check for system locale

Due of the following message, there should be a Best Practices Check, to verify, if it's set to C or not.

2016-08-17 23:57:45.419822|WARNING |ServerLibPriv | |The system locale is set to "C" this can cause unexpected behavior. We advice you to repair your locale!

Permission denied for "ts3server_startup.sh start"

OS: Debian 8 Jessie
Script: v4.1.1
Attempting upgrade: 3.0.11.3 -> 3.0.11.4

I get "permission denied" for ts3server_startup.sh when the script attempts to restart the ts3 server after successfully updating the ts3 server.

I also get "permission denied" if I try to start the server manually when the update script is running - I believe this is because "ts3server_startup.sh" enters a locked state when the update script calls:
ts3server_startup.sh stop

As soon as the update script exits (after failing), I can then start the server manually. But the update rolls-back.

Is there a way to free the lock on the file, so the script can start the server, and finish the update?

Or must I split the script into two sections, so I can start the server manually, and then continue the script?

Thanks

Instance available, but stopped causes find() problems

If an instance is available, but stopped, the find command returns no such file or directory. The "installed version" is also empty. Verify and fix this problem.

Collecting necessary information for further tasks [ OK ]

All collected information were validated successfully as preventive measures against possible failures [ INFO ]
find: "/home/teamspeak/logs/": No such file or directory
1 TeamSpeak 3 server instance found...or directory

Collecting as much as possible information for following TeamSpeak 3 server instance: /home/teamspeak
1 instance for update process...
find: "/home/teamspeak/logs/": No such file or directory

Following instance needs an update, but is stopped and not touched by the script: /home/teamspeak (Installed Version: )

Add SQL export due possible structure and database updates to the backup

The backup does only include files yet. In future, the backup also should include MySQL/MariaDB dumps of the database to be able to deploy the backup of an older version with an older database revision.

Some new TeamSpeak 3 server releases upgrades this revision, which causes an issue for older releases, if the script would rollback.

Backup should be available, but does not exist

The backup was created successful, but the destination does not exist anymore:

    5 minutes to wait...
    Could not backup temporary server passwords. Don't worry. You may just don't had any.
    TeamSpeak 3 server instance stopped for update process.
    Deleting old log files.
    Backup created successful.
    TeamSpeak 3 server instance was updated successful.
    Could not start TeamSpeak 3 server instance.
    Update and rollback failed. Please fix it manually. Backup can be found here: /tmp/TS3Tools/TS3UpdateScript/858bbb33349cda2b26073bf94a51c0f9

Update script doesn't detect newer installed version.

When I run the latest TS Update Script (4.6.0) it asks do I want to "update" to a version that's older than that currently installed. This doesn't affect me, just said I'd let you know.

1 TeamSpeak 3 server instance found...

Collecting as much as possible information for following TeamSpeak 3 server instance: /opt/teamspeak3-server
1 instance for update process...
############################################################################
    Do you want to update this instance to the following version? 3.0.11.4

    Installation Directory: /opt/teamspeak3-server
    Installed Version: 3.0.12.4 (Build: 1461597405)
    Installed Platform: Linux
    Installed Architecture: amd64

    Instance Log Files: /opt/teamspeak3-server/logs
    Instance TSDNS Binary: /opt/teamspeak3-server/tsdns/tsdnsserver
    TSDNS Status: Inactive

    Owner: teamspeak3-user (UID: 1000)
    Group: teamspeak3-user (GID: 1000)

    ServerQuery IP: 0.0.0.0
    ServerQuery Port: 10011

    Database Type: MariaDB
############################################################################
Please answer: ([y]es/[n]o) n
Instance will not be updated.

ts3server.ini: If query_ip is set to 0.0.0.0, use 127.0.0.1 instead

If in ts3server.ini the query_ip is set to 0.0.0.0, the TS3UpdateScript will use this IP to connect to the server. This causes a connection issue and results in some failed tasks based on the used parameters.

The script will use 127.0.0.1 instead of 0.0.0.0 in future.

Temporary passwords aren't restored correct

Passwords with spaces are restored with a s instead of a space. For example:

Above is always the source string, while the other one is the restored string.

password test

passwordstest

channel description 3

channelsdescriptions3

Rename .txt to .md

Would make the documentation much more readable via GitHub and change nothing for shell users.

su: user UNKNOWN does not exist

If the files are owned by an user / user id, which does not exist anymore, the files are owned by "UNKNOWN", which is currently not checked by the TS3UpdateScript.

Add this to the owner detection part with an extra error text due it's a seperate issue.

Extend support of ExaGear for more than just Debian 8

The script currently only supports ExaGear on Debian 8, due the code is set to following path:

if [[ -d "/opt/exagear/" ]]; then
        TEAMSPEAK_ROOT_DIRECTORY="/opt/exagear/images/debian-8-wine2g${1}/"
else
        TEAMSPEAK_ROOT_DIRECTORY="${1}/"
fi

ToDos:

  • Find a method to identify the correct path based on the used Linux distributation
  • Create a new function for this code, because it's used multiple times in the script

This can be a possible solution:

find /opt/exagear/images/ -maxdepth 1 -type d ! -path /opt/exagear/images/

Cronjobs are not executed as root / Cronjob gets wrong license information

Cronjobs are failing, because the licensing does always display the "Free" license.

Sep 10 02:06:01 ts3 /usr/sbin/cron[1527]: (*system*TS3UpdateScript) RELOAD (/etc/cron.d/TS3UpdateScript)
Sep 10 02:06:01 ts3 /USR/SBIN/CRON[22377]: (root) CMD (/root/TS3UpdateScript/TS3UpdateScript --update-script)

A cronjob email contained these information:

/root/TS3UpdateScript/TS3UpdateScript: Zeile 122: 93.123.123.7i686: command not found
[...]
Script License: Free (limited)
[...]
Cronjobs are not possible under the Free license! You need to upgrade your license therefore. View README.md for more.

After fixing the command not found on line 122, the issue was still not fixed. It's currently unknown, if cron.d is doing something wrong or the script.

This issues needs to be debugged, fixed and tested multiple times. After identifying the real cause, this issue gets updated as enhancement or bug.

Update Script Failure

You closed previous without assisting. I know you said 'script is only xxxx lines long' but doesn't explain reasoning behind failure.

`About: This is the most widely used and fastest shell script to update all your TeamSpeak 3 server instances.
Author: Sebastian Kraetzig [email protected]
Website: www.ts3-tools.info
facebook: www.facebook.com/TS3Tools
License: GNU GPLv3


|_ / | / | | ___ ___ | |___ () __ / | ___
| | ___ \ |
\ | / _ \ / _ | / | | | ' | | / _
| | ___) |) |
| || () | () | __ | | | | | | () |
|
| |// _____/ **/||**()|| ||| ___/

Script Version: 4.6.2 (2016-08-09)
Script License: Free (limited)

Donate and support this script: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7ZRXLSC2UBVWE


Please wait... Script is working...

Performing self-tests as preventive measures against possible failures [ OK ]

All collected information were validated successfully as preventive measures against possible failurespdate-script [ INFO ]

Do you really want to update the script? ([y]es/[n]o) y
Script update is in progress... [ Should be updated ]

Cleaning up...

Summary of measured execution time for each step
Total script: 30s
Self-Test: 5s
Execution Mechanism: 24s
Cleanup: 0s

Thanks for using this script! Support the development of this script and donate: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7ZRXLSC2UBVWE
./TS3UpdateScript: line 3691: syntax error near unexpected token (' ./TS3UpdateScript: line 3691: echo -e "\nUsage: ./$SCRIPT_NAME OPTION(S)\n";'`

Script fails to find correct server within recursive directory.

As an example, if you have a TS3 server in "/home/teamspeak" and another in "/home/teamspeak/home/teamspeak", which can happen if you've just unzipped a root-oriented backup within the user folder as I had, the script will find only the further recursive server and not the other, and will fail to update.

Edit for posterity: 1/3rd of the response to this was relevant. The issue was the script choosing the further recursive instance due to lack of "hoster license".

Cannot execute /bin/dummy

Creating Backup of existing TeamSpeak 3 server
Your server will be updated right now
Importing SQLite database
Importing Query IP white- and blacklist
Adjusting ownership and group of files
Adding COMMANDLINE_PARAMETERS 'inifile=ts3server.ini' to ts3server_startscript.sh
Cannot execute /bin/dummy
Rollback to the version '3.0.7.1', because the server could not start
Cannot execute /bin/dummy
Your new server version could not start. Deployed backup of version '3.0.7.1'
Cleaning up system
Finish!

Improve MySQL/MariaDB database backup export

Some customers are saving their database credentials within quotation marks, which causes following issue by dumping the database:

mysqldump: Got error: 2005: Unkown MySQL server host ''mysql.example.com'' (0) when trying to connect

Example database config file:

[config]
host='mysql.example.com'
port='3306'
username='teamspeak'
password='verySecretPassword'
database='teamspeak'
socket=

If the database port isn't 3306, the export will also fail, because no other port is being used by the script.

The script should also abort the update in case of the MySQL backup failed or it should ask the user at least, if he wants to continue or abort the update.

mysqldump: Got error: 1045: Access denied for user 'teamspeak'@'10.100.0.30' (using password: YES) when trying to connect

Position of "--inform-online-clients" argument prevents fetching of the current version

Hi, if I'm using the "--inform-online-clients" argument as the second argument, the script is no longer able to fetch the currently installed TS3 version. If I write it last, it works.

Script Version: 3.11.7 (2015-01-18)

Working command "./TS3UpdateScript.sh --check --delete-old-logs --keep-backups --inform-online-clients":

Latest Stable Release   : 3.0.11.2
Installed Release       : 3.0.11.2 (Build: 1418654632)
Installed Architecture  : amd64
Installed Binary        : Linux

Not working "./TS3UpdateScript.sh --check --inform-online-clients --delete-old-logs --keep-backups":

Latest Stable Release   : 3.0.11.2
Installed Release       : Unknown (Build: Unknown)
Installed Architecture  : amd64
Installed Binary        : Unknown

There were two error lines posted in the execution log:

Informing online clients... This may take a while.
./TS3UpdateScript.sh: line 1100: [: missing `]'
./TS3UpdateScript.sh: line 1102: [: missing `]'
Stopping the TeamSpeak 3 server..done

It is to note that this seems to be the only problem. The update process itself works, it just wants to update every time the script is running because it can't detect the most recent version.

Edit: Can't answer anymore. This conversation is locked to collaborators only.

Script can't update

Please wait... Script is working...

Performing self-tests as preventive measures against possible failures                  [ OK ]

Collecting necessary information for further tasks                                      [ OK ]

All collected information were validated successfully as preventive measures against pos[ INFO ]ilures
1 TeamSpeak 3 server instance found...

Collecting as much as possible information for TeamSpeak 3 server instance '/home/twyk/ts3'
1 instance for update process...

Following instance needs an update, but is stopped and not touched by the script: /home/twyk/ts3 (Installed Version: 3.0.11.4)

Cleaning up...

Summary of measured execution time for each step
Total script: 8s
Self-Test: 4s
Collecting Information: 4s
Validation: 0s
Execution Mechanism: 0s
Cleanup: 0s

But the server is running...
@Sebi94nbg

Update Script Failure

./TS3UpdateScript: line 3530: unexpected EOF while looking for matching `''
./TS3UpdateScript: line 3534: syntax error: unexpected end of file

Server 3.0.12 Beta release

There are a few important changes which require your attention. We strongly recommend that all ATHP's download and test the beta prior to the final release.

  • The file name of the server executable previously indicated the operating system and architecture, and has now been changed to simply "ts3server".
  • For all platforms, the download archive filename has changed slightly.
  • For Linux/FreeBSD, the archive compression method has changed from gzip to bz2.
  • FreeBSD minimim supported version is now 10.1.
  • OS X minimum supported version is now 10.7 and we only supply 64-bit servers.

Planned release date for the final TeamSpeak 3 server 3.0.12 is January 5, 2016. Please read the information provided in the changelog.txt file in the downloaded content prior to upgrading your existing servers!

Changelog:

    === Server Release 3.0.12 5 jan 2016
     + added "virtualserver_min_android_version" and "virtualserver_min_ios_version" to specifically
       set the minimal allowed client versions for android and ios on the server.
     + added "-mapping" to the serversnapshotdeploy command. This optional parameters will add a mapping
       of the old and new channelid's in the return
     + Grouped several SQL queries together into one statement which improves performance
     - fixed clientdbfind command returning false entries
     - fixed some hangs after heavy network io on linux/freebsd/osx
     * The server will now print a warning if the locale is set to "C"
     * Replaced Server query manual pdf file with a html version
     ! Removed "virtualserver_max_upload_total_bandwidth" and 
       "virtualserver_max_download_total_bandwidth" from the server template if the value was "-1"
     ! The server binaries file names now do NOT have the platform suffixes any more. They are all
       called "ts3server"
     ! The OSX version is now 64 bit only. OSX 10.7 is now the minimum supported version.
     ! Some SQL queries changed or added. If you use custom SQL queries, please take note of this.
     ! The minimum supported FreeBSD version for the server is 10.1 from now on. Release 3.0.13 (next)
       will need a libc++ from ports/pkg or FreeBSD 10.2.

These changes needs to be fixed in a new version of TS3UpdateScript.

version check

Installed version is newer then latest version, but the script will start to downgrad the Server.
Also newest version wasn't found (parsed website wasn't refreshed yet).

(debug)
Latest Version : 3.0.10.3
Installed Version : 3.0.11 (Build: 1410449602)

Update fails

Update fails without helpful error message.
Here's the output of ./TS3UpdateScript --check --debug error.txt

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.