Stuck - need to upgrade 9.1.2 - PHP5.5.1.6 no longer available at webhost

Owncloud was running on PHP 5.5.1.6 (I think). Web developer upgraded php to 8.1. Web host could only load PHP back to 7.1. We tried 7.2, 7.3 and maybe more. Is there a way to manually upgrade to a version that will run on 7.x, then eventually move forward into the 20th century?
Hoping it is as easy or easier than exporting the SQL and importing to newer release…
Thank you. - Rick Cassel

[~/public_html/owncloud]# ./occ upgrade
This version of ownCloud is not compatible with PHP 7.1.
You are currently running 9.1.2. Please use at least ownCloud 9.2.0

Obviously I can’t use ./occ. Possible I can download and run 9.2 from scripts? Shared server - ain’t got no Yummy or Apz-Getz.

Steps to reproduce

  1. Hire a web designer
  2. Upgrade php to 8x. install latest WordPress whilst wrecking OwnCloud.
    3.Search for an hour for how-to
    4.Hang a request at OwnCloud
  3. Maybe find a FreeLancer who really knows what they are doing and not scammers. lol.

Expected behaviour

Push a button and have it upgrade with ./occ

Actual behaviour

Rip my hair out and hack away all weekend building CentOS 7 with PHP5.x virtual machine and drop and drag and hope and pray can have it running by Monday morning.

Server configuration

CentOS 9:

Apache

MariaDB

PHP 7.4:

ownCloud version: (see ownCloud admin page)
9.1.2

Updated from an older ownCloud or fresh install:
Older Version
Where did you install ownCloud from:
Script bundle download from OwnCloud
Signing status (ownCloud 9.0 and above):

Login as admin user into your ownCloud and access 
http://example.com/index.php/settings/integrity/failed 
paste the results into https://gist.github.com/ and puth the link here.
*** Can't  *** PHP no good

The content of config/config.php:

<?php $CONFIG = array ( 'instanceid' => 'oc8bsw4doh0o', 'passwordsalt' => 'BR549/1+xZnWARRTgpxTijc9+FA', 'secret' => 's5qNskXhS2GtQtnNTYOizVVNOf5Vm4GhnzaE7BLHeHawBR549', 'trusted_domains' => array ( 'kukubird.com','www.kukubird.com', ), 'datadirectory' => '/home4/kukub/public_html/owncloud/data', 'overwrite.cli.url' => 'https://kukubird.com/owncloud', 'dbtype' => 'sqlite3', 'version' => '9.1.2.5', 'logtimezone' => 'UTC', 'installed' => true, 'loglevel' => 0, 'forcessl' => true, 'xframe_restriction' => true, ); ``` Log in to the web-UI with an administrator account and click on 'admin' -> 'Generate Config Report' -> 'Download ownCloud config report' This report includes the config.php settings, the list of activated apps and other details in a well sanitized form. or If you have access to your command line run e.g.: sudo -u www-data php occ config:list system from within your ownCloud installation folder *ATTENTION:* Do not post your config.php file in public as is. Please use one of the above methods whenever possible. Both, the generated reports from the web-ui and from occ config:list consistently remove sensitive data. You still may want to review the report before sending. If done manually then it is critical for your own privacy to dilligently remove *all* host names, passwords, usernames, salts and other credentials before posting. You should assume that attackers find such information and will use them against your systems. ``` **List of activated apps:** ``` If you have access to your command line run e.g.: sudo -u www-data php occ app:list from within your ownCloud installation folder. ``` **Are you using external storage, if yes which one:** local/smb/sftp/... **Are you using encryption:** yes/no No **Are you using an external user-backend, if yes which one:** LDAP/ActiveDirectory/Webdav/... No #### LDAP configuration (delete this part if not used) ``` With access to your command line run e.g.: sudo -u www-data php occ ldap:show-config from within your ownCloud installation folder * can't occ nothing, php broke Without access to your command line download the data/owncloud.db to your local computer or access your SQL server remotely and run the select query: SELECT * FROM `oc_appconfig` WHERE `appid` = 'user_ldap'; Eventually replace sensitive data as the name/IP-address of your LDAP server or groups. ``` ### Client configuration **Browser:** **Operating system:** ### Logs #### Web server error log ``` Insert your webserver log here ``` #### ownCloud log (data/owncloud.log) NULL - empty Insert your ownCloud log here ``` #### Browser log ``` Insert your browser log here, this could for example include: a) The javascript console log b) The network log c) ... ```

I have no good news for you. There no longer are any safe or supported versions of CentOS and ownCloud 9 has been past its end of life for just about as long as PHP 5.6 has been retired. Keeping your software updated with greater frequency can help avoid these types of self-made disasters.

You are going to most likely need to start over from scratch on a freshly installed server. I recommend Debian stable due to ownCloud’s dependency on an obsolete PHP version. It is still packaged by a Debian maintainer over at DEB.SURY.ORG.

If you are comfortable using containers you could always use the official Docker image.

Embrace the pain and use it as reminder to cultivate better maintenance habits once you have a new ownCloud running.

2 Likes

I have a working version of CentOS with PHP 7.4.33
I only need old versions and old php long enough to progressive upgrade.
Is it possible to upgrade manually without OCC ? Run installer overwriting existing files?
OR
Is it possible to get the users and other associated data by restoring MariaDB backups to fresh install of 10.10.15?

This version of ownCloud is not compatible with PHP 7.1.
You are currently running 7.4.33. Please use at least ownCloud 9.2.0.