Mysql root passwd
1.Stop the mysql server.
/etc/init.d/mysqld stop
2.Start the mysql daemon with –skip-grant-tables option. --
mysqld_safe --skip-grant-tables&
3.Login to the server as root user.
[root@alpha ~]# mysql -u root
Welcome to the MySQL monitor. Commands end with ; or \g. our MySQL connection id is 1 Server version: 5.0.77 Source distribution Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> 4.Reset the mysql root password using the following commands. -- mysql> use mysql; mysql> update user set password=PASSWORD("New root pass") where User='root'; mysql> flush privileges; mysql> quit -- « Dispersed Storage Adding multiple virtual network interfaces in Ubuntu » Reset mysql root password
Sometimes in some situations we forget some important things in their life LOL.So today I’m gonna share how to reset the reset the mysql root password.The steps are here.
1.Stop the mysql server.
/etc/init.d/mysqld stop
2.Start the mysql daemon with –skip-grant-tables option.
mysqld_safe --skip-grant-tables&
3.Login to the server as root user.
[root@alpha ~]# mysql -u root
Welcome to the MySQL monitor. Commands end with ; or \g.
our MySQL connection id is 1
Server version: 5.0.77 Source distribution
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql>
4.Reset the mysql root password using the following commands.
mysql> use mysql;
mysql> update user set password=PASSWORD("New root pass") where User='root';
mysql> flush privileges;
mysql> quit
5.Stop the mysql daemon and start it again. /etc/init.d/mysqld stop
/etc/init.d/mysqld start
--Subhash 12:52, 29 September 2012 (IST)