@@ -16,8 +16,8 @@ exec 5<&0
1616# Donations: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=7ZRXLSC2UBVWE
1717#
1818
19- SCRIPT_VERSION=" 5.8.2 "
20- LAST_EDIT_DATE=" 2021-04-07 "
19+ SCRIPT_VERSION=" 5.8.3 "
20+ LAST_EDIT_DATE=" 2021-05-20 "
2121
2222# DO NOT REMOVE OR CHANGE
2323SOFTWARE_ABOUT=" This is the most widely used and fastest shell script to update all your TeamSpeak 3 server instances."
@@ -87,7 +87,7 @@ function clearTerminalScreen() {
8787# Return: 0:boolean or 1:boolean
8888function checkConsistency() {
8989 CHKSUM=$( grep -v " ORIGIN=" " $0 " | sha256sum | cut -d " " -f 1)
90- ORIGIN=" ba8ba471627a26bde26f8e6c680574deda66c7c10bf617211e0e752f424f5c0a "
90+ ORIGIN=" b5fd2210cd8ca75b8671760db176230437828732ed004e54640e10a01e9174c6 "
9191
9292 if [[ " $CHKSUM " == " $ORIGIN " ]]; then
9393 return 0;
@@ -949,7 +949,7 @@ function getGroupOfTS3ServerFiles() {
949949# Par 1: TS3ServerRootDirectory:string
950950# Return: GroupID:string or 1:boolean
951951function getGroupID() {
952- GROUP_ID=$( grep -E " ^$( getGroupOfTS3ServerFiles ${1} ) \:" /etc/passwd | cut -d " :" -f 4 )
952+ GROUP_ID=$( grep -E " ^$( getGroupOfTS3ServerFiles ${1} ) \:" /etc/group | cut -d " :" -f 3 )
953953
954954 if [[ -n " $GROUP_ID " ]]; then
955955 echo -n " $GROUP_ID " ;
@@ -1012,19 +1012,6 @@ function getDatabaseINIFile() {
10121012 fi
10131013}
10141014
1015- # Get database type
1016- # Par 1: TeamSpeakRootDirectory:string
1017- # Return: DatabaseType:string or 1:boolean
1018- function getDatabaseType() {
1019- DATABASE_TYPE=" $( grep -Eo ' dbPlugin name:.*plugin' $( find ${1} /logs/ -name ' ts3server*_0.log' 2> /dev/null | sort | tail -1) | tr -d " " | cut -d " :" -f 2 | grep -Eo ' SQLite|MySQL|MariaDB' ) "
1020-
1021- if [[ -n " $DATABASE_TYPE " ]]; then
1022- echo -n " $DATABASE_TYPE " ;
1023- else
1024- return 1;
1025- fi
1026- }
1027-
10281015# Get TS3 server instance log path
10291016# Par 1: TS3ServerRootDirectory:string
10301017# Return: InstanceLogPath:string or 1:boolean
@@ -1058,7 +1045,7 @@ function getTS3ServerInstanceLogPath() {
10581045# Return: DatabaseType:string or 1:boolean
10591046function getDatabaseType() {
10601047 INSTANCE_LOG_PATH=" $( getTS3ServerInstanceLogPath ${1} ) "
1061- DATABASE_TYPE=" $( grep -Eo ' dbPlugin name:.*plugin' $( find ${INSTANCE_LOG_PATH} -name ' ts3server*_0.log' 2> /dev/null | sort | tail -1) | tr -d " " | cut -d " :" -f 2 | grep -Eo ' SQLite|MySQL|MariaDB' ) "
1048+ DATABASE_TYPE=" $( grep -Eo ' dbPlugin name:.*plugin' $( find ${INSTANCE_LOG_PATH} -name ' ts3server*_0.log' 2> /dev/null | sort | tail -1) | tail -1 | tr -d " " | cut -d " :" -f 2 | grep -Eo ' SQLite|MySQL|MariaDB' ) "
10621049
10631050 if [[ -n " $DATABASE_TYPE " ]]; then
10641051 echo -n " $DATABASE_TYPE " ;
@@ -2219,7 +2206,7 @@ function createDebugReport() {
22192206function main() {
22202207 # Load text for set language
22212208 cd " $ABSOLUTE_PATH "
2222- source $ PAR_LOCALE;
2209+ source " ${ABSOLUTE_PATH} / $ PAR_LOCALE" ;
22232210 cd - > /dev/null
22242211
22252212 # Enable debugging by commenting out the following line
0 commit comments