A way to avoid MySQL problems

I just installed Piwik and am glad to head toward losing the chains of Google. It never felt right using it.

I’m not a programmer so please bear with me.

I have a dedicated managed server running CentOS. After installing Piwik it alerted me that my PHP version was not up to date (I believe I had 5.13 installed). I alerted the techs and they updated PHP to 5.4 as suggested and also updated Apache to the latest stable release since it was out of date. While not requested by Piwik, it seemed best to have the latest release.

At that point I got an error that MySQL would not accept the information for the database with the following error:

Error while trying to connect to the database server: SQLSTATE[HY000] [2000]
mysqlnd cannot connect to MySQL 4.1+ using the old insecure authentication.
Please use an administration tool to reset your password with the command SET
PASSWORD = PASSWORD('your_existing_password'). This will store a new,
and more secure, hash value in mysql.user. If this user is used in other
scripts executed by PHP 5.2 or earlier you might need to remove the
old-passwords flag from your my.cnf file

I also should note that wordpress installs also could no longer accept passwords but IPB (proprietary system I am looking to replace) had no trouble with logins on a different domain on the same server. I don’t think this is a bug, it may be a security feature or the lack of a feature which is why I’m here. Piwik installer does however still show my PHP version being 5.13RC.

For someone very familiar with the OS this would probably be an easy fix. For someone like me, I’m still waiting for it to get fixed by the techs who’s efforts so far have failed. Something they changed fixed one domain but installing to another domain won’t work now at all. And while it is not Piwik’s fault that my Apache update caused the problem (at least that’s what it seems to be), since mysql goes hand-in hand it would be great to have a feature for admins with small servers and little knowledge of the OS to get by this quickly, or a simple tool we could run to get the database working properly. If there exists such a thing, please by all means let me know where it is.

This may be impossible but I have no way of knowing. I also want to contribute to Piwik’s development so I can use free software to run my analytics so figured it couldn’t hurt to ask.


Please upgrade your mysql server, it is really old.

I checked with the techs and I’m currently running mysql 5.0

They are going to upgrade to 5.1 and then 5.5 so it’s up to date. Hopefully this will avoid any problems.


Maybe you were using Mysql 4.1 since the message mentions it “mysqlnd cannot connect to MySQL 4.1”

No, I was definitely using 5. I had them upgrade it back in Jan or Feb of this year.

When they upgraded PHP there were also some other things that needed recompiling (memcache, ffmpeg, imagemagick) which caused some unrelated problems.

Unfortunately I also just found out I can’t get past mysql 5.1 because my install of CentOS reached its end of life. I need to have my whole server upgraded basically, it is out of date. I did get Apache updated though, but WHM and CPanel are also not able to upgrade until I overhaul the server.

At any rate, Piwik does seem to be working fine now. I installed it on 3 sites and they are registering activity. Hopefully the gods will smile upon me and more projects will come in so I can get all my stuff up to date. :slight_smile: Now that Piwik is up and running and I’ve used it a bit, I’m getting some good design ideas that I’ll share with the community. I think it’s headed in the right direction and will become a very powerful tool.