OJS 3 renames your files: if the permissions on the directory and all subdirectories, where they are kept are not correctly set OJS can’t do this and your files become not accessible. I would check permissions first.
Hi,
I have a same problem, non of pdf are showing after upgrade to 3.0 from 2.4.7 (in this version all if fine). I have tried every possible combination of permissions but upgrade process just doesn’t rename files or folders (when I compare them with old files directory, they are same). Can someone help me with this?
As I mention in my second post and as it is said in upgrade manual:
Upgrading the OJS database
After obtaining the latest OJS code, an additional script must be run to
complete the upgrade process by upgrading the OJS database and potentially
executing additional upgrade code.
This script can be executed from the command-line or via the OJS web interface.
Command-line
If you have the CLI version of PHP installed (e.g., /usr/bin/php), you can
upgrade the database as follows:
- Edit config.inc.php and change "installed = On" to "installed = Off"
- Run the following command from the OJS directory (not including the $):
$ php tools/upgrade.php upgrade
- Re-edit config.inc.php and change "installed = Off" back to
"installed = On"
I have upgraded database with mentioned commands from CLI and also from web in second iteration. CLI output was:
I have tried another upgrade, just from CLI, there are couple of errors and no file are renamed:
root@hosting3:/var/www/clients/client0/migracija.ff.uns.ac.rs/web# php tools/upgrade.php upgrade
[pre-install]
[load: upgrade.xml]
[version: 3.0.0.0]
[code: Installer Installer::syncSeriesAssocType]
[data: dbscripts/xml/upgrade/2.4.0_preupdate_usageStatistics.xml (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_preupdate_usageStatistics2.xml]
[data: dbscripts/xml/upgrade/3.0.0_preupdate.xml]
[data: dbscripts/xml/upgrade/3.0.0_adaptTimedViews.xml (skipped)]
[data: dbscripts/xml/upgrade/3.0.0_adaptReferrals.xml]
[data: dbscripts/xml/upgrade/3.0.0_adaptBooksForReview.xml]
[schema: lib/pkp/xml/schema/common.xml]
[schema: lib/pkp/xml/schema/log.xml]
[schema: lib/pkp/xml/schema/announcements.xml]
[schema: lib/pkp/xml/schema/scheduledTasks.xml]
[schema: lib/pkp/xml/schema/temporaryFiles.xml]
[schema: lib/pkp/xml/schema/metadata.xml]
[schema: lib/pkp/xml/schema/reviews.xml]
[schema: lib/pkp/xml/schema/reviewForms.xml]
[schema: lib/pkp/xml/schema/controlledVocab.xml]
[schema: lib/pkp/xml/schema/submissions.xml]
[schema: lib/pkp/xml/schema/submissionFiles.xml]
[schema: lib/pkp/xml/schema/notes.xml]
[schema: lib/pkp/xml/schema/views.xml]
[schema: lib/pkp/xml/schema/genres.xml]
[schema: lib/pkp/xml/schema/gifts.xml]
[schema: lib/pkp/xml/schema/mutex.xml]
[schema: lib/pkp/xml/schema/tombstone.xml]
[schema: lib/pkp/xml/schema/rolesAndUserGroups.xml]
[schema: lib/pkp/xml/schema/metrics.xml]
[schema: lib/pkp/xml/schema/views.xml]
[schema: lib/pkp/xml/schema/libraryFiles.xml]
[schema: dbscripts/xml/ojs_schema.xml]
[data: dbscripts/xml/indexes.xml]
[data: dbscripts/xml/upgrade/3.0.0_change_assoc_type.xml]
[data: dbscripts/xml/upgrade/3.0.0_change_assoc_type_metrics.xml]
[data: dbscripts/xml/upgrade/3.0.0_settings.xml]
[code: Installer Installer::migrateArticleMetadata]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classesdb/DAO.inc.php on line 347
Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[data: dbscripts/xml/upgrade/3.0.0_update.xml]
[code: Installer Installer::clearDataCache]
[code: Installer Installer::migrateUserRoles]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[code: Installer Installer::installDefaultGenres]
[data: dbscripts/xml/upgrade/remove_timed_views_bots.xml (skipped)]
[code: Installer Installer::migrateCounterPluginUsageStatistics (skipped)]
[code: Installer Installer::migrateTimedViewsUsageStatistics (skipped)]
[code: Installer Installer::migrateDefaultUsageStatistics (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_postUsageStatsMigration.xml (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_postUsageStatsMigration2.xml]
[data: dbscripts/xml/upgrade/2.4.0_postCounterMigration.xml (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_postTimedViewsMigration.xml (skipped)]
[code: Installer Installer::fixReviewForms]
[code: Installer Installer::htmlifyEmailTemplates]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[note: docs/release-notes/README-BEACON]
[code: Installer Installer::installEmailTemplate]
[code: Installer Installer::installEmailTemplate]
[code: Installer Installer::installEmailTemplate]
[code: Installer Installer::installEmailTemplate]
[code: Installer Installer::installEmailTemplate]
[data: dbscripts/xml/upgrade/3.0.0_scheduledTasks.xml]
[code: Installer Installer::localizeCustomBlockSettings]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[code: Installer Installer::convertEditorDecisionNotes]
[code: Installer Installer::convertQueries]
[code: Installer Installer::migrateFiles]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[code: Installer Installer::convertSupplementaryFiles]
[data: dbscripts/xml/upgrade/3.0.0_postupdate.xml]
[data: dbscripts/xml/upgrade/3.0.0_pubId_settings.xml]
[code: Installer Installer::addPluginVersions]
[post-install]
Release Notes
This software will optionally provide PKP with a unique identifier for the
installation and the OAI base URL. These are to be used for statistics and
security alert purposes only.
This feature is optional. If you do not wish to participate, you may either
uncheck the "beacon" option in the installation form, or for existing installs,
edit your config.inc.php configuration file and set "enable_beacon" to Off.
Successfully upgraded to version 3.0.0.0
root@hosting3:/var/www/clients/client0/migracija.ff.uns.ac.rs/web#
Owner is web6 client0 not www-data because it isn’t dedicated server and there is IspConfig installed that regulates clients and sites. I will try tomorrow to change owner to www-data but don’t think that it would work. Before upgrade files folder is owned by web6 client0 and it is working.
I’d suggest checking what version of OJS it thinks it’s currently running:
php tools/upgrade.php check
This will display your code version (should be 3.0.0.0) and your database version (should be 2.4.8-1 or whatever you’re upgrading from). Upgrade steps are chosen from dbscripts/xml/upgrade.xml, including things like renaming/moving files, based on the difference between these two versions.
Regards,
Alec Smecher
Public Knowledge Project Team
root@hosting3:/var/www/clients/client0/web6/web# php tools/upgrade.php check
Code version: 3.0.0.0
Database version: 3.0.0.0
Latest version: 2.4.8.1
Current version is newer than latest!
That tells me that your installation has already been upgraded to 3.0.0.0, so if you ask it to upgrade again, it won’t run the 2.4.x to 3.0.0.0 steps, such as moving the files.
Regards,
Alec Smecher
Public Knowledge Project Team
Yes I thought that executing command would give those results, because upgrade was already finished. But in post before (starting with
“I have tried another upgrade, just from CLI, there are couple of errors and no file are renamed:”) I tried clean upgrade from working and stable copy of system that we currently use at epub.ff.uns.ac.rs from 2.4.8.1 to 3.0.0 and it has thrown an errors. I will try to remove all files tomorrow and restore originals and execute given command.
I have just restored backup of files and database of currently used system that we want to upgrade and executed check command, here are results:
root@hosting3:/var/www/clients/client0/web6/web# php tools/upgrade.php check
Code version: 2.4.8.1
Database version: 2.4.8.1
Latest version: 2.4.8.1
Your system is up-to-date
After deleting folders (except files/ public/) and properly configuring config.inc.phpcheck result with:
root@hosting3:/var/www/clients/client0/web6/web# php tools/upgrade.php check
Code version: 3.0.0.0
Database version: 2.4.8.1
Latest version: 2.4.8.1
Database version is older than code version
Run "tools/upgrade.php upgrade" to update
And finally upgrade results with:
root@hosting3:/var/www/clients/client0/web6/web# php tools/upgrade.php upgrade
[pre-install]
[load: upgrade.xml]
[version: 3.0.0.0]
[code: Installer Installer::syncSeriesAssocType]
[data: dbscripts/xml/upgrade/2.4.0_preupdate_usageStatistics.xml (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_preupdate_usageStatistics2.xml]
[data: dbscripts/xml/upgrade/3.0.0_preupdate.xml]
[data: dbscripts/xml/upgrade/3.0.0_adaptTimedViews.xml (skipped)]
[data: dbscripts/xml/upgrade/3.0.0_adaptReferrals.xml]
[data: dbscripts/xml/upgrade/3.0.0_adaptBooksForReview.xml]
[schema: lib/pkp/xml/schema/common.xml]
[schema: lib/pkp/xml/schema/log.xml]
[schema: lib/pkp/xml/schema/announcements.xml]
[schema: lib/pkp/xml/schema/scheduledTasks.xml]
[schema: lib/pkp/xml/schema/temporaryFiles.xml]
[schema: lib/pkp/xml/schema/metadata.xml]
[schema: lib/pkp/xml/schema/reviews.xml]
[schema: lib/pkp/xml/schema/reviewForms.xml]
[schema: lib/pkp/xml/schema/controlledVocab.xml]
[schema: lib/pkp/xml/schema/submissions.xml]
[schema: lib/pkp/xml/schema/submissionFiles.xml]
[schema: lib/pkp/xml/schema/notes.xml]
[schema: lib/pkp/xml/schema/views.xml]
[schema: lib/pkp/xml/schema/genres.xml]
[schema: lib/pkp/xml/schema/gifts.xml]
[schema: lib/pkp/xml/schema/mutex.xml]
[schema: lib/pkp/xml/schema/tombstone.xml]
[schema: lib/pkp/xml/schema/rolesAndUserGroups.xml]
[schema: lib/pkp/xml/schema/metrics.xml]
[schema: lib/pkp/xml/schema/views.xml]
[schema: lib/pkp/xml/schema/libraryFiles.xml]
[schema: dbscripts/xml/ojs_schema.xml]
[data: dbscripts/xml/indexes.xml]
[data: dbscripts/xml/upgrade/3.0.0_change_assoc_type.xml]
[data: dbscripts/xml/upgrade/3.0.0_change_assoc_type_metrics.xml]
[data: dbscripts/xml/upgrade/3.0.0_settings.xml]
[code: Installer Installer::migrateArticleMetadata]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[data: dbscripts/xml/upgrade/3.0.0_update.xml]
[code: Installer Installer::clearDataCache]
[code: Installer Installer::migrateUserRoles]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[code: Installer Installer::installDefaultGenres]
[data: dbscripts/xml/upgrade/remove_timed_views_bots.xml (skipped)]
[code: Installer Installer::migrateCounterPluginUsageStatistics (skipped)]
[code: Installer Installer::migrateTimedViewsUsageStatistics (skipped)]
[code: Installer Installer::migrateDefaultUsageStatistics (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_postUsageStatsMigration.xml (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_postUsageStatsMigration2.xml]
[data: dbscripts/xml/upgrade/2.4.0_postCounterMigration.xml (skipped)]
[data: dbscripts/xml/upgrade/2.4.0_postTimedViewsMigration.xml (skipped)]
[code: Installer Installer::fixReviewForms]
[code: Installer Installer::htmlifyEmailTemplates]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[note: docs/release-notes/README-BEACON]
[code: Installer Installer::installEmailTemplate]
[code: Installer Installer::installEmailTemplate]
[code: Installer Installer::installEmailTemplate]
[code: Installer Installer::installEmailTemplate]
[code: Installer Installer::installEmailTemplate]
[data: dbscripts/xml/upgrade/3.0.0_scheduledTasks.xml]
[code: Installer Installer::localizeCustomBlockSettings]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[code: Installer Installer::convertEditorDecisionNotes]
[code: Installer Installer::convertQueries]
[code: Installer Installer::migrateFiles]
PHP Notice: unserialize(): Error at offset 970 of 1261 bytes in /var/www/clients/client0/web6/web/lib/pkp/classes/db/DAO.inc.php on line 347
[code: Installer Installer::convertSupplementaryFiles]
[data: dbscripts/xml/upgrade/3.0.0_postupdate.xml]
[data: dbscripts/xml/upgrade/3.0.0_pubId_settings.xml]
[code: Installer Installer::addPluginVersions]
[post-install]
Release Notes
----------------------------------------
This software will optionally provide PKP with a unique identifier for the
installation and the OAI base URL. These are to be used for statistics and
security alert purposes only.
This feature is optional. If you do not wish to participate, you may either
uncheck the "beacon" option in the installation form, or for existing installs,
edit your config.inc.php configuration file and set "enable_beacon" to Off.
Successfully upgraded to version 3.0.0.0
PHP is Fast-CGI
PHP version
root@hosting3:/var/www/clients/client0/web6/web# php -v
PHP 5.5.9-1ubuntu4.19 (cli) (built: Jul 28 2016 19:31:33)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies
with XCache v3.1.0, Copyright (c) 2005-2013, by mOo
with Zend OPcache v7.0.3, Copyright (c) 1999-2014, by Zend Technologies
with XCache Optimizer v3.1.0, Copyright (c) 2005-2013, by mOo
with XCache Cacher v3.1.0, Copyright (c) 2005-2013, by mOo
with XCache Coverager v3.1.0, Copyright (c) 2005-2013, by mOo
MySql version
root@hosting3:/var/www/clients/client0/web6/web# mysql --version mysql Ver 14.14 Distrib 5.5.52, for debian-linux-gnu (x86_64) using readline 6.3
For some reason upgrade went relatively ok, I say relatively because most of journals are converted and accessible along with pdf galleys, but for some reason articles of older issues of one journal are missing, there are headings and table of content but there are no articles.