{"id":135,"date":"2016-06-03T18:46:49","date_gmt":"2016-06-03T18:46:49","guid":{"rendered":"http:\/\/symbioticindia.in\/docu\/?p=135"},"modified":"2016-06-03T18:46:49","modified_gmt":"2016-06-03T18:46:49","slug":"how-to-reset-the-mysql-root-password-forget-the-mysql-root-password","status":"publish","type":"post","link":"http:\/\/symbioticindia.in\/docu\/2016\/06\/03\/how-to-reset-the-mysql-root-password-forget-the-mysql-root-password\/","title":{"rendered":"How to reset the Mysql root password (forget the mysql root password)"},"content":{"rendered":"<div class=\"article-header\">\n<h1 class=\"title entry-title\"><\/h1>\n<\/div>\n<div class=\"article-content entry-content\">\n<div dir=\"ltr\">\n<div><i>How to reset the Mysql root password in case of password forget.<\/i><\/div>\n<div>\n<div class=\"separator\"><a href=\"http:\/\/4.bp.blogspot.com\/-0jYyTecIj2E\/VV8G1-tmpZI\/AAAAAAAAATw\/4bHKrZoZl3Q\/s1600\/mysql_rootpassword_reset.PNG\"><img decoding=\"async\" src=\"http:\/\/4.bp.blogspot.com\/-0jYyTecIj2E\/VV8G1-tmpZI\/AAAAAAAAATw\/4bHKrZoZl3Q\/s1600\/mysql_rootpassword_reset.PNG\" border=\"0\" \/><\/a><\/div>\n<p><i><br \/>\n<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>Follow the below steps to reset the mysql password.<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>Step 1 : stop the mysql<\/i><\/div>\n<p><i>*****************************<\/i><\/p>\n<div><i>\/etc\/init.d\/mysql stop<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>it will outputs\u00a0<\/i><\/div>\n<div><i>stopping MySQL database server : mysqld<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>Step 2 : starting the mysql in safemode<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>run the below command to start mysql in safe mode<\/i><\/div>\n<div><i>mysqld_safe &#8211;skip-grant-tables &amp;<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>the above command outputs as<\/i><\/div>\n<div><i>[1]5988<\/i><\/div>\n<div><i>Starting mysqld daemon with databases from \/var\/lib\/mysql<\/i><\/div>\n<div><i>mysqld_safe[6025]: started<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>Step 3 : logging to mysql<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>mysql -u root\u00a0<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>output<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i><\/i><\/p>\n<div><i>Welcome to the MySQL monitor. \u00a0Commands end with ; or \\g.<\/i><\/div>\n<p><i><\/i><\/p>\n<div><i>Your MySQL connection id is 1 to server version: 4.1.15-Debian_1-log<\/i><\/div>\n<div>Type &#8216;help;&#8217; or &#8216;\\h&#8217; for help. Type &#8216;\\c&#8217; to clear the buffer.<\/div>\n<div>mysql&gt;<\/div>\n<div><\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>Step 4 : updating new password for mysql root<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div>\n<ul>\n<li>\n<div><i>use mysql<\/i><\/div>\n<\/li>\n<li>\n<div><i>update user set password=PASSWORD(&#8220;yournewpassword&#8221;) where user=&#8217;root&#8217;;<\/i><\/div>\n<\/li>\n<li>\n<div><i>flush privileges<\/i><\/div>\n<\/li>\n<li>\n<div><i>quit<\/i><\/div>\n<\/li>\n<\/ul>\n<\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div>Step 5 : Stop and Start the mysql<\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>\/etc\/init.d\/mysql stop<\/i><\/div>\n<div><i>\/etc\/init.d\/mysql start<\/i><\/div>\n<div><i>\u00a0<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>Step 6 : login to mysql with new password<\/i><\/div>\n<div><i>*****************************<\/i><\/div>\n<div><i>mysql -u root -p yournewpassword<\/i><\/div>\n<div><\/div>\n<div>*****************************<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>How to reset the Mysql root password in case of password forget. \u00a0 Follow the below steps to reset the mysql password. \u00a0 ***************************** Step 1 : stop the mysql ***************************** \/etc\/init.d\/mysql stop \u00a0 it will outputs\u00a0 stopping MySQL database server : mysqld \u00a0 ***************************** Step 2 : starting the mysql in safemode ***************************** run ..<\/p>\n<div class=\"clear-fix\"><\/div>\n<p><a href=\"http:\/\/symbioticindia.in\/docu\/2016\/06\/03\/how-to-reset-the-mysql-root-password-forget-the-mysql-root-password\/\" title=\"read more...\">Read more<\/a><\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[13],"tags":[],"class_list":["post-135","post","type-post","status-publish","format-standard","hentry","category-mysql"],"_links":{"self":[{"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/posts\/135","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/comments?post=135"}],"version-history":[{"count":1,"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/posts\/135\/revisions"}],"predecessor-version":[{"id":136,"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/posts\/135\/revisions\/136"}],"wp:attachment":[{"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/media?parent=135"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/categories?post=135"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/symbioticindia.in\/docu\/wp-json\/wp\/v2\/tags?post=135"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}