Add a --nowatch option to mysqld_safe that causes it to exit after spawning mysqld. We don't need mysqld_safe to restart mysqld after a crash, because systemd can do that just fine. diff -Naur mysql-5.5.14.orig/scripts/mysqld_safe.sh mysql-5.5.14/scripts/mysqld_safe.sh --- mysql-5.5.14.orig/scripts/mysqld_safe.sh 2011-06-21 12:42:40.000000000 -0400 +++ mysql-5.5.14/scripts/mysqld_safe.sh 2011-07-25 13:52:40.363068060 -0400 @@ -15,6 +15,7 @@ KILL_MYSQLD=1; MYSQLD= niceness=0 +nowatch=0 mysqld_ld_preload= mysqld_ld_library_path= @@ -54,6 +55,7 @@ --mysqld=FILE Use the specified file as mysqld --mysqld-version=VERSION Use "mysqld-VERSION" as mysqld --nice=NICE Set the scheduling priority of mysqld + --nowatch Exit after starting mysqld --plugin-dir=DIR Plugins are under DIR or DIR/VERSION, if VERSION is given --skip-kill-mysqld Don't try to kill stray mysqld processes @@ -140,8 +142,16 @@ ;; esac - #echo "Running mysqld: [$cmd]" - eval "$cmd" + if test $nowatch -eq 1 + then + # We'd prefer to exec $cmd here, but SELinux needs to be fixed first + #/usr/bin/logger "Running mysqld: $cmd" + eval "$cmd &" + exit 0 + else + #echo "Running mysqld: [$cmd]" + eval "$cmd" + fi } shell_quote_string() { @@ -198,6 +208,7 @@ fi ;; --nice=*) niceness="$val" ;; + --nowatch) nowatch=1 ;; --open-files-limit=*) open_files="$val" ;; --open_files_limit=*) open_files="$val" ;; --skip-kill-mysqld*) KILL_MYSQLD=0 ;;