2.mysql-server.sh.in 664 Bytes
Newer Older
1 2 3 4 5
#!/bin/sh

case "$1" in
	start)
		if [ -x /usr/local/bin/safe_mysqld ]; then
6
			/usr/local/bin/safe_mysqld --pid-file=/var/run/mysqld.pid --skip-grant-tables --skip-networking --user=mysql --log-long-format --log=@prefix@/log/mysql/base --log-bin=@prefix@/log/mysql/update --log-slow-queries=@prefix@/log/mysql/slowqueries -O max_connections=300 -O long_query_time=2 -O key_buffer=32M -O table_cache=256 -O sort_buffer=4M -O record_buffer=1M > /dev/null 2>&1 &
7
			echo -n ' mysqld'
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
		fi
		;;
	stop)
		/usr/bin/killall mysqld > /dev/null 2>&1 && echo -n ' mysqld'
		;;
	*)
		echo ""
		echo "Usage: `basename $0` { start | stop }"
		echo ""
		exit 64
		;;
esac