Forums

mysql connection fails from schedule, but not from bash

I have a schedule script for web2py to send emails in the background: python2.7 /home/ykamarjanen/web2py/web2py.py -S app -M -R /home/ykamarjanen/app/modules/script.py

Until last wednesday the script worked fine and was able to connect to the database and send emails. However then it started to give error: "OperationalError: (2003, "Can't connect to MySQL server on 'mysql.server' (111)").

When I execute the same script from bash console with the same command, it works. But when I use schedule to execute it, it doesn't work.

Has something changed recently or have I missed something?

Ykä

Apologies, it looks like we had an outage with the mysql proxy server on the task server. I've given it a kick, see if things are better now?

Hi Harry,

seems to work now. Thanks.

Ykä