Re: opps ... Deleted perms for root, host localhost
If the root user was the only one with access to the mysql db, then you need to start the server with the option --skip-grant-tables. Then connect with the mysql client and grant new permissions the the root user. Restart the mysqld server normally and connect to the db using the root user.
The pid file gets written when mysqld starts so that the process can be killed. The user that mysqld is run as probably doesn't have write access to the data directory. It should be run as mysql. chown the data directory to mysql:mysql and try to start the server with user=mysql in the configuration file under the section [mysqld]. If you don't have a configuration file, look at the examples in the support-files directory of the mysql installation. I am not exactly sure what that is with RedHat, assuming you used an RPM file. You could check out /usr/local/mysql. The example files are my-huge.cnf, my-large.cnf, my-medium.cnf and my-small.cnf. Copy the appropriate one to /etc and rename it my.cnf. Use whatever one sounds appropriate for your use. There are comments in each one that give hints as to such.
When you get it running, use the link from my previous post to restore the permissions.
There is something going on here. It should not give Access Denied errors when the server is started with --skip-grant-tables. Try starting mysqld straight up with this:
/usr/bin/mysqld --skip-grant-tables &
rather than mysqld_safe. It will return you to the command prompt and you can try to log in using mysql.
I was looking back at your past posts and you said that after you completely reinstalled, you got access denied errors. That should not be. There must be something with the installation. Try uninstalling and reinstalling. If you used an RPM last time, try a tar'd and gzip'd binary installation. If you used that last time, try an RPM this time. Make sure that mysql_install_db gets run. There has to be something going on at that point.
Success! This time I completely removed all MySQL files before doing a clean install. I can't thank you enough for your insight/assistance. I will be very careful w/ root/host/localhost perms in the future.
There's one more way you could have reset your password. When you start the server using
prompt>mysqld_safe --skip-grant-tables &
you can enter mysql without any problem, then
mysql>update user set Password = PASSWORD(<new-password>) where User = 'root';
This would reset your root password.
Then restart the mysql server without --skip-grant-tables option.
Just a add on.