[gull] Script pour restarter mysql

Daniel Cordey dc at mjt.ch
Tue Oct 10 12:39:22 CEST 2006


On Tuesday 10 October 2006 12:02, Lol Zimmerli wrote:

> if [ ! -s /tmp/mysql ]
> then
> ...

Normalement, mysql ecrit son PID dans :

	/var/run/mysqld/mysqld.pid

A parrir de la, il suffit de relire ce PID et d'effectuer un kill 0.

kill -s 0 $(< /var/run/mysqld/mysqld.pid) 2>/dev/null && /etc/init.d/mysql start

dc





More information about the gull mailing list