WAMP server PhpMyAdmin not authenticating with valid credentials - php

WAMP server MySQL is working fine in CLI. But PHPMyAdmin is not working. I had MySQL and workbench installed with 3306 port (before I install the WAMP server). This is why My WAMP server MySQL wasn't working, I changed the port to 3309 in MySQL my.ini file, it's working fine in CLI but not working in PHPMyAdmin.
I have already tried alter user 'username'#'localhost' identified with mysql_native_password by 'password'; still not working in with PHPMyAdmin but CLI. I don't want to downgrade my MySQL version.
MySQL Version 8.0.21
ERROR:

If you must have 2 MySQL instances running then use the features built into WAMPServer to amend the MySQL port number
RIGHT Click on the WAMPServer icon in the system tray and click the TOOLS menu item
See below, then click on "Use port other than 3306" and WAMPServer will update ALL the required files so that you can use a non standard port for MySQL

Search for libraries/config.default.php
and change
$cfg['Servers'][$i]['port']
it should be empty default is 3306 and add 3309
Addinally you have to run the installer again
executing the install file
select "Reconfigure" over the mysql server
In Authentication Method tab, select "Use Legacy Authentication
Method"

You can choose at the beginning the MariaDB server and on username type root, and password remains empty, after once you will be connected with Maria Db, switcher to MySQL ,
screenswitcherserver
and do the same thing side username and password

Related

xammp and wordpress installation for the first time

I had already installed mysql ,and later i installed the xammp the apache is starting but mysql is not starting so i changed the port to 3307,cahging the port from 3306 to 3307 helped to start the mysql,the next problem i faced was while installing wordpress, i created a database and even after filling in the username password and host detalis correctly it says "Error establishing a database connection" in the root directory of wordpress there is a file 'wp-config-sample.php'.
How do i establish connection with the mysql database?

mysqli_real_connect(): (HY000/2006): MySQL server has gone away

I am having an issue with logging into phpMyAdmin.
I have simply install xampp.
when i launch the Xampp server it show me port error for 3306
so i have change the port from 3306 to 3307
in my.ini file and
config -> Service and Port Settings -> Mysql port Tab
Service Setting of Xampp Control Panel
Then i was able to start SQL server
when i try to open PhpMyadmin it show me error like this
than i change in config.inc.php
config.inc.php
Now when i try to open PhpMyadmin it ask me for username and password
Username - root
Password - Null
it show me error like this
Error while login in PhpMyadmin
Please Help me to find an issue
Thanks in advance
Since you are in the very early stages of using xampp and
NO development has been completed;
Uninstall xampp and remove ALL the MySQL* programs, Shutdown/Restart Windows 10.
Reinstall xampp. Verify functionality.
For additional assistance, view my Profile, Network profile, for contact information including my Skype ID and get in touch with me, please.

mysql Cannot connect: invalid settings

My phpMyAdmin stopped connecting to mySQL suddenly with the following error:
Error MySQL said: Documentation
Cannot connect: invalid settings. phpMyAdmin tried to connect to the
MySQL server, and the server rejected the connection. You should check
the host, username and password in your configuration and make sure
that they correspond to the information given by the administrator of
the MySQL server.
I am running MAMP with php7 on a MAC.
I have checked my config.inc.php setting and both user and password
are set to root.
I have checked the httpd.conf file and changed the port from 8888 to 80
I have also reverted back on mamp controlpanel from php 7 to php
5.6.10.
And always stopped apache and restarted between changes. None of these changes have had any effect. Really don't understand why it suddenly stopped working.
I can still access mysql from Sequel Pro and MySQLWorkbench.
Thankful for any suggestions :)

How to connect MySQL workbench to database

I'm trying to use mysql workbench to get access the database in my office. My friend has already helped me setup the connection in PuTTY, so I can write my MySQL script in that "black and white" window. However when I try to use MySQL workbench to get connection to the database, it causes error. It says:
Failed to Connect to MySQL at 127.0.0.1:3306 with user martin (I tried root as well)
Can't connect to MySQL server on '127.0.0.1' (10061)
I know there are a lot of questions and answers about this on stackoverflow. I tried some of them but without any luck.
I'm thinking do I need something called mysqld.exe in a certain directory? I have downloaded the file but when I double click it nothing happens. Do I need to run that as an administrator? One of my friends told me I don't need that at all. So what should I do now?
Any clue please enlighten me. Thanks heaps!!
To connect to your MySQL database with Workbench software you should do the following:
Open your Workbench application >> Database >> Connect to database. Setup window will show up, please fill out the fields as follows:
SSH Section
Connection Method: Standard TCP/IP over SSH
SSH Hostname: OFFICE-SERVER-IP
SSH Username: SSH-USERNAME-HERE
SSH Password: SSH-PASSWORD-HERE
Mysql Section
MySQL Hostname: 127.0.0.1
MySQL Server Port: 3306
Username: MYSQL-USERNAME-HERE
Password: MYSQL-PASSWORD-HERE
Just For Ilustration purposes your configuration should look something like this:
Seems like you are trying to access the Mysql server running on your local machine in your example. The MySQL at 127.0.0.1 means connect to a mysql server running on the local machine.
If you are on the same network as the server and your Mysql server is set up to allow access from a second machine you need to enter the ip address of the machine that the Mysql server is running on for instance 192.168.1.210:3360 means connect to the machine at Ip address 192.168.1.210 using the default Mysql Port of 3360. Your Putty setup should have the ip address of the machine you need to connect to.

WAMP phpmyadmin error

I just installed WAMP server and for creating a new local database, when I clicked phpMyAdmin, i am getting this error,
Error
MySQL said: Documentation
1045 - Access denied for user 'root'#'localhost' (using password: YES)
phpMyAdmin tried to connect to the MySQL server, and the server rejected the connection. You should check the host, username and password in your configuration and make sure that they correspond to the information given by the administrator of the MySQL server.
Can some one please help me??
you are connecting to your local machine. If i am correct wamp does not set any credentials. So you should be fine to login with root and no password.
It's been a while since I have used WAMP (I only use Linux and OSX these days) I seem to remember the following...
In a command prompt enter in the mysql directory :
mysqladmin -u root password NEWPASSWORD
By default a mysql root password is not set yet the phpmyadmin pages are set to to connect with a password.
Dave
If you user has not password connect so. Try do it:
mysql_connect('server','user');
without thrid parameter. If all is right, you are connect to server.
else, if your user has password, you need provide the password correct
mysql_connect('server','user','password_correct');

Categories