Skip to content

Commit 757522c

Browse files
committed
occ: enable apc
Avoid memory exausted error when occ is executed. There are 2 possibile causes: - loglevel is set to 0 - apc is disabled See also nextcloud bug nextcloud/server#25274
1 parent e20ff3f commit 757522c

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

root/etc/e-smith/events/actions/nethserver-nextcloud-conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ function OCC
66
params=$@;
77
source /opt/rh/rh-php73/enable
88
cd /usr/share/nextcloud/
9-
TERM=dumb runuser -s /bin/bash apache -c "php -dmemory_limit=512M ./occ $params"
9+
TERM=dumb runuser -s /bin/bash apache -c "php -d memory_limit=1024M -d apc.enable_cli=1 ./occ $params"
1010
}
1111

1212
exitOnError () {

root/etc/e-smith/events/actions/nethserver-nextcloud-occ-conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ our @system_groups;
1818
sub OCC
1919
{
2020
my $params = join(" ", @_);
21-
system("TERM=dumb su - apache -s /bin/bash -c \"source /opt/rh/rh-php73/enable; cd /usr/share/nextcloud/; php -dmemory_limit=512M occ $params\"");
21+
system("TERM=dumb su - apache -s /bin/bash -c \"source /opt/rh/rh-php73/enable; cd /usr/share/nextcloud/; php -d memory_limit=1024M -d apc.enable_cli=1 occ $params\"");
2222
}
2323

2424
sub _cb_group_push

0 commit comments

Comments
 (0)