Secure your mysql

From mx Help Wiki
Jump to: navigation, search

Securing MySQL

(the following instructions adapted from

Change admin password

Changing the database administrator's password (empty by default). First run MySQL (if it is not already):

yourterminal$ mysql -u root -p

when prompted for a password leave it blank (i.e., just hit 'return')

then change the administrator's password as follows:

mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('yournewpaswd');

But replace yournewpaswd (keep the single quotes in there though) with a password that you will not forget.

Personal tools