Updated PHP 7.4, cannot connect to nextcloud

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face:

help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.

In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:

example

Or for longer, use three backticks above and below the code snippet:

longer
example
here

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can :heart:

Nextcloud version: 19.2.?
Operating system and version : 18.04.5 LTS
Apache or nginx version : 2.4.29
PHP version : 7.4.9

The issue you are facing:

Is this the first time you’ve seen this error? : Y

Steps to replicate it:

  1. Log in
  2. Profit

The output of your Nextcloud log in Admin > Logging:

cant access

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

<?php
$CONFIG = array (
  'instanceid' => '****',
  'passwordsalt' => '****',
  'secret' => '****',
  'trusted_domains' =>
  array (
    0 => 'cloud.hixfamily.us',
  ),
  'datadirectory' => '/media/data',
  'dbtype' => 'mysql',
  'version' => '19.0.2.2',
  'overwrite.cli.url' => 'https://cloud.hixfamily.us',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost',
  'htaccess.RewriteBase' => '/',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => '****',
  'dbpassword' => '****',
  'installed' => true,
  'memcache.local' => '\\OC\\Memcache\\Redis',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'filelocking.enabled' => 'true',
  'redis' =>
  array (
    'host' => '/var/run/redis/redis-server.sock',
    'port' => 0,
    'timeout' => 0.0,
  ),
  'ldapIgnoreNamingRules' => false,
  'ldapProviderFactory' => 'OCA\\User_LDAP\\LDAPProviderFactory',
  'mail_from_address' => 'cloud',
  'mail_smtpmode' => 'smtp',
  'mail_sendmailmode' => 'smtp',
  'mail_domain' => 'hixfamily.us',
  'mail_smtphost' => 'mail.hixfamily.us',
  'mail_smtpport' => '25',
  'twofactor_enforced' => 'true',
  'twofactor_enforced_groups' =>
  array (
    0 => 'admin',
  ),
  'twofactor_enforced_excluded_groups' =>
  array (
  ),
  'maintenance' => false,
  'theme' => '',
  'loglevel' => 2,
  'updater.secret' => '****',
  'app_install_overwrite' =>
  array (
    0 => 'keeweb',
  ),
);

The output of your Apache/nginx/system log in /var/log/____:

[php7:error] [pid 1555] [client 50.192.217.33:29137] PHP Fatal error:  Class 'XMLReader' not found in /var/www/html/nextcloud/3rdparty/sabre/xml/lib/Reader.php on line 22

When I updated to NC 19.02 the admin panel informed me that PHP 19.2 was no longer supported. So I followed this help here:


and upgraded.

After running the following commands after a restart:
sudo apt-get upgrade
sudo apt-get distupgrade
sudp apt-get autoremove
and then restart
I could no longer access my next cloud site.

I know it is some config file that is still pointing to 7.2 I just dont know where to look.

any help would be appreciated.
Thanks :slight_smile:

I think apache points to the wrong php version

Just execute
sudo a2dismod php7.3
sudo a2enmod php7.4

1 Like

Life Saver!

1 Like