Database upgrade failed OJS 2.4.8 to 3.0.0

Hi!

I’ve received a error message while updating the database:

ERROR: Upgrade failed: DB: Illegal mix of collations (latin1_swedish_ci,IMPLICIT), (utf8_general_ci,COERCIBLE), (utf8_general_ci,COERCIBLE) for operation 'replace'

Does anyone knows how to fix it?

Hi @rafaelmansilha,

This suggests that your database has somehow changed its character set configuration.

Check to make sure that your old config.inc.php and new config.inc.php have the same character set settings. If your old database was Latin1 and you would like your new database to be UTF-8 (and UTF-8 is definitely our recommendation), you may need to transcode your database using a tool like iconv.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher

Thanks!

Hi,

We got another issue, i’ve seen this post, and i’m getting this errors:

`code: Installer Installer::migrateFiles]
WARNING: Unable to find a match for “1546-9532-1-??.jpg” in “files/journals/20//articles/1546/”. Skipping this file.
WARNING: Unable to find a match for “1546-9533-1-??.jpg” in “files/journals/20//articles/1546/”. Skipping this file.
WARNING: Unable to find a match for “1579-9671-1-??.jpg” in “files/journals/20//articles/1579/”. Skipping this file.
[…]

[code: Installer Installer::convertSupplementaryFiles]
PHP Warning: Invalid argument supplied for foreach() in /var/www/ojs/releases/20160930181631/classes/install/Upgrade.inc.php on line 1182
PHP Warning: Invalid argument supplied for foreach() in /var/www/ojs/releases/20160930181631/classes/install/Upgrade.inc.php on line 1191
PHP Warning: Invalid argument supplied for foreach() in /var/www/ojs/releases/20160930181631/classes/install/Upgrade.inc.php on line 1182
[…]

DB Error: Data too long for column 'label' at row 1

ojs2: DB Error: Data too long for column 'label' at row 1`

About the [code: Installer Installer::convertSupplementaryFiles] issue, i’ve have done this @asmecher suggestion, but i’m still getting the problem.

And, about the [code: Installer Installer::migrateFiles], i’ve look at my aticles table, like this suggestion, and there is no section_id = NULL

If helps this is one of the error row:

# article_id, user_id, journal_id, section_id, language, comments_to_ed, date_submitted, last_modified, date_status_modified, status, submission_progress, current_round, submission_file_id, revised_file_id, review_file_id, editor_file_id, pages, fast_tracked, hide_author, comments_status, locale, citations
'1546', '5126', '20', '59', 'pt', 'Submissão relativa ao trabalho de PIBIC premiado no SIC.', '2015-09-07 23:12:09', '2016-09-06 10:03:29', '2015-12-03 10:26:12', '3', '0', '1', '9529', NULL, '9537', NULL, '76-88', '0', '0', '0', 'pt_BR', 'AMAKO, K.; CHEN, G.X.; ASADA, K. 1994. Separate assays specific for ascorbate peroxidase and guaiacol peroxidase and for the chloroplastic and cytosolic isozymes of ascorbate peroxidase in plants. Plant Cell Physiology 35: 497-504.\r\nANDREWS, M.; LEA, P.; RAVEN, J.; AZEVEDO, R. 2009. Nitrogen use efficiency. 3. Nitrogen fixation: genes and costs. Annals of Applied Biology 155: 1-13.\r\nANTÓN, M.; FERNÁNDEZ-PASCUAL, M.; SÁNCHEZ, M.L.; FEDOROVA, E.; HERRERO, M.G.; SAMA, A.; PEREIRA, L.G.; CARRETERO, C.; HERAS, N.M.L.; GUANCHE, J.P.; DABAD, J.P.; RODRÍGUEZ, A.V. 2006. Factores estructurales, bioquímicos y moleculares de la simbiosis Bradyrhizobium sp. (Lupinus)-Lupinus. Anales de la Real Academia Nacional de Farmacia 72: 423-442.\r\nASADA, K. 2006. Production and scavenging of reactive oxygen species in chloroplasts and their functions. Plant Physiology 141: 391-396.\r\nBEAUCHAMP, C.; FRIDOVICH, I. 1971. Superoxide dismutase: Improved assay applicable to acrylamide gels. Analytical Biochemistry 44: 2762-2787.\r\nBECANA, M.; MATAMOROS, M.A.; UDVARDI, M.; DALTON, D.A. 2010. Recent insights into antioxidant defenses of legume root nodules. New Phytologist 188: 960-976.\r\nBRENNAN, T.; FRENKEL, C. 1977. Involvement of hydrogen peroxide the regulation of senescence in pear. Plant Physiology 59: 411-416.\r\nCARVALHO, F.E.; LOBO, A.K.; BONIFACIO, A.; MARTINS, M.O.; NETO, M.C.L.;SILVEIRA, J.A. 2011. Aclimatação ao estresse salino em plantas de arroz induzida pelo pré-tratamento com H2O2. Revista Brasileira de Engenharia Agrícola e Ambiental 15(4): 416-\r\n423.\r\nCATTIVELLI, L.; RIZZA, F.; BADECK, F.W.; MAZZUCOTELLI, E.; MASTRANGELO,A.; FRANCIA, E.; MARÉ, C.; TONDELLI, A.; STANCA, A. 2008. Drought tolerance improvement in crop plants: An integrated view from breeding to genomics. Field Crops Research 105: 1-14.\r\nCHANG, C.; DAMIANI, I.; PUPPO, A.; FRENDO, P. 2009. Redox Changes during the Legume-Rhizobium Symbiosis. Molecular Plant 2(3): 370-377.\r\nDUBOIS, M.; GILLES, K.A.; HAMILTON, J.K.; REBERS P.A.; SMITH, F. 1956. Colorimetric method for determination of sugars and related substances. Analytical Chemical 28: 350-356.\r\nFOYER, C.H.; BLOOM, A.J.; QUEVAL, G.; NOCTOR, G. 2009. Photorespiratory metabolism: genes, mutants, energetics, and redox signaling. Annual Review of Plant Physiology 60: 455-484.\r\nGIANOPOLITIS, C.N.; RIES, S.K. 1977. Superoxide dismutases: I. Occurrence in Higher Plants. Plant Physiology 59: 309-314.\r\nHAVIR, E.A.; MCHALE, N.A. 1987. Biochemical and Developmental Characterization of Multiple Forms of Catalase in Tobacco-Leaves. Plant Physiology 84(2): 450-455.\r\nHOAGLAND, D.; ARNON, D.I. 1950. The water culture method for growing plants without soil. California: Agriculture Experimental Station Circular. 347 p.\r\nLEA, P.J.; AZEVEDO, R.A. 2006. Nitrogen use efficiency. 1. Uptake of nitrogen from the soil. Annals of Applied Biology 149: 243-247.\r\nMAHAJAN, S.; TUTEJA, N. 2005. Cold, salinity and drought stresses: An overview. Archives of Biochemistry and Biophysics 444(2); 139-158.\r\nMILLER, G.; SUZUKI, N.; CIFTCI-YILMAZ, S.; MITTLER, R. 2010. Reactive oxygen species homeostasis and signaling during drought and salinity stresses. Plant, Cell and Environment 33: 453-467.\r\nMITTLER, R. 2006. Abiotic stress, the field environment and stress combination. Trends in Plant Science 11(1): 15-19.\r\nMØLLER, I.M.; JENSEN, P.E.; HANSSON, A. 2007. Oxidative modifications to cellular components in plants. Annual Review of Plant Biology 58: 459-481.\r\nMUNNS, R.; TESTER, M. 2008. Mechanisms of Salinity Tolerance. Annual Review of Plant Biology 59: 651-681.\r\nNGUYEN, G.N.; HAILSTONES, D.L.; WILKES, M.; SUTTON, B.G. 2009. Droughtinduced oxidative conditions in rice anthers leading to a programmed cell death and pollen abortion. Journal of Agronomy e Crop Science 195: 157-164.\r\nRODRIGUES, A.C.; BONIFACIO, A.; ANTUNES, J.E.L.; SILVEIRA, J.A.G.; FIGUEIREDO, M.V. B. 2013. Minimization of oxidative stress in cowpea nodules by the interrelationship between Bradyrhizobium sp. and plant growth-promoting bacteria. Applied Soil Ecology 64: 245-251.\r\nSILVEIRA, J.A.G.; CONTADO, J.; RODRIGUES, J.; OLIVEIRA, J. 1998. Phosphoenolpyruvate carboxylase and glutamine synthetase activities in relation to nitrogen fixation in cowpea nodules. Revista Brasileira de Fisiologia Vegetal 10: 19-23. \r\nVANCE, C.P. 2008. Carbon and nitrogen metabolism in legume nodules. In: Nitrogen-Fixing Leguminous Symbioses (pp. 293-320). Springer Netherlands.\r\nWEATHERBURN, M.W. 1967. Phenol-hypochlorite reaction for determination of ammonia.Analytical Chemistry 39: 971-974.\r\nYEMM, E.W.; COCKING, E.F. 1955. The determination of amino acids with ninhydrin. Analyst 80: 209-213.'

And, there is a bug on templates/common/header.tpl

<li><a href="{url router=$smarty.const.ROUTE_PAGE page="manageIssues anchor="futureIssues"}">{translate key="editor.issues.futureIssues"}</a></li>

it should br

<li><a href="{url router=$smarty.const.ROUTE_PAGE page="manageIssues" anchor="futureIssues"}">{translate key="editor.issues.futureIssues"}</a></li>

Hi @rafaelmansilha,

The template typo you note has already been fixed:

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

@asmecher great! Can you help me about this?

I had similar “Unable to find a match” errors and the reason was that the file extension was written in capital letters. So maybe you have .JPG files in your filed dir?

Hi @rafaelmansilha,

Try this change for the comment_title issue. As for the missing files, I’d suggest investigating one or two to see whether the files are expected to be in a different location or whether they are truly missing. Note that if you’ve tried an upgrade once, the files will already be moved and thus warnings will be reported.

Regards,
Alec Smecher
Public Knowledge Project Team

HI @asmecher!

Finally we managed to make the system upgrade. We had to change the file dbscripts/xml/ojs_schema.xml

<field name="submission_id" type="I8"> <NOTNULL/> </field> -<field name="label" type="C2" size="255"/> +<field name="label" type="X"/>

But I noticed that the PKP-ALM plugin disappeared, this is correct? When you upgrade we lose this data?

Regards,
Rafael Mansilha

Hi @rafaelmansilha,

Glad to hear you got it going!

The ALM plugin hasn’t yet been forward-ported to OJS 3.0 (we’re working on this for numerous plugins). If and when it is, you shouldn’t lose any data.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher,

I realized now that a lot of the plugins were not moved

Following the instructions in docs/UPGRADE we did the Full Package upgrade by copying only the files:
`- config.inc.php

  • Public /
  • Your uploaded files directory (“files_dir” in config.inc.php)`

The plugins data are stored in these directories, or in the DB, right?

Regards,
Rafael Mansilha

Hi @rafaelmansilha,

The plugin data is stored in the database, typically. Not all OJS 2.x plugins are yet available in OJS 3.x, and some 3.x plugins are new to that version – what plugins are you particularly interested in?

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher

Actually I can not tell you, we have 31 Jornauls, with several editors. I’m just doing a conference before applying the update on production. On the directories I found that the following plugins are missing. I don’t really know which one is used or not. Among them I know the PKP-ALM is used and LDAP is not

./auth:
ldap

./blocks:
authorBios
donation
flagLanguageToggle
fontSize
help
keywordCloud
navigation
notification
readingTools
role
subscription
user

./citationOutput:
abnt
apa
mla
vancouver

./gateways:
metsGateway

./generic:
alm
announcementFeed
backup
booksForReview
coins
counter
customLocale
dataverse
doiInSummary
driver
externalFeed
googleViewer
lucene
objectsForReview
openAIRE
phpMyVisites
piwik
pln
referral
roundedCorners
sehl
stopForumSpam
sword
thesis
thesisFeed
translator
xmlGalley

./implicitAuth:
shibboleth

./importexport:
duracloud
erudit
mets
quickSubmit
sample

./reports:
counter
subscriptions
timedView
views

./themes:
blueSteel
classicBlue
classicBrown
classicGreen
classicNavy
classicRed
custom
desert
lilac
night
redbar
steel
uncommon
vanilla

Hi @rafaelmansilha,

That’s expected – the set of plugins for OJS 3.x is different than those for OJS 2.x, though most of the major ones are included in both. The ALM plugin, for example, has not yet been forward-ported to OJS 3.0.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher,

Ok, we will proced with the upgrade. Thank you for all suport!

Regards,
Rafael Mansilha

Hi, I am afraid I messed up the database when upgrading from 2.8.1 to 3.02 I tried to reinstall 2.8.1 but I get the error message: " Errors occurred during installation: A database error has occurred: Duplicate entry ‘tinymceplugin–0-enabled’ for key 1". The OJS system is on a hosting server (GoDaddy) under Windows. Any advice?

Hi @tkomives,

Rather than reopening an old thread, I’d suggest posting your question as a new topic. Note that if your upgrade has failed, you’ll need to restore from backup before trying again – running the upgrade a second time on a failed upgrade will not work.

Regards,
Alec Smecher
Public Knowledge Project Team

Thanks, Alec, for your quick reply. In the meantime, I recovered the database from a recent backup and now almost everything works again under the old 2.8.1 system (except the “USER BLOCK” in the Navigation Bar, so I cannot log in as a Site Manager; http://www.ecocycles.eu/ojs/index.php/Ecocycles/index). Before giving the upgrade another try I will read the guidelines very carefully. Thanks, again, Tamas