MySQL starting problem on cPanel Server
Introduction – After fresh installation of cPanel server, Whenever I have tried to start MySQL server, it has failed to start due to unknown reason. This is really crazy problem on cPanel!. Even you upgrade MySQL from 4.0 to latest 5.x version, MySQL server simply failed to start!! You will not find any thing in log file ie ” /var/log/mysql.log“. I have tried so many thing to find out the reason of failure. If you try this cPanel /scripts/mysqlup –force command still it won’t help you.
What is the Solution?
The solution to this crazy problem is to remove or comment out the “basedir=/var/lib” line from my.cnf configuration file of MySQL server.
root@cpanel.arunbagul:~# cat /etc/my.cnf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
[mysql.server]
user=mysql
basedir=/var/lib
[mysqld_safe]
err-log=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
root@server42 [/var/lib]#
root@cpanel.arunbagul:~#
** Finally the /etc/my.cnf file looks like –
root@cpanel.arunbagul:~# cat /etc/my.cnf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
[mysql.server]
user=mysql
[mysqld_safe]
err-log=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
root@cpanel.arunbagul:~#
** Now you can start your MySQL server on cPanel server!!
Cheers,
Arun Bagul
Similar Posts:
- Table types (storage Engine) in MySQL
- cPanel Server – License invalid, while changing IP address or Hostname
- How to upgrade Perl on cPanel Server
- how to reset MySQL root user password with different methods
- How to Transfer account on cPanel Server –
- Introduction to cPanel (part-1)
- SSH tunneling – for SOCK proxy port forwarding