Hi @Rakesh Negi,
Thanks for the response.Given that you've already verified the key points, let's delve deeper into potential causes for the "Access denied for user (using password: YES)" error:
- Ensure that the token being used by the users is not expired. Tokens have a limited lifespan, and an expired token will result in an access denied error.
- Verify that the token has the correct scope. The token should include the necessary permissions to access the MySQL server. Users can obtain the token using the Azure CLI with the appropriate scope.
- Confirm that the users are using the correct format for their User Principal Name (UPN). It should match the format expected by the MySQL server, typically ******@domain.com.
- Double-check the server configuration to ensure that it is set to allow Microsoft Entra authentication. The aad_auth_only parameter should be set correctly based on your authentication mode.
- Ensure that there are no firewall rules blocking the connection from the users' IP addresses. The MySQL server should be accessible from the users' network.
- Verify that MySQL Workbench is configured correctly to use the token as the password. Sometimes, configuration issues in the client tool can lead to authentication errors. For more information, please refer the documents:
https://learn.microsoft.com/en-us/azure/mysql/flexible-server/how-to-azure-ad
https://learn.microsoft.com/en-us/azure/mysql/flexible-server/concepts-azure-ad-authentication
Hope this helps. Do let us know if you any further queries.
If this answers your query, do click Accept Answer
and Yes
for was this answer helpful. And, if you have any further query do let us know.