On Tue, 2005-07-05 at 05:33 +0000, Karia Amit wrote:
Hi,
I Have lost root password for mysql , I have got mysql daemon started in my machine , I have tried to login to mysql using the following command mysqladmin -u root -p <password> it just doesnt Allow me to login, Please let me know how do i change the root password for mysql
Unless you are running exotic tables on MySQL all the databases should be in their respective directories. You can copy these after stopping MySQL and keep them seperately. You can also use hotcopy when MySQL is running.
Then re-instantiate the orginial table structure by deleting everything in your data directory using msql_install_db. Copy back the backed up databases change permissions and you are in business.
However, this way you WILL lose all user-account data for MySQL. It pays to keep a bac-up of the mysql database - in case you remember the password later.
HTH,
ah
regards Amit