Skip to content

Instantly share code, notes, and snippets.

@dlwhitehurst
Created January 15, 2015 19:33
Show Gist options
  • Save dlwhitehurst/1b2ea6e700aa1b007b60 to your computer and use it in GitHub Desktop.
Save dlwhitehurst/1b2ea6e700aa1b007b60 to your computer and use it in GitHub Desktop.
Reset Root Password MariaDB on CentOS-7
e.g. only
$ mysqld_safe --skip-grant-tables --skip-networking &
[1] 22411
# 140603 11:57:04 mysqld_safe Logging to syslog.
140603 11:57:04 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
$ mysql -u root
mysql> use mysql;
mysql> update user set password=PASSWORD("new-password") where User='root';
mysql> flush privileges;
mysql> exit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment