How to Test Database Access in Mysql

Tech Guru Add comments
55

The steps outlined earlier are a good test of database access. If the application fails, then retrace your steps to create the database and register the database information into the application. MySQL errors are logged automatically in the /var/log/mysqld.log file; investigate this file at the first sign of trouble.

Sometimes MySQL will fail to start because the host table in the mysql database wasn’t created during the installation, this can be rectified by running the mysql_install_db command.

[root@bigboy tmp]# service mysqld start
Timeout error occurred trying to start MySQL Daemon.
Starting MySQL:  [FAILED]
[root@bigboy tmp]# tail /var/log/mysql.log
...
...
050215 19:00:33  mysqld started
050215 19:00:33  /usr/libexec/mysqld: Table 'mysql.host' doesn't exist
050215 19:00:33  mysqld ended
...
...
[root@bigboy tmp]# mysql_install_db
...
...
[root@bigboy tmp]# service mysqld start
Starting MySQL:  [  OK  ]
[root@bigboy tmp]#

Tags:, , ,

Liked this article? To continue getting our latest free Howtos and Tutorials,
you can also grab the RSS feed or Subscribe to Techgurulive by Email

Not Getting



Leave a Reply



This Howtos posted under" Tech Guru

How to Test Database Access in Mysql


Find Free Howtos and tutorials on apache, Linux, windows, php, Networking, MySQL, Cisco, open source, Nas, Virtualization, voip, vpn, email,send mail, lamp, security, SEO, squid, Anti virus, Backup, Database and many more