Jump to content
View in the app

A better way to browse. Learn more.

The Uniform Server Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Database access denied with php v7.3 on a new USZ installation

Featured Replies

Hi everyone, I'm new to USZ. I installed the latest version and added the module for php 7.3 as the documentation says. I specify that the /www folder has nothing inside except the files of the first installation and that the mysql password is the default one. I have no problem accessing the database with 8.3, however with 7.3 I have access denied and these errors:

mysqli::real_connect(): The server requested authentication method unknown to the client [caching_sha2_password]

 mysqli::real_connect(): (HY000/2054): The server requested authentication method unknown to the client

 mysqli::real_connect(): The server requested authentication method unknown to the client [caching_sha2_password]

 mysqli::real_connect(): (HY000/2054): The server requested authentication method unknown to the client.

I also tried installing 7.4 and 8.1 and everything works correctly.

Can you help me? How can I solve it?

Hello,

I've tested everything once more, and it all works perfectly well on my side.

Are you using the latest release available here: https://sourceforge.net/projects/miniserver/files/latest/download
As for php 7.3, are you using the 7.3.33 version available here: https://sourceforge.net/projects/miniserver/files/Uniform Server ZeroXV/ZeroXV Modules/ZeroXV_php_7_3_33.exe/download

Try to reset the mySQL password, as described here: https://doc.uniformserver.com/mysql.html#Restore default password (root)

Thanks!

  • Author
13 hours ago, sbourdon said:

Hello,

I've tested everything once more, and it all works perfectly well on my side.

Are you using the latest release available here: https://sourceforge.net/projects/miniserver/files/latest/download
As for php 7.3, are you using the 7.3.33 version available here: https://sourceforge.net/projects/miniserver/files/Uniform Server ZeroXV/ZeroXV Modules/ZeroXV_php_7_3_33.exe/download

Try to reset the mySQL password, as described here: https://doc.uniformserver.com/mysql.html#Restore default password (root)

Thanks!

Thanks sbourdon for the reply. 

I've followed the steps you suggested more than once and I'm still having the problem with 7.3. I can't even view the MySQL Error Log as the error message appears:

Editor specified in us_user.ini cant be found.

I specify that I am on a virtual machine with Windows 11 and that I have always started USZ as administrator.

When running PHP version 7.3.x or older, set MySQL 8 Server's default password plugin to mysql_native_password or else you will see errors.
 
In the "core\mysql\my.ini" file, change: authentication_policy = caching_sha2_password to: default_authentication_plugin=mysql_native_password

Using phpMyAdmin, isolate DB User(s) and Host(s) that were created with caching_sha2_password, and change the plugin type from caching_sha2_password to mysql_native_password:
 ALTER USER 'pma'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root';
 ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root';

Hope this helps!

  • Author
41 minutes ago, sbourdon said:

When running PHP version 7.3.x or older, set MySQL 8 Server's default password plugin to mysql_native_password or else you will see errors.
 
In the "core\mysql\my.ini" file, change: authentication_policy = caching_sha2_password to: default_authentication_plugin=mysql_native_password

Using phpMyAdmin, isolate DB User(s) and Host(s) that were created with caching_sha2_password, and change the plugin type from caching_sha2_password to mysql_native_password:
 ALTER USER 'pma'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root';
 ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'root';

Hope this helps!

Thank you again sbourdon!!! I can access the db without errors now and I understand something new.

  • 1 month later...
On 3/19/2024 at 4:45 PM, citrus44 said:

Thank you again sbourdon!!! I can access the db without errors now and I understand something new.

This is very good to know about your good experience.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.