OJS Upgrade Failed from 3.4.0.5 to 3.5.0.3 – Unknown column 'context' in 'notification_subscription_settings'

I attempted to upgrade my Open Journal Systems (OJS) installation from version 3.4.0.5 to 3.5.0.3 using Softaculous in cPanel.

The upgrade process starts normally, but after initiating the Upgrade Open Journal Systems process, the page loads for some time and then shows a 503 Service Unavailable error.

After refreshing the page, it redirects to the installUpgrade page again, and then the following database error appears:

A database error has occurred: 
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'context' in 'notification_subscription_settings' 
(Connection: mysql, SQL: alter table `notification_subscription_settings` modify `context` bigint null)

Environment details:

  • Previous Version: OJS 3.4.0.5

  • Target Version: OJS 3.5.0.3

  • Installation Method: Softaculous (cPanel)

  • Database: MySQL

  • Server: Linux hosting environment

Issue:

The upgrade process seems to stop midway due to a database schema mismatch, specifically related to the notification_subscription_settings table where the context column cannot be found.

dditional Attempt (Based on PKP Forum Suggestion)
Reference: https://forum.pkp.sfu.ca/t/multiple-errors-while-upgrading-from-3-4-0-5-to-3-5-0-1/97168/2

According to the guidance provided in the PKP forum, failed upgrade attempts may leave the database schema in an inconsistent state. In such cases, it is recommended to restore the installation from the backup taken before the first upgrade attempt and try again.

Following this suggestion, I attempted the upgrade again with the following steps:

Attempt 2:

  1. Restored the full backup of both the OJS files and database (before the upgrade attempt).

  2. Initiated Upgrade Open Journal Systems again.

However, during the upgrade process the same issue occurs:

@asmecher please look it into this

Hi @salman20054,

Do you have a back up of your OJS installation taken before you first tried the upgrade from 3.4.0-5 to 3.5.0-3?

Regards,
Alec Smecher
Public Knowledge Project Team

Yes, i had back up of my OJS installation taken before i first tried the upgrade from 3.4.0-5 to 3.5.0-3

Hi @salman20054,

I’d recommend restoring your installation from backup, then following the upgrade steps e.g. in this video:

If you run the upgrade, and encounter a problem, you’ll need to restore from backup, resolve the problem you encountered, then try again.

I recommend using the command-line upgrade tool, rather than the web-based one, because the upgrade can take longer than your server timeouts. This is probably what happened when the Softaculous upgrade failed.

Regards,
Alec Smecher
Public Knowledge Project Team

This topic was automatically closed after 13 days. New replies are no longer allowed.