Dear @asmecher,
I am sending the tests you requested. I appreciate the attention.
Augusto Torres
DATABASE SERVER
$ psql ojsdatabase (database in production)
psql (9.5.21)
Type “help” for help.
DATABASE IN PRODUCTION
ojsdatabase=# SELECT * from authors;
author_id | submission_id | primary_contact | seq | country | email | url | user_group_id | include_in_browse
-----------±--------------±----------------±----±--------±-------------------------------------
1181 | 1005 | 0 | 1 | BR | test@domain.com |
(1470 rows)
ojsdatabase=# SELECT COUNT(*) FROM authors;
count
1470
(1 row)
ojsdatabase=# SELECT * from author_settings;
author_id | locale | setting_name | setting_value | setting_type
------------±------±-------------------±----------------±--------+
104 | pt_BR| affiliation | UFPA | string
(9385 rows)
ojsdatabase=# SELECT COUNT(*) FROM author_settings;
count
9385
(1 row)
CREATING CLEAR DATABASE AND RESTORE DUMP FROM PRODUCTION DATABASE
ojsdatabase=# DROP DATABASE ojsdatabasenew;
DROP DATABASE
ojsdatabase=# CREATE DATABASE ojsdatabasenew;
CREATE DATABASE
pg_dump -U pgsql seerojsdatabase --inserts > Backup-seerojsdatabase-10062020.sql
POPULATING NEW DATABASE
psql ojsdatabasenew
ojsdatabasenew=# \i ~user/Backup-seerojsdatabase-10062020.sql
NECESSARY ALTER THIS TO RUN UPGRADE (elseif the process are broken)
ojsdatabasenew=# ALTER TABLE author_settings ALTER COLUMN setting_type DROP NOT NULL;
ALTER TABLE
ojsdatabasenew=# ALTER TABLE journal_settings ALTER COLUMN setting_type DROP NOT NULL;
ALTER TABLE
ojsdatabasenew=# ALTER TABLE authors ALTER COLUMN submission_id DROP NOT NULL;
ALTER TABLE
ojsdatabasenew=#\q
PREPARING WEBSERVER TO MIGRATE
webserver# cd /usr/local/www/
fetch http://pkp.sfu.ca/ojs/download/ojs-3.2.0-2.tar.gz
tar -xvzf ojs-3.2.0-2.tar.gz
chown -R www:www ojs-3.2.0-2
chmod -R 755 ojs-3.2.0-2
cp -R ./ojs-3.1.2-4/public ./ojs-3.2.0-2/
chown -R www:www ojs-3.2.0-2
cp -R ./ojs-3.1.2-4/config.ini.php ./ojs-3.2.0-2/
cd ojs-3.2.0-2/tools
php upgrade.php check
Code version: 3.1.2.4
Database version: 3.1.2.4
php upgrade.php upgrade
Successfully upgraded to version 3.2.0.2
DATABASE SERVER (COMING BACK)
ojsdatabasenew=# SELECT * from authors;
author_id | submission_id | seq | email | user_group_id | include_in_browse | publication_id
------------±-----------------±----±-------------±--------------±-----------------±---------------
1181 | 1005 | 1 | user@domain.com | 31 | 1 |
ojsdatabasenew# SELECT COUNT(*) FROM authors;
count
1470
(1 row)
ojsdatabasenew=# SELECT * from author_settings;
author_id | locale | setting_name | setting_value | setting_type
------------±------±---------------------±----------------±--------------
104 | pt_BR| affiliation | UFPA | string
ojsdatabasenew=# SELECT COUNT(*) FROM author_settings;
count
12299 <== DIFFRENT NUMBERS OF ROWS FROM PRODUCTION DATABASE
(1 row)
OBSSERVATIONS:
All procedures were performed on a copy of the production database, using version ojs-3.2.0.2, where articles are imported but the authors disappear. If migrations are made using ojs-3.2.0.3, all authors and articles disappear as reported in the history of this post