Cron blocks my raspberry pi


#1

Hi

I’ve installed owncloud 10 on a raspberry pi 3b.

It is running on apache2, mysql, redis, php7, jessie. It is serving 4 different SMB CIFS shares; 3 x 4tb (1 of them is mostly fulfilled with movies, the rest is general files: docx, pdf, indd, psd, premiere projects) + 1 x 2 TB (general).

When I set cron to run using the system cron it makes may system unresponsive. I’ve set it to run on ajax. And the system looks ok, at least is responsive.

I’ve also saw to make occ file:scan -all through cron.

My client runs on macOS mojave and I’m experimenting virtual files, which are not all synced. I’ve had issues configuring the external shares, so now I’m waiting to complete all the scanning.

Per example my client log tonight:
17/02/2019 23:38:17, FOLDER ,An error occurred while opening a folder Arquivo/ArquivoYYYYY/ZZZ XIX/04 — Design/PROJECT_XXX: Operation canceled

Which cron tasks should be enabled? If cron makes my system unusable I think I should continue to make a task at a time using ajax (as the client also browses the system I suppose tasks continue to be done). Are there any occ commands recommendable to be done? Is there any advantage to do a regular “occ files:scan --all” ? And deletions and expiring versions? Shouldn’t it be done automatically?

Steps to reproduce

Expected behaviour

Tell us what should happen

Actual behaviour

Tell us what happens instead

Server configuration

Operating system:

Web server:

Database:

PHP version:

ownCloud version: (see ownCloud admin page)

Updated from an older ownCloud or fresh install:

Where did you install ownCloud from:

Signing status (ownCloud 9.0 and above):

Login as admin user into your ownCloud and access 
http://example.com/index.php/settings/integrity/failed 
paste the results into https://gist.github.com/ and puth the link here: https://gist.github.com/dawn2duskpt/59783be20706daa69668c4bfac5ba50a

{
“system”: {
“instanceid”: “ocsuae146qmo”,
“updater.secret”: “REMOVED SENSITIVE VALUE”,
“passwordsalt”: “REMOVED SENSITIVE VALUE”,
“secret”: “REMOVED SENSITIVE VALUE”,
“trusted_domains”: [
“agendacultural.eu”
],
“datadirectory”: “/media/owncloud-usb”,
“overwrite.cli.url”: “https://agendacultural.eu/cloud”,
“dbtype”: “mysql”,
“version”: “10.0.10.4”,
“dbname”: “owncloud2”,
“dbhost”: “localhost”,
“dbtableprefix”: “oc_”,
“dbuser”: “REMOVED SENSITIVE VALUE”,
“dbpassword”: “REMOVED SENSITIVE VALUE”,
“logtimezone”: “UTC”,
“installed”: true,
“mail_domain”: “REMOVED SENSITIVE VALUE”,
“mail_from_address”: “REMOVED SENSITIVE VALUE”,
“mail_smtpmode”: “sendmail”,
“mail_smtpauthtype”: “LOGIN”,
“mail_smtphost”: “REMOVED SENSITIVE VALUE”,
“mail_smtpauth”: 1,
“mail_smtpname”: “REMOVED SENSITIVE VALUE”,
“mail_smtppassword”: “REMOVED SENSITIVE VALUE”,
“mail_smtpport”: “587”,
“mail_smtpsecure”: “ssl”,
“memcache.local”: “\OC\Memcache\Redis”,
“filelocking.enabled”: true,
“memcache.distributed”: “\OC\Memcache\Redis”,
“memcache.locking”: “\OC\Memcache\Redis”,
“redis”: {
“host”: “localhost”,
“port”: 6379
},
“files_external_allow_create_new_local”: “true”,
“loglevel”: 3,
“versions_retention_obligation”: “30, 31”
}
}

Log in to the web-UI with an administrator account and click on
'admin' -> 'Generate Config Report' -> 'Download ownCloud config report'
This report includes the config.php settings, the list of activated apps
and other details in a well sanitized form.

or 

If you have access to your command line run e.g.:
sudo -u www-data php occ config:list system
from within your ownCloud installation folder

*ATTENTION:* Do not post your config.php file in public as is. Please use one of the above
methods whenever possible. Both, the generated reports from the web-ui and from occ config:list
consistently remove sensitive data. You still may want to review the report before sending.
If done manually then it is critical for your own privacy to dilligently
remove *all* host names, passwords, usernames, salts and other credentials before posting.
You should assume that attackers find such information and will use them against your systems.

List of activated apps:

If you have access to your command line run e.g.:
sudo -u www-data php occ app:list
from within your ownCloud installation folder.

Enabled:

  • activity: 2.4.2
  • announcementcenter: 1.2.1
  • audioplayer: 2.6.0
  • calendar: 1.6.1
  • camerarawpreviews: 0.6.4
  • comments: 0.3.0
  • configreport: 0.1.1
  • contacts: 1.5.5
  • customgroups: 0.4.0
  • dav: 0.4.0
  • external: 1.2
  • federatedfilesharing: 0.3.1
  • federation: 0.1.0
  • files: 1.5.1
  • files_external: 0.7.1
  • files_pdfviewer: 0.10.0
  • files_sharing: 0.11.0
  • files_texteditor: 2.3.0
  • files_trashbin: 0.9.1
  • files_versions: 1.3.0
  • files_videoplayer: 0.9.8
  • firstrunwizard: 1.1
  • gallery: 16.1.1
  • guests: 0.7.0
  • market: 0.3.0
  • notifications: 0.3.5
  • provisioning_api: 0.5.0
  • richdocuments: 2.1.2
  • systemtags: 0.3.0
  • updatenotification: 0.2.1
  • user_external: 0.4
    Disabled:
  • encryption

Are you using external storage, if yes which one: local/smb/sftp/…
YES: SMB
Are you using encryption: yes/no
NO
Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/…
NO

Client configuration

Browser: safari

Operating system:
macOS mojave

Logs

Web server error log

Insert your webserver log here

ownCloud log (data/owncloud.log)

Insert your ownCloud log here

Browser log

Insert your browser log here, this could for example include:

a) The javascript console log
b) The network log 
c) ...

#2

Hey,

maybe you had too many tasks in your queue due to the usage of Ajax which are now putting high load on your system until those are processed?

Have you tried to research from which component the high load is coming from?

Some additional things i’m seeing which could give additional performance improvements:

Have you considered to update to the recent Server 10.1.0 Release ?

I think the memcache.distributed isn’t required for your setup as long as you don’t have multiple systems accessing the same redis cache.

According to the documentation below APCu is recommended for small / home systems.

https://doc.owncloud.org/server/admin_manual/configuration/server/caching_configuration.html#configuration-recommendations-based-on-type-of-deployment

Maybe using unix sockets like described in the documentation below could avoid the overhead of a TCP connection:

https://doc.owncloud.org/server/admin_manual/configuration/server/caching_configuration.html#redis-configuration


#3

Hi.

Thanks. I’ve read on owncloud doc that for small systems with small amounts of memory using Redis for all cache is recommended.

About memcache.distributed i’ve 4 devices accessing the owncloud server. Shouldn’t I use this option?

About latest version, I wasn’t aware of this. Thanks.

I still can’t make my clients to sync using virtual files, or if they have downloaded those virtual files, then the client doesn’t download the file from the server. most of the files are on external smb shares.

Thanks.


#4

Hey,

i don’t think that this is the correct assumption. From what i know this is not about the devices accessing the server but a distributed setup of more then one ownCloud server connecting to the same redis cache.


#5

Hum… ok, so i Should turn it off, right? It is one server on one raspberry pi. It serves several php webpages and a email server also (davecot).