Nextcloud version (eg, 12.0.2): 14.0.1
Operating system and version (eg, Ubuntu 17.04): Alpine Linux 3.8
Apache or nginx version (eg, Apache 2.4.25): Nginx 1.14.0
PHP version (eg, 7.1): 7.2.10
The issue you are facing:
I want to run occ command to set Nextcloud in maintenance mode:
su nginx -c "php occ maintenance:mode --on"
However validating the config-file config.php shows that the command was not successfull:
ct114-devcloud:/# tail /var/www/nextcloud/config/config.php
'mail_smtpauthtype' => 'LOGIN',
'mail_smtpauth' => 1,
'mail_smtphost' => 'smtp.gmail.com',
'mail_smtpport' => '587',
'maintenance' => false,
);
I checked if occ commands are generally working w/o success:
ct114-devcloud:/# su nginx -c 'php /var/www/nextcloud/occ status'
ct114-devcloud:/# su nginx -c 'php /var/www/nextcloud/occ -h'
ct114-devcloud:/#
Is this the first time you’ve seen this error? (Y/N): Y
The output of your Nextcloud log in Admin > Logging:
<no relevant entries>
The output of your config.php file in /path/to/nextcloud
(make sure you remove any identifiable information!):
<?php
$CONFIG = array (
'datadirectory' => '/var/lib/nextcloud/data',
'logfile' => '/var/log/nextcloud/nextcloud.log',
'apps_paths' =>
array (
0 =>
array (
'path' => '/usr/share/webapps/nextcloud/apps',
'url' => '/apps',
'writable' => false,
),
1 =>
array (
'path' => '/var/lib/nextcloud/apps',
'url' => '/apps-appstore',
'writable' => true,
),
),
'updatechecker' => false,
'check_for_working_htaccess' => false,
'installed' => true,
'instanceid' => 'ocsd5hfatsje',
'trusted_domains' =>
array (
0 => 'devcloud.domain.lan',
),
'dbtype' => 'mysql',
'version' => '14.0.1.1',
'overwrite.cli.url' => 'https://devcloud.domain.lan',
'dbname' => 'nextcloud',
'dbhost' => 'localhost',
'dbport' => '',
'dbtableprefix' => 'oc_',
'mysql.utf8mb4' => true,
'enable_previews' => false,
'mail_from_address' => 'admin',
'mail_smtpmode' => 'smtp',
'mail_smtpauthtype' => 'LOGIN',
'mail_domain' => 'devcloud.domain.lan',
'mail_smtpauth' => 1,
'mail_smtphost' => 'smtp.gmail.com',
'mail_smtpport' => '587',
'mail_smtpsecure' => 'tls',
'maintenance' => false,
);
How can I debug the occ commands to identify the root cause?
THX