Difference between revisions of "MySQL Installation/Configuration"
Jump to navigation
Jump to search
(Created page with "== Useful Commands == killall mysqld mysqld_safe ps aux | grep mysqld killall -9 mysqld mysqld_safe sudo systemctl stop mysqld") |
|||
| (2 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
== Useful Commands == | == Useful Commands == | ||
| + | killall mysqld mysqld_safe | ||
| + | ps aux | grep mysqld | ||
| + | killall -9 mysqld mysqld_safe | ||
| + | sudo systemctl stop mysqld | ||
| − | |||
| − | + | == Reset Root == | |
| + | sudo mysqld_safe --skip-grant-tables & | ||
| + | mysql -u root | ||
| + | show databases; | ||
| − | + | use mysql; | |
| + | update user set authentication_string=PASSWORD("mypassword") where User='root'; | ||
| + | flush privileges; | ||
| + | quit | ||
| − | sudo systemctl stop mysqld | + | sudo systemctl stop mysqld |
| + | sudo systemctl start mysqld | ||
| + | |||
| + | ==Backup == | ||
| + | #In normal linux shell | ||
| + | mysqldump -u root -p aposo_site1 > aposo_site1_bkp2.sql | ||
Latest revision as of 12:59, 11 March 2021
Useful Commands
killall mysqld mysqld_safe ps aux | grep mysqld killall -9 mysqld mysqld_safe sudo systemctl stop mysqld
Reset Root
sudo mysqld_safe --skip-grant-tables & mysql -u root show databases;
use mysql;
update user set authentication_string=PASSWORD("mypassword") where User='root';
flush privileges;
quit
sudo systemctl stop mysqld sudo systemctl start mysqld
Backup
#In normal linux shell mysqldump -u root -p aposo_site1 > aposo_site1_bkp2.sql