Sponsor:

Server and Web Integrator
Link:
Kloxo-MR logo
6.5.0 or 7.0.0
Click for "How to install"
Donation/Sponsorship:
Kloxo-MR is open-source.
Donate and or Sponsorship always welcome.
Click to:
Click Here
Please login or register. 2024-03-29, 12:38:45

Author Topic: mysqld restart needs also mysqld_safe  (Read 1955 times)

0 Members and 1 Guest are viewing this topic.

Offline Spacedust

  • Super Grand Master
  • ****
  • Posts: 4,050
  • Karma: +1/-0
    • View Profile
mysqld restart needs also mysqld_safe
« on: 2016-03-12, 17:17:19 »
Should be:

Quote
#!/bin/sh

echo "*** Process for MYSQL/MARIADB service ***"

if [ -f /etc/rc.d/init.d/mysql ] ; then
   if [ "$(/etc/rc.d/init.d/mysql status|grep pid)" == "" ] ; then
      /etc/rc.d/init.d/mysql start
   fi
   sleep 1
elif [ -f /etc/rc.d/init.d/mysqld ] ; then
   if [ "$(/etc/rc.d/init.d/mysqld status|grep pid)" == "" ] ; then
      /etc/rc.d/init.d/mysqld start
   fi
   sleep 1
else
   echo "  - No need started"
fi

echo "  - Process: restart"
if [ -f /etc/rc.d/init.d/mysql ] ; then
   /etc/rc.d/init.d/mysql stop
   pkill -9 mysql
   pkill -9 mysql_safe
   /etc/rc.d/init.d/mysql start
elif [ -f /etc/rc.d/init.d/mysqld ] ; then
   /etc/rc.d/init.d/mysqld stop
   pkill -9 mysqld
   pkill -9 mysql_safe
   /etc/rc.d/init.d/mysqld start
fi
echo "No message for restart"

 


MRatWork Affiliates:    BIGRAF(R) Inc.    House of LMAR    EFARgrafix
Click Here

Page created in 0.068 seconds with 21 queries.

web stats analysis