XAMPP default MySQL password settings, modify the default null password for MySQL

Source: Internet
Author: User
Tags phpmyadmin

xampp default MySQL password settings, modify the default null password for MySQLCategory: Xampp2012-09-12 11:24 30264 People read Comments (5) favorite reports Mysqlphpmyadminauthentication database management Tools Database extension

I used to develop it all the time. Appserv,appserv is a key installation, installation will require users to enter the root password of MySQL. Today I switched to XAMPP as my development environment, so I encountered the problem of modifying the MySQL default blank password.

I looked at the internet to provide some help information, make so complex, in fact, there is no need, I have a simple approach, in fact, is essentially the same, the following is my method:

Because the MySQL default password after installing XAMPP is empty, so we can log in to phpMyAdmin, enter Http://localhost/phpmyamdin into the database Control Panel on the browser address, then choose the name of MySQL database, You can see from the user table that the password for root two users is empty.

We can manually edit the root user's password in the database. Click Quick Edit, or edit can edit password, such as password: 123456, then fill in "*6bb4837eb74329105ee4568dda7dc67ed2ca2ad9" (except quotation marks)

After editing as

If you want to change the password to another, you can directly execute the west of the SQL statement, the new_password changed to their own password can be:

1 UPDATE user SET password=PASSWORD(‘new_password‘) WHERE user=‘root‘;

In addition, since MySQL root user password has been modified, then the corresponding password configuration in the phpMyAdmin also to modify, find the configuration file, such as mine is:
F:\xampp\phpMyAdmin\config.inc.php
Find the following code

123456 /* Authentication type and info */$cfg[‘Servers‘][$i][‘auth_type‘] = ‘config‘;$cfg[‘Servers‘][$i][‘user‘] = ‘root‘;$cfg[‘Servers‘][$i][‘password‘] = ‘‘;$cfg[‘Servers‘][$i][‘extension‘] = ‘mysql‘;$cfg[‘Servers‘][$i][‘AllowNoPassword‘] = true;

Revision changed to

123456 /* Authentication type and info */$cfg[‘Servers‘][$i][‘auth_type‘] = ‘config‘;$cfg[‘Servers‘][$i][‘user‘] = ‘root‘;$cfg[‘Servers‘][$i][‘password‘] = ‘123456‘;$cfg[‘Servers‘][$i][‘extension‘] = ‘mysql‘;$cfg[‘Servers‘][$i][‘AllowNoPassword‘] = true;

Of course, you do not change this database will work as usual, but phpMyAdmin is a database management program, we need to use it to create a management database, and so on, if you use other database management tools such as Navicat, you can do without the tube phpmyadmin, Because Phpmyamdin and navicat have the same effect.

    • Previous post MyEclipse 10 How do I install svn?
    • The next HTML-like effect of a radio button

XAMPP default MySQL password settings, modify the default null password for MySQL

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.