MySQL Tips: Howto change the MySQL root password
Here is a quick tip that will show several methods to change the mysql root password (that is normally empty at mysql initial install).
Method 1: using the SET PASSWORD command:
mysql -u root
mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('newpass');
Method 2: using mysqladmin
mysqladmin -u root password "newpass"
if there was already a mysql root password set, change this to:
mysqladmin -u root password oldpass "newpass"
Method 3: using UPDATE to directly edit the users table
mysql -u root
mysql> use mysql;
mysql> UPDATE user SET Password = PASSWORD('newpass') WHERE User = 'root';
mysql> FLUSH PRIVILEGES;
Langgan:
Catat Ulasan (Atom)
Memulakan Perniagaan Cara WI-FI tiket Prabayar dengan modal hanya RM450.00
MudahSPOT hanya RM450.00. Keperluan 1) Talian Internet Streamyx/3G/WIMAX. Cuma 3G/WIMAX kurang stabil untuk perniagaan 2) Router Kerb...
-
tar -xvf filename.tar foldername/ -compress a folder ===> tar -pczf web.tar.gz /var/www/html 4-april-2010 on sahabat pc router. tar -pc...
-
MudahSPOT hanya RM450.00. Keperluan 1) Talian Internet Streamyx/3G/WIMAX. Cuma 3G/WIMAX kurang stabil untuk perniagaan 2) Router Kerb...
-
detailed instructions on setting LAMP up and once completed you will have a LAMP server that runs: Apache 2 - Linux Web server MySQL 5 - My...
Tiada ulasan:
Catat Ulasan