OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



Problems with updating OJS from version 2.2.3 to 2.4.2

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Tue Jun 04, 2013 12:36 pm

We have a very outdated version of OJS (2.2.3) on a machine with etch10 PHP 5.2.0-8 and Apache 2.2.3. We want to update the version and at the same time, migrate to a new device, squeeze14 with PHP 5.3.3-7 and Apache 2.2.16.

The new equipment has the necessary prerequisites for the system, according to the installation manual.

After several attempts and various consultations forum, we come to the following results:

1) Update to patch.
Not run on the new server. On the old server, after running, error occurred as below.

2) Update the full version or simple clean install on the new server.
Loads the first screen, but after providing the data and click "Install system" carries a blank screen and does not perform. In the error log shows nothing, the only error that was identified was the "Network error 500".

3) single copy of the current version to the new server.
Runs normally, however, is not the block side.

My questions:
- Why does not perform update for patch (patch-p1 <file)? Accuses "-bash: patch: command not found".
- Why in the complete installation does not pass the second screen on the new server?
- The reason may be related to the ratio of copies of the original structure be?

Please if anyone can give help at least to indicate which way to turn, will be very welcome ...

In advance, thank you ...
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Fri Jun 07, 2013 6:38 am

I upgraded in full installation (copying config.inc.php from previous version) and occurs 2 situations:

1) In first execution appears "column review_round_id contain null values".
2) Clicking in upgrade button again, the system say "relation copyed_assignments does not exist". Do not continues...

What´s happen?
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby asmecher » Fri Jun 07, 2013 10:15 am

Hi madriano,

Are you using PostgreSQL? If so, try applying the patch for bug #8247 (specifically, this patch, applied in the lib/pkp subdirectory). Apply it before running the upgrade script.

As for your second error, it's happening because the upgrade died partway through and left your database in an intermediate state. Restore your DB from backup before trying the upgrade again.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9233
Joined: Wed Aug 10, 2005 12:56 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Mon Jun 10, 2013 5:04 am

Hi Alec, thank you for your response.

In mean time, I do the upgrade from patch ojs-2.2.3_to_2.4.2.patch, in command line - appears the message error:
Code: Select all
DB Error: ERROR: column v.product_class_name does not exist LINHA 3: lower(v.product_class_name) = ps.plugin_name ^


And in the apache log error:
Code: Select all
[Mon Jun 10 08:56:26 2013] [error] [client 10.10.0.124] NOTICE: Undefined index: redirect (/var/www/revistas/lib/pkp/classes/site/SiteDAO.inc.php:63)
[Mon Jun 10 08:56:26 2013] [error] [client 10.10.0.124] ojs2: DB Error: ERROR:  column v.product_class_name does not exist\nLINHA 3:      lower(v.product_class_name) = ps.plugin_name\n                    ^
[Mon Jun 10 08:56:26 2013] [error] [client 10.10.0.124] PHP Fatal error:  Class 'HookRegistry' not found in /var/www/revistas/lib/pkp/classes/db/DAO.inc.php on line 218


This too have relation with bug #8247? Is better execute from command line with patch or by interface in browser?

[]´s
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby asmecher » Mon Jun 10, 2013 8:48 am

Hi madriano,

Have you run the upgrade script, or just applied the patch?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9233
Joined: Wed Aug 10, 2005 12:56 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Mon Jun 10, 2013 10:54 am

Both... how I am testing, I have 2 installations (distinct dns e database)... in first installation, I upgraded by interface (browser) and in the second instance, in command line, was executed:
Code: Select all
patch -p1 < ojs-2.2.3_to_2.4.2.patch
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby asmecher » Mon Jun 10, 2013 11:18 am

Hi madriano,

Do you have the console output from the patch and upgrade commands?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9233
Joined: Wed Aug 10, 2005 12:56 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Mon Jun 10, 2013 11:33 am

I do not know ... is there any predefined log in update? Can I run again, how could save the log?
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Mon Jun 10, 2013 2:52 pm

With patch downloaded from bug 8247, I do the command (in 2.2.3 version site):
Code: Select all
patch -p1 --dry-run < 0001-Relax-not-null-constraint-on-review_round_id-in-revi.patch


This is the result:
Code: Select all
patching file lib/pkp/xml/schema/reviews.xml
Hunk #1 FAILED at 58.
1 out of 1 hunk FAILED -- saving rejects to file lib/pkp/xml/schema/reviews.xml.rej


Should I proceed with installing the patch? Or the patch should be executed in 2.4.2 version site before upgrade?
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby asmecher » Mon Jun 10, 2013 3:05 pm

Hi madriano,

That patch should be applied to the OJS 2.4.2 code before you run the upgrade script.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9233
Joined: Wed Aug 10, 2005 12:56 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Tue Jun 11, 2013 4:58 am

Hi Alec. Please, confirm to me the steps:

1) Download version 2.4.2 and extract files.
2) Rename directory to name of directory to actual site.
3) Copy the files directory and config.inc.php of actual version (2.2.3).
4) Execute patch of bug 8247.
5) Execute patch ojs-2.2.3_to_2.4.2.patch OR
5) Execute upgrade from installation interface (changing "installed" parameter in config.inc.php to "off").
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Tue Jun 11, 2013 7:48 am

1) Copy actual base (2.2.3)

2) Copy files from version 2.4.2 to copy actual site, except config.inc.php, public and files directory.

3) Executed patch of bug 8247, with follow result:
Code: Select all
patching file lib/pkp/xml/schema/reviews.xml


4) Changed config.inc.php file in parameter installed to "off".

5) Call the url in browser, and click in "Upgrade" link.

6) In new screen, click in button upgrade. Occurs the follow error:
Code: Select all
Ocorreu um erro de base de dados: ERROR: invalid input syntax for type numeric: " "

And in second click in the button:
Code: Select all
Ocorreu um erro de base de dados: ERROR: relation "copyed_assignments" does not exist


In step 6, I imagine it might be a bug associated with the translation, no?

Attachement the log error of apache.
Attachments
log_instalacao.txt
(6.2 KiB) Downloaded 344 times
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby asmecher » Tue Jun 11, 2013 10:09 am

Hi madriano,

There is quite a mix of stuff happening here:
  • The "Class 'HookRegistry' not found" error is an APC problem; see http://pkp.sfu.ca/support/forum/viewtopic.php?f=8&t=4999&start=15#p20486 and this work-around.
  • The first upgrade attempt (with the "invalid input syntax") is a PostgreSQL-related error. We test with MySQL most heavily, so the occasional PostgreSQL problem sneaks in. You've already patched #8247, so it looks like there's another similar bug or perhaps a data inconsistency that needs fixing. If you turn on the "debug" setting in config.inc.php before you run the upgrade, we'll hopefully be able to identify where in the upgrade we hit this problem.
  • The final message about the table not existing is because you're trying to upgrade a database that has already been partially upgraded. You'll need to restore your DB from backup before you try the upgrade again, or you'll see this kind of message.
Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9233
Joined: Wed Aug 10, 2005 12:56 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby asmecher » Tue Jun 11, 2013 11:44 am

Hi madriano,

One additional note: I wonder if you're not running into http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8252.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9233
Joined: Wed Aug 10, 2005 12:56 pm

Re: Problems with updating OJS from version 2.2.3 to 2.4.2

Postby madriano » Tue Jun 11, 2013 12:52 pm

Hi Alec.

The problem with HookRegistry must be added session_write_close as a shutdown function in file /lib/pkp/classes/session/SessionManager.inc.php in line 96, correct (action executed)? Or is it more advisable to disable the APC?

I did the upgrade installation with debug and show_stacktrace parameters as "on". Attached are the files log of ojs and apache web server. The last lines of debug are:
Code: Select all
(postgres7): INSERT INTO article_files (file_id, revision, source_file_id, source_revision, article_id, file_name, file_type, file_size, original_file_name, file_stage, viewable, date_uploaded, date_modified, round, assoc_id) SELECT file_id, revision, source_file_id, source_revision, article_id, file_name, file_type, file_size, original_file_name, to_number(file_stage,'S9999999999999D99'), viewable, date_uploaded, date_modified, round, assoc_id FROM article_files_tmp 
-1: ERROR: invalid input syntax for type numeric: " "
                                    ADOConnection._Execute(INSERT INTO article_files (file_id, revision, source_file_id, source_revision, article_id, file_name, file_type, file_size, orig..., false) % line  864, file: adodb.inc.php
                                 ADOConnection.Execute(INSERT INTO article_files (file_id, revision, source_file_id, source_revision, article_id, file_name, file_type, file_size, orig...) % line  443, file: Installer.inc.php
                              Installer.executeSQL(INSERT INTO article_files (file_id, revision, source_file_id, source_revision, article_id, file_name, file_type, file_size, orig...) % line  438, file: Installer.inc.php
                           Installer.executeSQL(Array[346]) % line  378, file: Installer.inc.php
                        Installer.executeAction(Array[3]) % line  268, file: Installer.inc.php
Attachments
log_upgrade_erro.txt
Debug File
(527.95 KiB) Downloaded 48 times
log_upgrade_apache.txt
Apache File
(11.81 KiB) Downloaded 46 times
madriano
 
Posts: 52
Joined: Wed Nov 25, 2009 12:23 pm

Next

Return to OJS Technical Support

Who is online

Users browsing this forum: Exabot [Bot], Google [Bot], Yahoo [Bot] and 8 guests