salar74_a
January 3rd, 2012, 00:18
با سلام وخسته نباشید
وقتی سرور رو تحویل گرفتیم حالا معلوم نبود بعضی چیز هاش نصبه یا خیر ولی وقتی mysql رو ریستارت میکنیم با خطای زیر مواجه میشم
MySQL manager or server PID file could not be found
مشکل از چی میتونه باشه؟
---------- Post added January 3rd, 2012 at 12:18 AM ---------- Previous post was January 2nd, 2012 at 11:09 PM ----------
سلام با جستجو در نت مشکلم حل شد دوستانی که شاید بارشون این مشکل مشابه پیش بیاد میتونند اینجوری حل کنند
.................
Problem - You get these types of errors when you restart mysql MySQL manager or server PID file could not be found! [FAILED]
ERROR! MySQL manager or server PID file could not be found!
/etc/init.d/mysql: /usr/local/bin/hostname: not found
Solution
Well don't panic, just follow these steps to get you out of this situation. Usually has to do with missing your mysql.sock file. This is done from the command line, terminal, or ssh. You will need root access. If you don't have command line or root access because this is on a shared hosting server you will have to contact technical support to fix it.
ps -ef |grep mysql|awk '{print $2}'|xargs kill -9 (This finds and kills all mysql processes)
touch /tmp/mysql.sock Other locations are possible. e.x. /var/tmp/mysql.sock
(creates a new mysql.sock)
chown -R mysql:mysql mysql.sock (Must be in same folder as mysql.sock or specify path)
which mysql (tells you where mysql is. Output might look like this: /usr/local/mysql/bin/mysql)
/etc/init.d/mysql start (Restarts mysql service)
For Hostname not found
# find / -name hostname
/usr/bin/hostname
/usr/ucb/hostname
# ln -s /usr/bin/hostname /usr/local/bin/hostname
# vi /etc/init.d/mysql
find
basedir=
datadir=
change with
basedir=/usr/local/mysql
datadir=/usr/local/mysql/var
# /etc/init.d/mysql start
NOTE: Your paths may be different, make sure you use the paths found by the find hostname command above.
وقتی سرور رو تحویل گرفتیم حالا معلوم نبود بعضی چیز هاش نصبه یا خیر ولی وقتی mysql رو ریستارت میکنیم با خطای زیر مواجه میشم
MySQL manager or server PID file could not be found
مشکل از چی میتونه باشه؟
---------- Post added January 3rd, 2012 at 12:18 AM ---------- Previous post was January 2nd, 2012 at 11:09 PM ----------
سلام با جستجو در نت مشکلم حل شد دوستانی که شاید بارشون این مشکل مشابه پیش بیاد میتونند اینجوری حل کنند
.................
Problem - You get these types of errors when you restart mysql MySQL manager or server PID file could not be found! [FAILED]
ERROR! MySQL manager or server PID file could not be found!
/etc/init.d/mysql: /usr/local/bin/hostname: not found
Solution
Well don't panic, just follow these steps to get you out of this situation. Usually has to do with missing your mysql.sock file. This is done from the command line, terminal, or ssh. You will need root access. If you don't have command line or root access because this is on a shared hosting server you will have to contact technical support to fix it.
ps -ef |grep mysql|awk '{print $2}'|xargs kill -9 (This finds and kills all mysql processes)
touch /tmp/mysql.sock Other locations are possible. e.x. /var/tmp/mysql.sock
(creates a new mysql.sock)
chown -R mysql:mysql mysql.sock (Must be in same folder as mysql.sock or specify path)
which mysql (tells you where mysql is. Output might look like this: /usr/local/mysql/bin/mysql)
/etc/init.d/mysql start (Restarts mysql service)
For Hostname not found
# find / -name hostname
/usr/bin/hostname
/usr/ucb/hostname
# ln -s /usr/bin/hostname /usr/local/bin/hostname
# vi /etc/init.d/mysql
find
basedir=
datadir=
change with
basedir=/usr/local/mysql
datadir=/usr/local/mysql/var
# /etc/init.d/mysql start
NOTE: Your paths may be different, make sure you use the paths found by the find hostname command above.