Hello,
this post may be connected to this and this.
For a couple of days I was trying to do a full migration of one-journal OJS from 2.4.8.1 to 3.1.1.4 (latest).
The best I was able to do was to upgrade to 3.0.2 and then upgrade to 3.1.1.4. However, I’m still unable to migrate files to new architecture as the script is throwing errors (unable to find source file).
Problems I’ve encountered:
-
I can’t upgrade via installer web interface - there is simply no link to run the upgrade script - I had to run upgrade via the console. I’m not sure it is related but it is strange nevertheless. I’ve never had this problem and I’m upgrading by removing all files in www directory (apart from config and public) and placing fresh version. I’ve tried using the same config file (1:1) and manually updating database and other information based on template from the newest version, no difference.
-
Direct upgrade from 2.4.8.1 to 3.1.1.4 is impossible regardless of using PHP 5.6.x or 7.0.x. The error I get that kills the script:
PHP Fatal error: Uncaught Error: Call to a member function getFileId() on null in /home/klient.dhosting.pl//../www/lib/pkp/classes/submission/PKPSubmissionFileDAO.inc.php:1065
Stack trace:
#0 /home/klient.dhosting.pl//../www/lib/pkp/classes/submission/PKPSubmissionFileDAO.inc.php(315): PKPSubmissionFileDAO->_castToDatabase(NULL)
#1 /home/klient.dhosting.pl//../www/lib/pkp/classes/file/SubmissionFileManager.inc.php(185): PKPSubmissionFileDAO->insertObject(Object(SupplementaryFile), ‘/home/klient.dh…’)
#2 /home/klient.dhosting.pl//../www/classes/install/Upgrade.inc.php(1491): SubmissionFileManager->copyFileToFileStage(‘7518’, 1, 4, NULL, true)
#3 /home/klient.dhosting.pl//../www/lib/pkp/classes/install/Installer.inc.php(421): Upgrade->provideSupplementaryFilesForReview(Object(Upgrade), Array)
#4 /home/klient.dhosting.pl//.. in /home/klient.dhosting.pl//../www/lib/pkp/classes/submission/PKPSubmissionFileDAO.inc.php on line 1065 -
Even when I upgrade using 3.0.2 mid-stage, my database gets upgraded but files don’t move.
I have plenty of “Unable to copy file - file does not exist” errors.
One problem that I see is double slash in path:
/files/journals/1//articles/3616/
However, this shouldn’t be a problem with UNIX systems.
What bothers me more is updater script throwing gazillion of warnings, such as:
WARNING: Unable to find a match for "3546-7320-1-CE.pdf" in "/home/klient.dhosting.pl/***/***.***.***/www/files/journals/1//articles/3546/". Skipping this file.
Basically one line per file - be it PDF or DOCX. Since such warnings are being thrown out even when upgrading to 3.0.2, I did some investigation and found out that in 2.4.8.1, files exist in:
/files/journals/1/issues/
While script tries to access:
/files/journals/1//articles/
There isn’t even a folder called “articles” in 2.4.8 which could explain the error.
Am I right or am I missing something important?
I’ll be happy for any insight on what may be the culprit. It seems that, apart from fatal error, file migration is the only problem leaving me unable to do the migration.