Occ upgrade segfaulting

Hi all,

I tried to upgrade my Nextcloud installation to v17.0.2, and now it is segfaulting when running the update script in maintenance mode.

I tried reverting to v17.0.0 but that made no difference.

The other php services running on my VPS are working fine (Joomla, myphpadmin, etc), so it doesn’t appear to be a problem with php, unless there is an issue with a specific module that the others don’t use.

I’ve tried disabling all apps using occ, but no luck here either. I have enabled logging level 0 but the only thing I see is a warning about memcache:

{"reqId":"###","level":1,"time":"2019 December 23-19:41:34","remoteAddr":"","user":"--","app":"cli","method":"","url":"\/nextcloud\/occ","message":"Memcache \\OC\\Memcache\\APCu not available for distributed cache","userAgent":"--","version":"17.0.0"}

Really hoping someone here has some suggestions for me.

/usr/local/www/nextcloud# su -m www -c "php ./occ upgrade"
Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
Set log level to debug
Updating database schema
Updated database
Checking for update of app accessibility in appstore
Checked for update of app "accessibility" in appstore 
Checking for update of app activity in appstore
Checked for update of app "activity" in appstore 
Checking for update of app admin_audit in appstore
Checked for update of app "admin_audit" in appstore 
Checking for update of app bruteforcesettings in appstore
Checked for update of app "bruteforcesettings" in appstore 
Checking for update of app cloud_federation_api in appstore
Checked for update of app "cloud_federation_api" in appstore 
Checking for update of app comments in appstore
Checked for update of app "comments" in appstore 
Checking for update of app dav in appstore
Checked for update of app "dav" in appstore 
Checking for update of app federatedfilesharing in appstore
Checked for update of app "federatedfilesharing" in appstore 
Checking for update of app federation in appstore
Checked for update of app "federation" in appstore 
Checking for update of app files in appstore
Checked for update of app "files" in appstore 
Checking for update of app files_pdfviewer in appstore
Checked for update of app "files_pdfviewer" in appstore 
Checking for update of app files_rightclick in appstore
Checked for update of app "files_rightclick" in appstore 
Checking for update of app files_sharing in appstore
Checked for update of app "files_sharing" in appstore 
Checking for update of app files_trashbin in appstore
Checked for update of app "files_trashbin" in appstore 
Checking for update of app files_versions in appstore
Checked for update of app "files_versions" in appstore 
Checking for update of app files_videoplayer in appstore
Checked for update of app "files_videoplayer" in appstore 
Checking for update of app firstrunwizard in appstore
Checked for update of app "firstrunwizard" in appstore 
Checking for update of app logreader in appstore
Checked for update of app "logreader" in appstore 
Checking for update of app lookup_server_connector in appstore
Checked for update of app "lookup_server_connector" in appstore 
Checking for update of app nextcloud_announcements in appstore
Checked for update of app "nextcloud_announcements" in appstore 
Checking for update of app notifications in appstore
Checked for update of app "notifications" in appstore 
Checking for update of app oauth2 in appstore
Checked for update of app "oauth2" in appstore 
Checking for update of app password_policy in appstore
Checked for update of app "password_policy" in appstore 
Checking for update of app privacy in appstore
Checked for update of app "privacy" in appstore 
Checking for update of app provisioning_api in appstore
Checked for update of app "provisioning_api" in appstore 
Checking for update of app recommendations in appstore
Checked for update of app "recommendations" in appstore 
Checking for update of app serverinfo in appstore
Checked for update of app "serverinfo" in appstore 
Checking for update of app sharebymail in appstore
Checked for update of app "sharebymail" in appstore 
Checking for update of app support in appstore
Checked for update of app "support" in appstore 
Checking for update of app survey_client in appstore
Checked for update of app "survey_client" in appstore 
Checking for update of app systemtags in appstore
Checked for update of app "systemtags" in appstore 
Checking for update of app text in appstore
Checked for update of app "text" in appstore 
Checking for update of app twofactor_backupcodes in appstore
Checked for update of app "twofactor_backupcodes" in appstore 
Checking for update of app updatenotification in appstore
Checked for update of app "updatenotification" in appstore 
Checking for update of app viewer in appstore
Checked for update of app "viewer" in appstore 
Checking for update of app workflowengine in appstore
Checked for update of app "workflowengine" in appstore 
Segmentation fault (core dumped)

httpd-error.log:
[Mon Dec 23 18:22:25.545723 2019] [core:notice] [pid 75504] AH00052: child pid 4701 exit signal Segmentation fault (11)

Nextcloud v17.0.0
OS FreeBSD 12.1-RELEASE-p1
Apache v2.4.41
PHP v7.2.25

# cat config/config.php
<?php
$CONFIG = array (
  'instanceid' => '516ae6f15e855',
  'passwordsalt' => '####',
  'datadirectory' => '/mnt/data',
  'dbtype' => 'mysql',
  'version' => '17.0.0',
  'dbname' => 'nextcloud',
  'dbhost' => '127.0.0.1',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'nextcloud',
  'dbpassword' => '###',
  'installed' => true,
  'maintenance' => true,
  'theme' => '',
  'forcessl' => true,
  'default_locale' => 'en-dk',
  'force_language' => 'en_DK',
  'force_locale' => 'en_DK',
  'trusted_domains' => 
  array (
    0 => '####.###',
  ),
  'mail_from_address' => 'root',
  'mail_smtpmode' => 'smtp',
  'mail_smtphost' => '127.0.0.1',
  'mail_smtpport' => 25,
  'mail_domain' => '#####.###',
  'secret' => '###',
  'log_type' => 'file',
  'logfile' => '/var/log/nextcloud.log',
  'logtimezone' => 'Europe/###',
  'logfilemode' => 416,
  'loglevel' => 0,
  'logdateformat' => 'Y F d-H:i:s',
  'trashbin_retention_obligation' => '180, auto',
  'overwrite.cli.url' => '/nextcloud',
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'overwritewebroot' => '/nextcloud',
  'apps_paths' => 
  array (
    0 => 
    array (
      'path' => '/usr/local/www/nextcloud/apps',
      'url' => '/apps',
      'writable' => true,
    ),
    1 => 
    array (
      'path' => '/usr/local/www/nextcloud/apps-pkg',
      'url' => '/apps-pkg',
      'writable' => false,
    ),
  ),
  'app_install_overwrite' => 
  array (
    0 => 'calendar',
    1 => 'tasks',
  ),
);

Hi again everyone,

I still have not solved this and am hoping someone here will have some ideas for me. I have tried simply disabling “update” but it still segfaulting. I don’t feel I can report this to github until I can determine why it is crashing.

# su -m www -c "php ./occ maintenance:mode --off"
Nextcloud or one of the apps require upgrade - only a limited number of commands are available
You may use your browser or the occ upgrade command to do the upgrade
Maintenance mode disabled
Segmentation fault (core dumped)