Steps to reproduce
- Not sure. My hosting company started throttling in June as apparently I’m abusing the service, and their analysis is OC using constant 10 to 20% CPU. Can’t recall making any changes (running 10.0.4), except maybe enabling/disabling Apps in the admin web interface. We don’t use any apps in practice, just the core OC functions from original install.
- I upgraded to 10.0.8 hoping that the issue would go away. Instead my hosting provider has limited my server access (CPU throttling for my domain) after one week, as OC has exceeded the CPU quota for the month
Expected behaviour
OC should just run normally with 3 active users and small file traffic (max 10 file updates per day), without using excessive CPU
Actual behaviour
I get this message in Cpanel ressource Usage Overview:
You have reached entry processes (number of simultaneously running php and cgi scripts, as well as cron jobs and shell sessions) limit 37 times.
I/O usage resources were limited for your site
Also, Webalizer shows that the top URL “hit” on my box is :"/owncloud/ocs/v2.php/apps/notifications/api/v1/notifications" with 9,000++ hits in 22 days.
We are all running OC windows client. No one is accessing web browser client. This amount of hits makes no sense. This URL (and perhaps others, I am not a sysadmin and don’t know what to look for) causes a fairly constant aprox. 10-20% CPU usage throughout the day, which adds up at the end of the month. My hosting provider is not happy with my hosting setup and asking to upgrade to a higher hosting package. Makes no sense, we have very little traffic.
Server configuration
Operating system: Linux
Web server: Apache 2.4.33
Database: My SQL 10.1.34
PHP version: 5.6.36
ownCloud version: 10.0.8
Updated from an older ownCloud or fresh install: Updated from 10.0.4
Where did you install ownCloud from: Softaculous from hosting provider
Signing status (ownCloud 9.0 and above): Don’t understand the question. Pls clarify?
I have no problem to sign in to OC, with Windows and with web client, regular user and admin user
Login as admin user into your ownCloud and access
http://example.com/
paste the results into https://gist.github.com/ and puth the link here.
The content of config/config.php:
https://gist.github.com/virgulesystems/7adfc00d799fe64bb43ce3424a2002ac
List of activated apps: I do not have command-line access
Are you using external storage, if yes which one: no
Are you using encryption: no
Are you using an external user-backend, if yes which one: no
Client configuration
Browser: Chrome (updated)
Operating system: Win7/64
Logs
Web server error log:
I don’t think that I have access to web server log (and I don’t know where to find it…)
This is the file \public_html\error_log:
text/x-generic error_log ( ASCII text, with very long lines )
[15-May-2017 17:51:12 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2 "No such file or directory")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:63
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php(146): Doctrin in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 63
[15-May-2017 17:51:12 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2 "No such file or directory")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:63
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php(146): Doctrin in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 63
[15-May-2017 17:51:13 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2 "No such file or directory")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:63
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php(146): Doctrin in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 63
[15-May-2017 17:51:14 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2 "No such file or directory")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:63
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php(146): Doctrin in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 63
.
.
.
. same error goes on forever
.
.
.
[13-Mar-2018 06:03:26 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (11 "Resource temporarily unavailable")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:64
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 64
.
.
.
. same error goes on forever
.
.
.
[10-Jun-2018 17:26:25 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2 "No such file or directory")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:64
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php(147 in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 64
[10-Jun-2018 17:26:25 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2 "No such file or directory")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:64
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php(147 in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 64
[10-Jun-2018 17:26:26 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2 "No such file or directory")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:64
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php(147 in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 64
[10-Jun-2018 17:26:26 UTC] PHP Fatal error: Uncaught exception 'Doctrine\DBAL\DBALException' with message 'Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2 "No such file or directory")' in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php:64
Stack trace:
#0 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\DB\Connection->connect()
#1 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\DBAL\Connection->getDatabasePlatformVersion()
#2 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\DBAL\Connection->detectDatabasePlatform()
#3 /home/MyUserRoot/public_html/owncloud/lib/composer/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\DBAL\Connection->getDatabasePlatform()
#4 /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php(147 in /home/MyUserRoot/public_html/owncloud/lib/private/DB/Connection.php on line 64
[25-Jun-2018 19:07:34 Asia/Hong_Kong] PHP Fatal error: Cannot destroy active lambda function in [no active file] on line 0
[25-Jun-2018 19:11:01 Asia/Hong_Kong] PHP Fatal error: Cannot destroy active lambda function in [no active file] on line 0
[25-Jun-2018 21:16:24 Asia/Hong_Kong] PHP Fatal error: Cannot destroy active lambda function in [no active file] on line 0
[25-Jun-2018 23:18:34 Asia/Hong_Kong] PHP Fatal error: Cannot destroy active lambda function in [no active file] on line 0
[26-Jun-2018 01:20:57 Asia/Hong_Kong] PHP Fatal error: Cannot destroy active lambda function in [no active file] on line 0
ownCloud log (data/owncloud.log)
The ownCloud log contains thousands of entries with user names and confidential file names that would be really difficult to edit out. Is there a way to extract a log that does not contain sensitive info?
Browser log
probably not relevant, the issue is not related to web browsing