]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - src/paks/mysql/install.sh
Clamav kommt erstma ohne Virendefinitionen daher.
[people/pmueller/ipfire-2.x.git] / src / paks / mysql / install.sh
index 40787bd51a2d5623b5011eca2c27593c98a67c02..3fc601dc7a81984d4b0894a4a205057e37a4a1e5 100644 (file)
@@ -9,6 +9,16 @@ ln -svf  ../init.d/mysql /etc/rc.d/rc6.d/K26mysql
 
 /etc/init.d/mysql start
 
-sleep 10
+COUNTER=0
+
+while [ "$COUNTER" -lt "10" ]; do
+       [ -e "/var/run/mysql/mysql.sock" ] && break
+       echo "MySQL server is still not running. Waiting 5 seconds."
+       sleep 5
+       (( $COUNTER += 1 ))
+done 
+
+[ -e "/var/run/mysql/mysql.sock" ] || (echo "MySQL still noch running... Exiting."; \
+       exit 1)
 
 mysqladmin -u root --password='' password 'mysqlfire'