@Thenomain Well. My mechanipus branch of tinymux will auto-reconnect sql as needed... see
this commit if you want to try it in isolation...
Otherwise, set up a ~/.my.cnf file with something like:
[client]
user=gamename
password=...
database=gamename
and then a ~/wait-for-sql.sh like:
#! /bin/bash
while ! echo 'select distinct "sql is up";' |mysql; do sleep 1; done
and then be sure to set it executable
$ chmod 755 wait-for-sql.sh
and then edit your crontab (cron -e) to have something like:
@reboot wait-for-sql.sh && cd /home/mush/gamename/game && ./Startmux
or if you're on my fork something like
@reboot wait-for-sql.sh && cd /home/mush/gamename/game && bin/mux-start
menacing helpfulness intensifies