Koozali.org: home of the SME Server

mysql root password after update to V5.5

ndejean

mysql root password after update to V5.5
« on: November 04, 2002, 06:08:00 PM »
Hi,

I recently updated an e-smith server V5.0 with all updates installed to V5.5 with updates 1 and 2 installed.

Since the upgrade I could not connect anymore to mysql database as root with th normal password.

The only way to connect was to be user root, then run mysql without password that allowed me to connect without giving the normal password.

I then ran "select password('the_normal_password')" and compared it with the one stored in mysql.user table. It is not the same, what explains why I could not connect.

But why isn't it the same ??? Is this linked ti the upgrade of SSL libraries ???

Once connected, I changed the password for the new one (the same differently encrypted) and could connect as usual.
But I cannot connect anymore as root user without specifying a password.

I believe that mysql had been almost reset like after a fresh install. The only difference was that only root had lost its password and was allowed to connect without specifying it ...

If someone could help me to understand what happened ...

Thanks by advance,

Nicolas Déjean.


ndejean

Re: mysql root password after update to V5.5
« Reply #2 on: November 04, 2002, 06:56:42 PM »
Thanks Dan,

but I had read it before posting ... (I also had a trip on your site and I was quite interested by the detection of worms attacks ...)

Do you mean by this that each time I will update my SME-Server the root password for mysql will be changed for a 76 chars one ???

I believe this is quite strange because even if it is often unecessary, some applications could use it ....

How an upgrade ca be allowed to change the root password without a word of warning or explanation ???

--------------------------------------

I now hesitate about changing it back as you showed in the howto but maybe if you tell me the kind of changes system makes with this password ...

What really disturb me is that the main aim of mysql access privileges is to draw a line between system users and database users. With such a policy, the system root is also the mysql root ... this is the case on almost servers but not all ....

Is there a solution to keep the 76 chars password for the system and require  password even for root (ideally it should be different from system password but it seems to be difficult to realize as mysql root should accept 2 different passwords) ...

Thanks by advance,

Nicolas Déjean.

Dan Brown

Re: mysql root password after update to V5.5
« Reply #3 on: November 04, 2002, 07:16:54 PM »
Really, there are _very_ few apps which should need to use the mysql root password.  phpmyadmin would be one, but that's the only one I can think of.

As to whether the update changed it, I really don't know.  I wouldn't think it _should_, but I know at some point a version upgrade changed my password from a 6-character random one (which was chosen by the system when _that_ version was installed) to the current long one.

You're right that the users are separate, but even without the /root/.mysql.conf file, the system root user could still get root access to mysql.  As Pitr put it, "root, God, what is difference?"

As to exactly what changes the system makes with this password, I'm frankly not 100% sure.  I know the system sometimes has to add or drop databases, and I'm sure it uses the password for that, but I don't know what else.

ndejean

Re: mysql root password after update to V5.5
« Reply #4 on: November 04, 2002, 08:09:34 PM »
thanks a lot Dan,

I will look further this topic ... and change back the root password ...

Regards,

Nicolas Déjean.

Charlie Brady

Re: mysql root password after update to V5.5
« Reply #5 on: November 04, 2002, 08:27:18 PM »
Dan Brown wrote:

> As to exactly what changes the system makes with this
> password, I'm frankly not 100% sure.  I know the system
> sometimes has to add or drop databases, and I'm sure it uses
> the password for that, but I don't know what else.

It also has to be able to dump database tables to do a backup.
Other than that, adding and dropping databases, and modifying the access table would be about it, Dan.

Charlie

Gerald

Re: phpmyadmin and SME V5.5
« Reply #6 on: November 08, 2002, 10:12:01 PM »
Either and upgrade of SME or phpmyadmin broke my previous version of phpmyadmin. In just installled phpmyadmin 2.3.2. I address it using a static ip. The myadmin login screen comes up but will not accept root as user and the .my.conf password, the long one gererated by SME. Any ideas?
I need phpmyadmin because I have a number of virtual PN sites running on the server and find it necessary, from time to time to modify data base entries. TIA

Gerald

Re: mysql root password after update to V5.5
« Reply #7 on: November 11, 2002, 09:23:52 PM »
I design and support a number of web sites using Post Nike. Many of the modules that I use require that the mysql password. Given the number of databases created it is imperative that I am able to get phpmyadmin backup and running under SME 5.5 any assistance or observations you have would be greatly appreciated.

Pedro

Re: mysql root password after update to V5.5
« Reply #8 on: February 26, 2003, 03:41:05 PM »
[root@e-smith /root] # /etc/rc.d/init.d/mysqld stop
[root@e-smith /root] # /etc/e-smith/events/actions/conf-mysql-password
[root@e-smith /root] # /etc/rc.d/init.d/mysqld start


the above is wrong?