Error message while updating from 5.0.9 to 6.0.9

Steps to reproduce

  1. Try to upgrade from 5.0.9 to 6.0.9

Expected behaviour

Successful upgrade

Actual behaviour

Error message:
“An exception occurred while executing ‘SELECT id FROM oc_jobs WHERE class = ? AND argument = ?’: SQLSTATE[42S02]: Base table or view not found: 1146 Table ‘db1024487-wikidb.oc_jobs’ doesn’t exist”

Server configuration

Operating system:
N/A
Web server:
N/A
Database:
MySQL

PHP version:
3.7

ownCloud version: (see ownCloud admin page)
5.0.9 and 6.0.9

Updated from an older ownCloud or fresh install:
Update

Where did you install ownCloud from:

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.

error msg as above

The content of config/config.php:
N/A

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/…
no
Are you using encryption: yes/no
no
Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/…
no

Client configuration

Browser:
any
Operating system:
any

Logs

Web server error log

Insert your webserver log here

ownCloud log (data/owncloud.log)

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) ...

N/A

Additional comment:
I am trying to update an old and badly maintained Owncloud instance from 5.0.9 to the current stable version (10.0.9). Because of the limitations of the update process, I have to go through all intermediate major versions. However, the oldest available version is 6.0.9. Apparently, somewhere in between 5.0.9 and 6.0.9 the table “oc_jobs” got created and is now not available in my installation for the required update.
Thanks a lot for any help.

Kind regards,

Martin

Hi Martin,

sadly you didn’t provide all the required information to give you a better answer. it would be great to know which apps have you enabled and your log fies, anyway I will provide some hints:

you can’t migrate from 5.0.9 to 6.0.9 directly you have to make a step between (5.0.19), the whole migration that you have to do is:

5.0.9 -> 5.0.19 -> 6.0.9 -> 7.0.15 -> 8.0.16 -> 8.1.12 -> 8.2.11 -> 10.0.9 or next week to 10.0.10

You can skip the migrations to 9.0.11 and 9.1.8 when you come from 8.2.11

Please read the reference: https://doc.owncloud.org/server/10.0/admin_manual/maintenance/upgrade.html
and all the release notes too: https://doc.owncloud.org/server/10.0/admin_manual/release_notes.html

The error that you are experimenting is a temporary database to migrate, to avoid it, first make a backup of your database! and then run this command:

./occ upgrade --skip-migration-test -vvv

I’m not sure if the OLD versions have that --skip-migration-test but you can try it.

Additional: (if you don’t want to spend many hours upgrading all the versions)
If you don’t have to many shares and you want to avoid all the migrations steps, I would recommend to install a fresh installation from 10.0.9, copy the files to the same folders of the users and run an occ files:scan --all who will update the oc_filecache.
In this case all the shares will be lost but you could ask to the users to create them again, you can see the existing shares in the oc_share table

I hope that helps.

Carlos

1 Like

And remember to upgrade your PHP version after 8.2 you need at least 5.6 or 7.0

1 Like

Hi Carlos,

Thanks a lot for the quick reply. I didn’t provide all the details, because most of them seemed to be irrelevant to the problem (I work as a developer, so I think I can make competent judgement on what’s required for debugging such an issue).

Thanks a lot for providing the upgrade path. Where would I find the 5.0.19 version? The archive downloads only go back to version 6.

I won’t be able to use the command line tool “occ”, because I don’t have shell access to where this Owncloud instance is hosted.

Kind regards,

Martin

Hey,

generally i’m not sure how much people are still around here knowing such versions like 5 or 6 (i had started with 9.1 for example) which could help with any issues arising during this long upgrade way to 10.0.

Personally i would take the route to drop this old versions and do a fresh installation of 10.0.9/10.0.10 like @cdamken suggested.

all links in https://owncloud.org/download/older-versions/ looks like the following:

https://download.owncloud.org/community/6/owncloud-6.0.9.tar.bz2

If i’m replacing the “6” with “5” i’m getting a directory listing presented:

https://attic.owncloud.com/org/community/5/

which seems to have 5.0.19 here:

https://attic.owncloud.com/org/community/5/owncloud-5.0.19.tar.bz2

1 Like

Great, thanks a lot for hint. I could have thought of this myself. :slight_smile:
I have managed to download the 5.0.19 files and will try to update with this one.