New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cron fails if mysql is not enabled globally #9074
Comments
Ok I really don't know why but after many tries, suddenly it works now... The only thing I did was (like I said in the first post) : enable pdo_mysql.so globally, run the cron (it works) then disable again pdo_mysql.so globally and put it back in the command line. It shouldn't work, but it is. Maybe the cron has to be launched once with pdo_mysql.so enabled globally ? |
The problem appeared again after one or two hours. So I did some tests : -Change adapter to mysqli : same error. It's very strange, nothing changes between the cron, except the error. EDIT : the error is a bit different with 2.15:
|
Maybe this is rather something for our forum http://forum.piwik.org/ ? It seems to be some kind of server configuration problem |
I'm not sure it's a server configuration problem but for the moment I enabled mysql globally. Maybe the cron call php and doesn't use the command line arguments I use ? I tried to look at the source code but I don't have the time now, I'll do it later. |
The database connection shouldn't depend on the arguments you use. Can you maybe paste the command that you use to run the cron? Is only the cron experiencing such issues or also the Piwik UI? Do they both run as the same user? |
I think issue #9258 forward PHP CLI parameters to CLI subrequests, will fix this as well. marking as duplicate |
Hello,
I'm trying to setup cron but I'm facing a strange problem. On my server, pdo_mysql.so is not enabled globally, I enable it in the php engine (with uWSGI) only for websites that need it. Some webapps, like piwik or wordpress, need cron to work well and that's why I have to add in the command line each extension I need.
Here is the command line I want to use :
But I get this error :
It's strange because this method works perfectly with my other webapps. Also, why is there a difference between enabling mysql in php.ini or in the command line ?
The text was updated successfully, but these errors were encountered: