• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Cron failure

GrzegorzSS

New Pleskian
Hello

I have Panel version 11.0.9 Update #63, last updated at Oct 25, 2014 05:14 AM
Yesterday I got following errors :

PHP Warning: mysql_errno() expects parameter 1 to be resource, boolean given; File: /usr/local/psa/admin/plib/common_func.php3, Line: 209

PHP Warning: mysql_errno() expects parameter 1 to be resource, boolean given in /usr/local/psa/admin/plib/common_func.php3 on line 209
PHP Warning: mysql_error() expects parameter 1 to be resource, boolean given in /usr/local/psa/admin/plib/common_func.php3 on line 222
PHP Warning: mysql_errno() expects parameter 1 to be resource, boolean given in /usr/local/psa/admin/plib/common_func.php3 on line 222
PHP Fatal error: Call to a member function getContext() on a non-object in /usr/local/psa/admin/plib/Navigation.php on line 54


and email with such error :


--- Below this line is a copy of the message.

Return-Path: <[email protected]>
Received: (qmail 6153 invoked by uid 501); 26 Oct 2014 21:50:01 +0100
Date: 26 Oct 2014 21:50:01 +0100
Message-ID: <[email protected]>
From: [email protected] (Cron Daemon)
To: [email protected]
Subject: Cron <psaadm@host1> /opt/plesk-billing/task-manager/scripts/run-all.sh --config /opt/plesk-billing/task-manager/config/config.ini
Content-Type: text/plain; charset=UTF-8
Auto-Submitted: auto-generated
X-Cron-Env: <SHELL=/bin/sh>
X-Cron-Env: <HOME=/usr/local/psa/admin>
X-Cron-Env: <PATH=/usr/bin:/bin>
X-Cron-Env: <LOGNAME=psaadm>
X-Cron-Env: <USER=psaadm>

{"result":null,"error":{"code":-32603,"message":"SQLSTATE[08004] [1040] Too many connections","data":{"errorInfo":null}},"id":"","jsonrpc":"2.0"}


Any idea what happaned ? how to fix or check if job has been completed succesfully ?

Tnx
Greg
 
Make sure that option old-passwords = 1 is disabled in the /etc/my.cnf file.
 
I can see it was already disabled take a look :

root@host1 /etc # cat my.cnf
[mysqld]
set-variable=local-infile=0
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
# Forced OLD_PASSWORD format is turned OFF by Plesk
#old_passwords=1
bind-address=127.0.0.1

# Disabling symbolic-links is recommended to prevent assorted security risks;
# to do so, uncomment this line:
# symbolic-links=0
#log=/var/log/mysqld.general.log

[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
 
looks like it's saying you have 'too many connections' to sql and it's denying the additional ones which is then creating warnings when you try to use the connection. so increase your connections or try to get onto phpmyadmin or something to see if you can connect there and look at the code to see if it's releasing connections that it may be creating in a loop or something like that.

may be related, but i'm pretty sure that update #63 included an update to the version of php you're using. newer versions of php are VERY MUCH pickier about not letting things slide that earlier versions did. so as a result almost any php code you run after updating will throw WARNINGS like the ones above that didn't use to generate warnings. a common one is that objects must be declared implicitly like $objectvar = new stdObjectclass; before using them. so you may see some new issues unless you turn off the display of warnings after updating php levels.
 
Back
Top