1

After I downloaded:

  • Wampserver 2.4
  • Apache version 2.4.4
  • PHP version 5.4.12
  • MySQL version 5.6.12

On Wampserver 2.4, make put online -> start all -> click localhost -> click phpMyAdmin.

On phpMyAdmin screen:

Welcome to phpMyAdmin

Language - English

Log in

Username

Password

phpMyAdmin requires username and password.

I did not make any username and password for phpMyAadmin.

I had no idea, but if I insert some user name and password, it says:

1045 cannot log in to the MySQL server

Please let me know what I did wrong.

For your reference, wamp\apps\phpmyadmin4.0.4\config.in.php code:

<?php
    /* vim: set expandtab sw=4 ts=4 sts=4: */
    /**
     * phpMyAdmin sample configuration, you can use it as base for
     * manual configuration. For easier setup you can use setup/

 *
 * All directives are explained in documentation in the doc/ folder
 * or at <http://docs.phpmyadmin.net/>.
 *
 * @package PhpMyAdmin
 */

/*
 * This is needed for cookie based authentication to encrypt password in
 * cookie
 */
$cfg['blowfish_secret'] = 'a8b7c6d'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */

/*
 * Servers configuration
 */
$i = 0;

/*
 * First server
 */
$i++;
/* Authentication type */
$cfg['Servers'][$i]['auth_type'] = 'cookie';
/* Server parameters */
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['compress'] = false;
/* Select mysql if your server does not have mysqli */
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['AllowNoPassword'] = true;

/*
 * phpMyAdmin configuration storage settings.
 */

/* User used to manipulate with storage */
// $cfg['Servers'][$i]['controlhost'] = '';
// $cfg['Servers'][$i]['controluser'] = 'pma';
// $cfg['Servers'][$i]['controlpass'] = 'pmapass';

/* Storage database and tables */
// $cfg['Servers'][$i]['pmadb'] = 'phpmyadmin';
// $cfg['Servers'][$i]['bookmarktable'] = 'pma__bookmark';
// $cfg['Servers'][$i]['relation'] = 'pma__relation';
// $cfg['Servers'][$i]['table_info'] = 'pma__table_info';
// $cfg['Servers'][$i]['table_coords'] = 'pma__table_coords';
// $cfg['Servers'][$i]['pdf_pages'] = 'pma__pdf_pages';
// $cfg['Servers'][$i]['column_info'] = 'pma__column_info';
// $cfg['Servers'][$i]['history'] = 'pma__history';
// $cfg['Servers'][$i]['table_uiprefs'] = 'pma__table_uiprefs';
// $cfg['Servers'][$i]['tracking'] = 'pma__tracking';
// $cfg['Servers'][$i]['designer_coords'] = 'pma__designer_coords';
// $cfg['Servers'][$i]['userconfig'] = 'pma__userconfig';
// $cfg['Servers'][$i]['recent'] = 'pma__recent';
/* Contrib / Swekey authentication */
// $cfg['Servers'][$i]['auth_swekey_config'] = '/etc/swekey-pma.conf';

/*
 * End of servers configuration
 */

/*
 * Directories for saving/loading files from server
 */
$cfg['UploadDir'] = '';
$cfg['SaveDir'] = '';

/**
 * Defines whether a user should be displayed a "show all (records)"
 * button in browse mode or not.
 * default = false
 */
//$cfg['ShowAll'] = true;

/**
 * Number of rows displayed when browsing a result set. If the result
 * set contains more rows, "Previous" and "Next".
 * default = 30
 */
//$cfg['MaxRows'] = 50;

/**
 * disallow editing of binary fields
 * valid values are:
 *   false    allow editing
 *   'blob'   allow editing except for BLOB fields
 *   'noblob' disallow editing except for BLOB fields
 *   'all'    disallow editing
 * default = blob
 */
//$cfg['ProtectBinary'] = 'false';

/**
 * Default language to use, if not browser-defined or user-defined
 * (you find all languages in the locale folder)
 * uncomment the desired line:
 * default = 'en'
 */
//$cfg['DefaultLang'] = 'en';
//$cfg['DefaultLang'] = 'de';

/**
 * default display direction (horizontal|vertical|horizontalflipped)
 */
//$cfg['DefaultDisplay'] = 'vertical';


/**
 * How many columns should be used for table display of a database?
 * (a value larger than 1 results in some information being hidden)
 * default = 1
 */
//$cfg['PropertiesNumColumns'] = 2;

/**
 * Set to true if you want DB-based query history.If false, this utilizes
 * JS-routines to display query history (lost by window close)
 *
 * This requires configuration storage enabled, see above.
 * default = false
 */
//$cfg['QueryHistoryDB'] = true;

/**
 * When using DB-based query history, how many entries should be kept?
 *
 * default = 25
 */
//$cfg['QueryHistoryMax'] = 100;

/*
 * You can find more configuration options in the documentation
 * in the doc/ folder or at <http://docs.phpmyadmin.net/>.
 */
?>
Community
  • 1
  • 1
Happy
  • 23
  • 1
  • 1
  • 5
  • 1
    If you didn't put in any username/password during installation, your default username should be **root** and when prompted for password, just press the enter key. that should work. – Kneel-Before-ZOD Nov 06 '13 at 19:59

3 Answers3

7

Log in using the default password:

Username: root

Password: [null]

With [null] I mean no password at all.

Community
  • 1
  • 1
Joren
  • 3,068
  • 25
  • 44
  • Dear Chris: Thank you for your response. I did type "root in username and "null" in password. but I still have same error. could you please let me know what other option do I have. Thank you – Happy Jul 29 '13 at 13:46
  • 1
    With [null] I mean no password at all – Joren Jul 29 '13 at 14:02
  • Also, my name is Joren. The name of the editor of your post is Chris. – Joren Jul 29 '13 at 14:03
  • If this answered your question, please mark this answer as the accepted answer by clicking the check-mark under the vote counter. – Joren Aug 05 '13 at 20:34
  • @joren when i create a new user and try to login with it. the error 1045 appears. what to do ? – adeel iqbal Dec 03 '13 at 08:36
  • 1
    @adeeliqbal See http://stackoverflow.com/questions/489119/mysql-error-1045-access-denied – Joren Dec 03 '13 at 10:41
  • @Joren thanks for your support. +1 for thanks. but my issue is not yet resolved. can we have some chat? – adeel iqbal Dec 03 '13 at 16:48
  • @Joren i want to login using the new user i have created. but when i give user and password in phpmyadmin. it gives error 1045 and user can't login. what could be the issue. i have just installed a new fresh wamp 2.4 – adeel iqbal Dec 03 '13 at 16:52
1

After installation, on Start Menu, Try right click on "start WampServer" and "Run as Administrator". Then can login to MySQL (PHPMyAdmin) as root without any password .

(In my case, the installation on a windows 7 machine was done by a user with admin role. But when I tried to click on "start WampServer" it would only go upto orange. After searching a few blogs which pointed at changing certain config file, the above occurred to me, and it worked).

lasa108
  • 11
  • 1
0

1) Open your MySQL console - using wamp , left click your WAMP icon located at the bottom right of your desktop and click on MySQL Console You will be prompted to enter a password , if you have one you can ignore the following steps

Press ENTER Type in: use mysql

Press ENTER

2) Enter the following on the command line

To set your MySQL Password: UPDATE mysql.user SET Password=PASSWORD("EnterYourPasswordHere") WHERE User="root"; Replace "EnterYourPasswordHere" with your new chosen password.

Press ENTER.

Flush the privileges: Type FLUSH PRIVILEGES;

Exit by typing : Exit

then ENTER

3) Open and Edit your config.inc.php file located in your local sever files

Go to My Computer > C Drive > (Your Local Server Folder, WAMP/MAMP/XAMPP) > APPS > PHPMYADMIN > config.inc.php Find this line of code: $cfg['Servers'][$i]['password'] = ''; // MySQL password

Change 'password' to the new chosen password you created from Step 2.

Click Save.

4) You can access phpMyAdmin by going to http://localhost/phpMyAdmin/.

Congratulations! You are now able to access your databases.