MySQL database password is always randomly generated

8 posts / 0 new
Last post
#1 Wed, 09/28/2011 - 07:01
fade2gray

MySQL database password is always randomly generated

Virtualmin GPL 3.88

When creating a virtual server using the Default Template and Default Plan, the resulting MySQL database password is always randomly generated no matter if I set "Keep MySQL and administration passwords in sync?" to yes or no.

After creating the virtual server and going to Edit Databases -> Passwords, I see "This form can be used to change the primary database passwords for this virtual server. By default they are kept the same as the server's administration password." - but the displayed database password is not the same as the administrative password.

How can the administrative and database passwords be kept the same by default without manual intervention?

Thanks for any advice.

Wed, 10/24/2012 - 20:18
marco1492
marco1492's picture

I have the same problem

Wed, 10/24/2012 - 20:24
marco1492
marco1492's picture

I am facing the same problem. Maybe as the user password and the root password are identical Virtualmin doesn't allow that and generates a random password....

Wed, 10/24/2012 - 22:09
andreychek

Howdy,

The issue you're seeing is intentional, and is due to using hashed passwords.

If you selected the hashed passwords option while setting up Virtualmin, MySQL users will indeed use randomly generated passwords... if they weren't using random passwords, that would negate the benefit of using hashed passwords, since that MySQL password is stored in plain text.

-Eric

Wed, 10/24/2012 - 23:01 (Reply to #4)
fade2gray

WOW - I posted this query over a year ago. ;-)

Tue, 11/26/2013 - 21:24 (Reply to #5)
telmodias

Hi there!

I'm just confused, but what does hashed have to do with random ?

Why wouldn't the MySQL password be the hashed version of the inserted password ?

Also, can you tell me, how to get the generated password ? Or is it generated just random with the intention of being reset just afterwards ?

Thanks

— Telmo

Thu, 10/25/2012 - 00:36
marco1492
marco1492's picture

Thanks for the answer Andreychek. Makes absolutely sense what you are saying. Thank you. The issue is solved.

Suggestion for the developers: Well, still, it is not consistent with what the user tells the system... If the user wants automatically identical passwords for his account and MySQL, so be it !!! The system should just do this... and not something else (out of integrity considerations...)

Now the practical application: Each time I generate a new Virtual User, I have to click until the freaking MySQl password and adjust to be identical... takes like twice the time now to setup a new virtual user... this should be changed !!! Clearly.

Sat, 06/24/2017 - 23:54
Freddy63
Freddy63's picture

Here's a quick video on how to find MySQL username and password for a virtual server in Virtualmin, https://www.youtube.com/watch?v=Z7GfuSjbZBg

Topic locked