[GeoNetwork-users] Difficulty migrating from GN3.2.1 to GN3.4.2

I have reduced my scope, still with no success: I am now trying to upgrade from 3.2.1 to 3.2.2 only.

The exact process I am following for the update is at https://1drv.ms/w/s!AnSnLykEGGAmrXSgsC8Wifr_Oy2y

I found in the geonetwork Users Archive significant discussion over the past year about adapting to XSRF-TOKEN security, which is introduced in GN3.2.2. I followed the note by Jose Garcia, suggesting to delete the two wro4j files in my external data structure, and then attempting the upgrade. The PostGIS metadata database gets updated to 3.2.2, and I get the GeoNetwork title so there is access, but the GUI is completely blank.

I now get errors related to wro4j:
2018-07-16 21:48:48,245 WARN [geonetwork.schemamanager] - Cannot resolve http://www.w3.org/2001/03/xml.xsd: will append last component to current path (not sure it will help though!)
2018-07-16 21:48:48,759 WARN [geonetwork.schemamanager] - WARNING: gco:Record is a global element without a type - assuming a string
2018-07-16 21:48:48,774 WARN [geonetwork.schemamanager] - WARNING: schema-substitutions.xml has wiped out XSD substitution list for gml:VerticalDatum
2018-07-16 21:48:48,784 WARN [geonetwork.schemamanager] - WARNING: schema-substitutions.xml has wiped out XSD substitution list for gml:CoordinateSystemAxis
2018-07-16 21:48:48,786 WARN [geonetwork.schemamanager] - WARNING: schema-substitutions.xml has wiped out XSD substitution list for gml:VerticalCS
2018-07-16 21:48:48,789 WARN [geonetwork.schemamanager] - WARNING: schema-substitutions.xml has wiped out XSD substitution list for gml:CoordinateSystemAxis
2018-07-16 21:48:50,383 WARN [geonetwork.schemamanager] - WARNING: gco:Record is a global element without a type - assuming a string
2018-07-16 21:48:52,939 WARN [geonetwork.lucene] - Stopwords file with incorrect ISO 639-2 language as filename: README
2018-07-16 21:48:59,889 ERROR [geonetwork.wro4j] - Error while loading wro4j model
java.lang.NullPointerException
at java.io.File.<init>(File.java:277)
at org.fao.geonet.wro4j.GeonetWroModelFactory.parseSource(GeonetWroModelFactory.java:659)
at org.fao.geonet.wro4j.GeonetWroModelFactory.configureJavascripDependencyManager(GeonetWroModelFactory.java:575)
at org.fao.geonet.wro4j.GeonetWroModelFactory.loadGroupsUsingRequireDependencyManagement(GeonetWroModelFactory.java:380)
at org.fao.geonet.wro4j.GeonetWroModelFactory.createModel(GeonetWroModelFactory.java:191)
at org.fao.geonet.wro4j.GeonetWroModelFactory.createModel(GeonetWroModelFactory.java:163)
at org.fao.geonet.wro4j.GeonetWroModelFactory.create(GeonetWroModelFactory.java:121)
at org.fao.geonet.wro4j.GeonetWroModelFactory.create(GeonetWroModelFactory.java:66)
at ro.isdc.wro.model.factory.WroModelFactoryDecorator.create(WroModelFactoryDecorator.java:27)
at ro.isdc.wro.model.factory.FallbackAwareWroModelFactory.create(FallbackAwareWroModelFactory.java:48)
at ro.isdc.wro.model.factory.FallbackAwareWroModelFactory.create(FallbackAwareWroModelFactory.java:22)
at ro.isdc.wro.model.factory.WroModelFactoryDecorator.create(WroModelFactoryDecorator.java:27)
at ro.isdc.wro.model.factory.ModelTransformerFactory.create(ModelTransformerFactory.java:55)
etceterra

-------- Forwarded Message --------
Re: Difficulty migrating from GN3.2.1 to GN3.4.2, <2018-07-13 15:38>

I am having difficulty migrating from GN3.2.1 to GN3.4.2, and I strongly suspect I am doing something procedurally wrong. I previously had similar problems migrating from 3.0.1 to 3.2.1 and ended by re-entering all the metadata. I would like to determine what I do wrong.

As a process, in Linux CentOS I do the following:
1. back up existing PostGIS database
2. ensure the GN data directory is remote from the deploy location
3. ensure the Jetty9 (as a service) webserver variables and options correctly set
4. download GN3.4.2 WAR
5. unzip and modify WAR for jetty-env.xml, jdbc.properties, and srv.xml for database name, userID, PW and port.
6. remove existing GN3.2.1 from jetty deploy location
7. delete the metadata_subversion directory to avoid 3.2.1 vs 3.4.2 error (deployment will rebuild)
8. reboot the server to avoid "duplicate node" error
9. place modified GN tree in webapps deployment location
10. get error like "database migration failed - try manual"

I am stuck /- /any suggestions?

---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus

Hi Terry,

My environment is slightly different to yours in that I'm using tomcat8 and
ubuntu linux (but still postgresql) but I thought I should let you know
that it is possible to upgrade- I have just done one from 2.10 to 3.4.3
without too much trouble. The last few times I've done this I have found
that the database upgrade fails at around 3.2.2. To find the exact point at
which it fails, I look in the settings table for the version number, then
stop tomcat. The catalina.out log file contains the error message, but
generally it's quite early in the log. I then go to the
WEB-INF/classes/setup/sql/migrate folder and find the sql for the version
that it failed on. Running that SQL manually gives you the full error, then
you can adapt the sql as necessary (generally I've found that the commented
out statements that should be added automatically by hibernate are not
always added). Once that sql has worked, restarting tomcat generally allows
the upgrade to continue without failure.

If you're getting a blank interface, have you tried a chrome incognito
window and adding the debug parameter at the end of the URL? I find
geonetwork caches very aggressively but that tends to work.

Hope that helps a little bit,

Jo

On Tue, Jul 17, 2018 at 7:02 AM, Terry <terry.curran@anonymised.com> wrote:

I have reduced my scope, still with no success: I am now trying to
upgrade from 3.2.1 to 3.2.2 only.

The exact process I am following for the update is at
https://1drv.ms/w/s!AnSnLykEGGAmrXSgsC8Wifr_Oy2y

I found in the geonetwork Users Archive significant discussion over the
past year about adapting to XSRF-TOKEN security, which is introduced in
GN3.2.2. I followed the note by Jose Garcia, suggesting to delete the two
wro4j files in my external data structure, and then attempting the
upgrade. The PostGIS metadata database gets updated to 3.2.2, and I get
the GeoNetwork title so there is access, but the GUI is completely blank.

I now get errors related to wro4j:
2018-07-16 21:48:48,245 WARN [geonetwork.schemamanager] - Cannot resolve
http://www.w3.org/2001/03/xml.xsd: will append last component to current
path (not sure it will help though!)
2018-07-16 21:48:48,759 WARN [geonetwork.schemamanager] - WARNING:
gco:Record is a global element without a type - assuming a string
2018-07-16 21:48:48,774 WARN [geonetwork.schemamanager] - WARNING:
schema-substitutions.xml has wiped out XSD substitution list for
gml:VerticalDatum
2018-07-16 21:48:48,784 WARN [geonetwork.schemamanager] - WARNING:
schema-substitutions.xml has wiped out XSD substitution list for
gml:CoordinateSystemAxis
2018-07-16 21:48:48,786 WARN [geonetwork.schemamanager] - WARNING:
schema-substitutions.xml has wiped out XSD substitution list for
gml:VerticalCS
2018-07-16 21:48:48,789 WARN [geonetwork.schemamanager] - WARNING:
schema-substitutions.xml has wiped out XSD substitution list for
gml:CoordinateSystemAxis
2018-07-16 21:48:50,383 WARN [geonetwork.schemamanager] - WARNING:
gco:Record is a global element without a type - assuming a string
2018-07-16 21:48:52,939 WARN [geonetwork.lucene] - Stopwords file with
incorrect ISO 639-2 language as filename: README
2018-07-16 21:48:59,889 ERROR [geonetwork.wro4j] - Error while loading
wro4j model
java.lang.NullPointerException
        at java.io.File.<init>(File.java:277)
        at org.fao.geonet.wro4j.GeonetWroModelFactory.parseSource(Geone
tWroModelFactory.java:659)
        at org.fao.geonet.wro4j.GeonetWroModelFactory.configureJavascri
pDependencyManager(GeonetWroModelFactory.java:575)
        at org.fao.geonet.wro4j.GeonetWroModelFactory.loadGroupsUsingRe
quireDependencyManagement(GeonetWroModelFactory.java:380)
        at org.fao.geonet.wro4j.GeonetWroModelFactory.createModel(Geone
tWroModelFactory.java:191)
        at org.fao.geonet.wro4j.GeonetWroModelFactory.createModel(Geone
tWroModelFactory.java:163)
        at org.fao.geonet.wro4j.GeonetWroModelFactory.create(GeonetWroM
odelFactory.java:121)
        at org.fao.geonet.wro4j.GeonetWroModelFactory.create(GeonetWroM
odelFactory.java:66)
        at ro.isdc.wro.model.factory.WroModelFactoryDecorator.create(Wr
oModelFactoryDecorator.java:27)
        at ro.isdc.wro.model.factory.FallbackAwareWroModelFactory.creat
e(FallbackAwareWroModelFactory.java:48)
        at ro.isdc.wro.model.factory.FallbackAwareWroModelFactory.creat
e(FallbackAwareWroModelFactory.java:22)
        at ro.isdc.wro.model.factory.WroModelFactoryDecorator.create(Wr
oModelFactoryDecorator.java:27)
        at ro.isdc.wro.model.factory.ModelTransformerFactory.create(Mod
elTransformerFactory.java:55)
      etceterra

-------- Forwarded Message --------
Re: Difficulty migrating from GN3.2.1 to GN3.4.2, <2018-07-13 15:38>

I am having difficulty migrating from GN3.2.1 to GN3.4.2, and I strongly
suspect I am doing something procedurally wrong. I previously had similar
problems migrating from 3.0.1 to 3.2.1 and ended by re-entering all the
metadata. I would like to determine what I do wrong.

As a process, in Linux CentOS I do the following:
1. back up existing PostGIS database
2. ensure the GN data directory is remote from the deploy location
3. ensure the Jetty9 (as a service) webserver variables and options
correctly set
4. download GN3.4.2 WAR
5. unzip and modify WAR for jetty-env.xml, jdbc.properties, and srv.xml
for database name, userID, PW and port.
6. remove existing GN3.2.1 from jetty deploy location
7. delete the metadata_subversion directory to avoid 3.2.1 vs 3.4.2 error
(deployment will rebuild)
8. reboot the server to avoid "duplicate node" error
9. place modified GN tree in webapps deployment location
10. get error like "database migration failed - try manual"

I am stuck /- /any suggestions?

---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
GeoNetwork-users mailing list
GeoNetwork-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geonetwork-users
GeoNetwork OpenSource is maintained at http://sourceforge.net/project
s/geonetwork

--
*Jo Cook*
t:+44 7930 524 155/twitter:@archaeogeek
Please note that currently I do not work on Friday afternoons. For urgent
responses at that time, please visit support.astuntechnology.com or phone
our office on 01372 744009

--
--
Astun Technology Ltd, The Coach House, 17 West Street, Epsom, Surrey,
KT18 7RL, UK
t:+44 1372 744 009 w: astuntechnology.com
<http://astuntechnology.com/&gt; twitter:@astuntech
<https://twitter.com/astuntech&gt;

iShare - enterprise geographic
intelligence platform <https://astuntechnology.com/ishare/&gt;
GeoServer,
PostGIS and QGIS training <https://astuntechnology.com/services/#training&gt;

Helpdesk and customer portal
<http://support.astuntechnology.com/support/login&gt;

Company registration
no. 5410695. Registered in England and Wales. Registered office: 120 Manor
Green Road, Epsom, Surrey, KT19 8LN VAT no. 864201149.