Upgrade to ojs2.4.8 to 3.1.2.1

Hi,

I am trying to update ojs2.4.8 to ojs3.2.1:

  • I have modify config.inc.php from “mysql to mysqli” because I had a Fatal error: Uncaught Error: Call to undefined function mysql_pconnect() in /home/lib/pkp/lib/adodb/drivers/adodb-mysql.inc.php:475

Afterthat, I have this message error:

[code: Installer Installer::installDefaultNavigationMenus]
Notice: unserialize(): Error at offset 3882 of 4099 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 72 of 3768 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 50 of 355 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 375 of 1541 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352

[code: Installer Installer::migrateStaticPagesToNavigationMenuItems]
Notice: unserialize(): Error at offset 3882 of 4099 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 72 of 3768 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 50 of 355 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 375 of 1541 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352

[code: Installer Installer::migrateSRLocale]

[code: Installer Installer::migrateUserAndAuthorNames]
Notice: unserialize(): Error at offset 3882 of 4099 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 72 of 3768 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 50 of 355 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 375 of 1541 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352

[code: Installer Installer::concatenateIntoAbout]
Notice: unserialize(): Error at offset 3882 of 4099 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 3882 of 4099 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 72 of 3768 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 50 of 355 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 72 of 3768 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 50 of 355 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 375 of 1541 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 375 of 1541 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352

[code: Installer Installer::concatenateIntoMasthead]
Notice: unserialize(): Error at offset 3882 of 4099 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 3882 of 4099 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 72 of 3768 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 50 of 355 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 72 of 3768 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 50 of 355 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 375 of 1541 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: unserialize(): Error at offset 375 of 1541 bytes in /home/_ojs3_hp/lib/pkp/classes/db/DAO.inc.php on line 352
Notice: Undefined index: CS in /home/_ojs3_hp/classes/install/Upgrade.inc.php on line 2259

I have checked a post by @asmecher about it, but I think the configuration in config.inc is ok (is working ok in ojs 2.4.8)

[i18n]

; Default locale
locale = en_US

; Client output/input character set
client_charset = utf-8

; Database connection character set
; Must be set to “Off” if not supported by the database server
; If enabled, must be the same character set as “client_charset”
; (although the actual name may differ slightly depending on the server)
connection_charset = utf-8

; Database storage character set
; Must be set to “Off” if not supported by the database server
database_charset = utf-8

; Enable character normalization to utf-8
; If disabled, strings will be passed through in their native encoding
; Note that client_charset and database collation must be set
; to “utf-8” for this to work, as characters are stored in utf-8
; (Note that this is generally no longer needed, as UTF8 adoption is good.)
charset_normalization = Off

Any idea, what can I do?

Thank you very much.

Hi @ipa,

See e.g. Charset problems (ISO-8859-1 x UTF-8) – the differences between utf8 and utf-8 are important! Make sure you mimic the settings in your old configuration file exactly.

Regards,
Alec Smecher
Public Knowledge Project Team

Thank you @asmecher ,

I had checked the values that work in 2.4.8 and are correct:
locale = en_US
client_charset = utf-8
connection_charset = utf-8
database_charset = utf-8

In the database are “utf8_general_ci” and “utf8_unicode_ci” in the fields.
I could remove charset_normalization = Off, but I think it is not used in the new version.

I read the other posts but I don’t understand how to solve the problems.

thank you very much

Hi @ipa,

Those values are incorrect for OJS 2.x too – it’s always been this way (as we’ve always used the same library toolset, such as ADODB).

However, even if these are set incorrectly, you shouldn’t introduce problems when you move from OJS 2.x to OJS 3.x – the same incorrect configuration should continue to work the same way. So I wonder if it’s possible that an additional problem was introduced during a database dump/load process?

I would suggest investigating this thread/post: Submission download unserialize() error at DAO.inc.php:350

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher,

thank you very much. Yes the problem I think is something about PHP version that moves some charset by default. I will try to find where is the problem.

Thank you again.