[ NextCloud ] [ 20.0.1.0] OwnCloud Fork

This is the best place for community developers to publish their genius work. Your Apps enrich the QNAP Turbo NAS.
User avatar
QNAP_Stephane
Experience counts
Posts: 3867
Joined: Wed Mar 27, 2013 1:00 am

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by QNAP_Stephane » Fri Dec 06, 2019 6:51 pm

seems it doesn kill the process...

did you try restart your NAS
--------------------------------------------------------------------------
QnapClub AppCenter - https://www.qnapclub.eu
--------------------------------------------------------------------------

raidforsaving
Know my way around
Posts: 242
Joined: Mon Jul 14, 2014 9:14 am

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by raidforsaving » Wed Dec 18, 2019 11:44 pm

FYI, for anyone having memory leak issues, I found the following change fixed it for me. I'm usinq QApache 2.4.39 and Nextcloud 16 (non-qpkg). My Qapache is only for Nextcloud, and I have a small personal instance only used for file storage.

UPDATE: I've settled on using the new values below. If you have ideas on making them better please let me know. The defaults are not acceptable.

Proof of memory leak and fix in place:
https://i.imgur.com/MDpMS2I.png

In my Nextcloud/httpd.conf I edited the following section at the bottom.

I lowered many of the values.

Original config:

Code: Select all

# event MPM
# StartServers: initial number of server processes to start
# MinSpareThreads: minimum number of worker threads which are kept spare
# MaxSpareThreads: maximum number of worker threads which are kept spare
# ThreadsPerChild: constant number of worker threads in each server process
# MaxRequestWorkers: maximum number of worker threads
# MaxConnectionsPerChild: maximum number of connections a server process serves
#                         before terminating
<IfModule mpm_event_module>
    StartServers             3
    MinSpareThreads         75
    MaxSpareThreads        250
    ThreadsPerChild         25
    MaxRequestWorkers      400
    MaxConnectionsPerChild   0
</IfModule>
New config 1 - led to app error - AH00484: server reached MaxRequestWorkers setting, consider raising the MaxRequestWorkers setting

Code: Select all

<IfModule mpm_event_module>
    StartServers             2
    MinSpareThreads         10
    MaxSpareThreads        25
    ThreadsPerChild         15
    MaxRequestWorkers      30
    MaxConnectionsPerChild   50
</IfModule>
New config 2:

Code: Select all

<IfModule mpm_event_module>
    StartServers              2
    MinSpareThreads          30
    MaxSpareThreads         100
    ThreadsPerChild          15
    MaxRequestWorkers       120
    MaxConnectionsPerChild   50
</IfModule>
Last edited by raidforsaving on Sun Feb 23, 2020 2:46 am, edited 1 time in total.
Model name: TS-651
CPU: Intel(R) Celeron(R) CPU J1800 @ 2.41GHz
Firmware version: 4.3.5.0760(20181114)
Volumes: EXT4, Encrypted volume

raidforsaving
Know my way around
Posts: 242
Joined: Mon Jul 14, 2014 9:14 am

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by raidforsaving » Sat Dec 28, 2019 2:04 am

Has anyone performed this db format change successfully on QNAP? It enables 4-byte character support in the DB.

https://docs.nextcloud.com/server/16/ad ... pport.html
Model name: TS-651
CPU: Intel(R) Celeron(R) CPU J1800 @ 2.41GHz
Firmware version: 4.3.5.0760(20181114)
Volumes: EXT4, Encrypted volume

purezerg
Getting the hang of things
Posts: 54
Joined: Wed Nov 18, 2009 7:41 pm

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by purezerg » Tue Dec 31, 2019 10:50 pm

raidforsaving wrote:
Sat Dec 28, 2019 2:04 am
Has anyone performed this db format change successfully on QNAP? It enables 4-byte character support in the DB.

https://docs.nextcloud.com/server/16/ad ... pport.html
i too asked this a while ago.

purezerg
Getting the hang of things
Posts: 54
Joined: Wed Nov 18, 2009 7:41 pm

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by purezerg » Tue Dec 31, 2019 10:58 pm

Slight change of topic from mem hog to cron..
anyone knows how to enable webcron or cron? i checked crontab. the command line is in there but NC will say "last job execution ran xxx minutes ago. Something seems wrong"

raidforsaving
Know my way around
Posts: 242
Joined: Mon Jul 14, 2014 9:14 am

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by raidforsaving » Wed Jan 01, 2020 12:04 am

purezerg wrote:
Tue Dec 31, 2019 10:58 pm
Slight change of topic from mem hog to cron..
anyone knows how to enable webcron or cron? i checked crontab. the command line is in there but NC will say "last job execution ran xxx minutes ago. Something seems wrong"
Read this for directions on QNAP.

https://wiki.qnap.com/wiki/Add_items_to_crontab
Model name: TS-651
CPU: Intel(R) Celeron(R) CPU J1800 @ 2.41GHz
Firmware version: 4.3.5.0760(20181114)
Volumes: EXT4, Encrypted volume

purezerg
Getting the hang of things
Posts: 54
Joined: Wed Nov 18, 2009 7:41 pm

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by purezerg » Wed Jan 01, 2020 1:49 am

correct me if i'm wrong.
5 * * * * /share/CACHEDEV1_DATA/.qpkg/Qapache/bin/php -f /share/CACHEDEV1_DATA/.qpkg/NextCloud/nextcloud/cron.php

is this correct?

raidforsaving
Know my way around
Posts: 242
Joined: Mon Jul 14, 2014 9:14 am

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by raidforsaving » Wed Jan 01, 2020 4:21 am

oo dang. Mine is now commented out. Odd. They may have changed their handling of crontab.

I manually uncommented mine and changed it to every 15 minutes.
Model name: TS-651
CPU: Intel(R) Celeron(R) CPU J1800 @ 2.41GHz
Firmware version: 4.3.5.0760(20181114)
Volumes: EXT4, Encrypted volume

raidforsaving
Know my way around
Posts: 242
Joined: Mon Jul 14, 2014 9:14 am

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by raidforsaving » Wed Jan 01, 2020 4:35 am

purezerg wrote:
Wed Jan 01, 2020 1:49 am
correct me if i'm wrong.
5 * * * * /share/CACHEDEV1_DATA/.qpkg/Qapache/bin/php -f /share/CACHEDEV1_DATA/.qpkg/NextCloud/nextcloud/cron.php

is this correct?
Here is my exact syntax:

Code: Select all

*/15  *  *  *  * /share/CACHEDEV1_DATA/.qpkg/Qapache/bin/php -f /share/CACHEDEV1_DATA/.qpkg/NextCloud/nextcloud/cron.php
Model name: TS-651
CPU: Intel(R) Celeron(R) CPU J1800 @ 2.41GHz
Firmware version: 4.3.5.0760(20181114)
Volumes: EXT4, Encrypted volume

mitch569
New here
Posts: 9
Joined: Thu May 02, 2019 6:36 pm

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by mitch569 » Wed Jan 01, 2020 5:16 am

raidforsaving wrote:
Wed Jan 01, 2020 4:21 am
oo dang. Mine is now commented out. Odd. They may have changed their handling of crontab.

I manually uncommented mine and changed it to every 15 minutes.
Yea I noticed mine hadn’t ran in a while. It was commented out also.
Weird

User avatar
OneCD
Ask me anything
Posts: 8057
Joined: Sun Aug 21, 2016 10:48 am
Location: "... there, behind that sofa!"

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by OneCD » Wed Jan 01, 2020 5:30 am

raidforsaving wrote:
Wed Jan 01, 2020 4:21 am
oo dang. Mine is now commented out. Odd. They may have changed their handling of crontab.
mitch569 wrote:
Wed Jan 01, 2020 5:16 am
Yea I noticed mine hadn’t ran in a while. It was commented out also.
Is QNAP's Malware Remover installed? I think Malware Remover disables entries it doesn’t recognise.

ImageImageImageImageImageImageImageImageImageImageImageImageImageImageImageImageImage

mitch569
New here
Posts: 9
Joined: Thu May 02, 2019 6:36 pm

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by mitch569 » Wed Jan 01, 2020 6:07 am

OneCD wrote:
Wed Jan 01, 2020 5:30 am
raidforsaving wrote:
Wed Jan 01, 2020 4:21 am
oo dang. Mine is now commented out. Odd. They may have changed their handling of crontab.
mitch569 wrote:
Wed Jan 01, 2020 5:16 am
Yea I noticed mine hadn’t ran in a while. It was commented out also.
Is QNAP's Malware Remover installed? I think Malware Remover disables entries it doesn’t recognise.
Yea I installed Malware Remover not long ago.
Is there anyway to add exceptions?

User avatar
OneCD
Ask me anything
Posts: 8057
Joined: Sun Aug 21, 2016 10:48 am
Location: "... there, behind that sofa!"

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by OneCD » Wed Jan 01, 2020 6:08 am

Sorry, I don’t know. :(

ImageImageImageImageImageImageImageImageImageImageImageImageImageImageImageImageImage

purezerg
Getting the hang of things
Posts: 54
Joined: Wed Nov 18, 2009 7:41 pm

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by purezerg » Thu Jan 02, 2020 3:56 pm

something new just cropped up in the log..

-------------------------------
Some columns in the database are missing a conversion to big int. Due to the fact that changing column types on big tables could take some time they were not changed automatically. By running 'occ db:convert-filecache-bigint' those pending changes could be applied manually. This operation needs to be made while the instance is offline. For further details read the documentation page about this.
mounts.storage_id
mounts.root_id
mounts.mount_id
------------------------------
how do you guys solve this?

raidforsaving
Know my way around
Posts: 242
Joined: Mon Jul 14, 2014 9:14 am

Re: [ NextCloud ] [ 17.0.1 ] OwnCloud Fork

Post by raidforsaving » Sat Jan 04, 2020 12:22 am

purezerg wrote:
Thu Jan 02, 2020 3:56 pm
something new just cropped up in the log..

-------------------------------
Some columns in the database are missing a conversion to big int. Due to the fact that changing column types on big tables could take some time they were not changed automatically. By running 'occ db:convert-filecache-bigint' those pending changes could be applied manually. This operation needs to be made while the instance is offline. For further details read the documentation page about this.
mounts.storage_id
mounts.root_id
mounts.mount_id
------------------------------
how do you guys solve this?
# Perform PATH change to add in Qapache dir :
echo $PATH
export PATH=/share/CACHEDEV1_DATA/.qpkg/Qapache/bin:$PATH
cd /share/CACHEDEV1_DATA/.qpkg/NextCloud/nextcloud/
chmod +x occ

# Enable maintenance mode
./occ maintenance:mode --on

# How to run occ commands from the nextcloud dir:
/opt/Qapache/bin/php occ db:add-missing-indice
/opt/Qapache/bin/php occ db:convert-filecache-bigint

# Disable maintenance mode
./occ maintenance:mode --off

# Undo PATH change:
export PATH=<YOUR ORIGINAL PATH VALUE>
Model name: TS-651
CPU: Intel(R) Celeron(R) CPU J1800 @ 2.41GHz
Firmware version: 4.3.5.0760(20181114)
Volumes: EXT4, Encrypted volume

Post Reply

Return to “Community Apps”