Discussion:
[Exist-open] Migration from 2.2 to 3.2
Andreas Jung
2017-06-17 15:02:50 UTC
Permalink
Hi there,

I am trying to migrate a project from exist 2.2 to 3.2.

I created a full backup of 2.2 and now I am trying a restore using


bin/backup.sh -u admin -p XXXX -r /tmp/full20170617-1651/db/__contents__.xml

This fails with

org.apache.xmlrpc.XmlRpcException: Failed to read server's response: Connection refused (Connection refused)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:161)
at org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(XmlRpcHttpTransport.java:143)
at org.apache.xmlrpc.client.XmlRpcSunHttpTransport.sendRequest(XmlRpcSunHttpTransport.java:69)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:56)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:167)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:158)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:147)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:81)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:72)
at org.exist.xmldb.DatabaseImpl.readCollection(DatabaseImpl.java:265)
at org.exist.xmldb.DatabaseImpl.getRemoteCollection(DatabaseImpl.java:227)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:167)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
Caused by: java.net.ConnectException: Connection refused (Connection refused)
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
at sun.net.www.http.HttpClient.New(HttpClient.java:339)
at sun.net.www.http.HttpClient.New(HttpClient.java:357)
at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1202)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1138)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1032)
at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:966)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream0(HttpURLConnection.java:1316)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1291)
at org.apache.xmlrpc.client.XmlRpcSunHttpTransport.writeRequest(XmlRpcSunHttpTransport.java:104)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:151)
... 22 more
Caused by:
java.net.ConnectException: Connection refused (Connection refused)


However the 3.2 server is running with default settings
anything I am missing?

Andreas


17 Jun 2017 16:59:14,237 [main] INFO (JettyStart.java [lifeCycleStarting]:616) - Jetty server starting...
17 Jun 2017 16:59:14,738 [main] INFO (JettyStart.java [lifeCycleStarted]:625) - Jetty server started.
17 Jun 2017 16:59:14,739 [main] WARN (JettyStart.java [run]:234) - Could not find OpenID extension. OpenID will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:241) - Could not find OAuthServlet extension. OAuth will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:248) - Could not find IPRangeServlet extension. IPRange will be disabled!
17 Jun 2017 16:59:14,743 [main] INFO (JettyStart.java [run]:257) - -----------------------------------------------------
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:258) - Server has started, listening on:
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) - http://XXX:8088/
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) - https://XXX:8451/
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:263) - Configured contexts:
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:269) - /
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:323) - -----------------------------------------------------
Joe Wicentowski
2017-06-17 17:29:32 UTC
Permalink
Hi Andreas,

Just an observation: the server is starting up on port 8088. Does backup.sh
know to connect on that port, instead of 8080?

Joe
Post by Andreas Jung
Hi there,
I am trying to migrate a project from exist 2.2 to 3.2.
I created a full backup of 2.2 and now I am trying a restore using
bin/backup.sh -u admin -p XXXX -r
/tmp/full20170617-1651/db/__contents__.xml
This fails with
Connection refused (Connection refused)
at
org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:161)
at
org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(XmlRpcHttpTransport.java:143)
at
org.apache.xmlrpc.client.XmlRpcSunHttpTransport.sendRequest(XmlRpcSunHttpTransport.java:69)
at
org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:56)
at
org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:167)
at
org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:158)
at
org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:147)
at
org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:81)
at
org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:72)
at
org.exist.xmldb.DatabaseImpl.readCollection(DatabaseImpl.java:265)
at
org.exist.xmldb.DatabaseImpl.getRemoteCollection(DatabaseImpl.java:227)
at
org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:167)
at
org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
Caused by: java.net.ConnectException: Connection refused (Connection refused)
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net
.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at java.net
.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net
.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
at sun.net.www.http.HttpClient.New(HttpClient.java:339)
at sun.net.www.http.HttpClient.New(HttpClient.java:357)
at
sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1202)
at
sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1138)
at
sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1032)
at
sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:966)
at
sun.net.www.protocol.http.HttpURLConnection.getOutputStream0(HttpURLConnection.java:1316)
at
sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1291)
at
org.apache.xmlrpc.client.XmlRpcSunHttpTransport.writeRequest(XmlRpcSunHttpTransport.java:104)
at
org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:151)
... 22 more
java.net.ConnectException: Connection refused (Connection refused)
However the 3.2 server is running with default settings
anything I am missing?
Andreas
17 Jun 2017 16:59:14,237 [main] INFO (JettyStart.java
[lifeCycleStarting]:616) - Jetty server starting...
17 Jun 2017 16:59:14,738 [main] INFO (JettyStart.java
[lifeCycleStarted]:625) - Jetty server started.
17 Jun 2017 16:59:14,739 [main] WARN (JettyStart.java [run]:234) - Could
not find OpenID extension. OpenID will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:241) - Could
not find OAuthServlet extension. OAuth will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:248) - Could
not find IPRangeServlet extension. IPRange will be disabled!
17 Jun 2017 16:59:14,743 [main] INFO (JettyStart.java [run]:257) -
-----------------------------------------------------
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:258) - Server
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) -
http://XXX:8088/
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) -
https://XXX:8451/
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:269) - /
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:323) -
-----------------------------------------------------------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Exist-open mailing list
https://lists.sourceforge.net/lists/listinfo/exist-open
--
Sent from my iPhone
a***@uni-koeln.de
2017-06-17 21:24:53 UTC
Permalink
since the recent changes of commandline parameter handling you have to
use the -ouri=xmldb:exist:///
to connect to a vanilla eXistdb server on localhost:8080 (no default
anymore, the docs still say so).
So I presume your backup will work with -ouri (and the correct port).

regards
Peter
Post by Andreas Jung
Hi there,
I am trying to migrate a project from exist 2.2 to 3.2.
I created a full backup of 2.2 and now I am trying a restore using
bin/backup.sh -u admin -p XXXX -r /tmp/full20170617-1651/db/__contents__.xml
This fails with
Connection refused (Connection refused)
at
org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:161)
at
org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(XmlRpcHttpTransport.java:143)
at
org.apache.xmlrpc.client.XmlRpcSunHttpTransport.sendRequest(XmlRpcSunHttpTransport.java:69)
at
org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:56)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:167)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:158)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:147)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:81)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:72)
at org.exist.xmldb.DatabaseImpl.readCollection(DatabaseImpl.java:265)
at org.exist.xmldb.DatabaseImpl.getRemoteCollection(DatabaseImpl.java:227)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:167)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
Caused by: java.net.ConnectException: Connection refused (Connection refused)
at java.net.PlainSocketImpl.socketConnect(Native Method)
at
java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at
java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at
java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
at sun.net.www.http.HttpClient.New(HttpClient.java:339)
at sun.net.www.http.HttpClient.New(HttpClient.java:357)
at
sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1202)
at
sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1138)
at
sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1032)
at
sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:966)
at
sun.net.www.protocol.http.HttpURLConnection.getOutputStream0(HttpURLConnection.java:1316)
at
sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1291)
at
org.apache.xmlrpc.client.XmlRpcSunHttpTransport.writeRequest(XmlRpcSunHttpTransport.java:104)
at
org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:151)
... 22 more
java.net.ConnectException: Connection refused (Connection refused)
However the 3.2 server is running with default settings…anything I
am missing?
Andreas
17 Jun 2017 16:59:14,237 [main] INFO (JettyStart.java
[lifeCycleStarting]:616) - Jetty server starting...
17 Jun 2017 16:59:14,738 [main] INFO (JettyStart.java
[lifeCycleStarted]:625) - Jetty server started.
17 Jun 2017 16:59:14,739 [main] WARN (JettyStart.java [run]:234) -
Could not find OpenID extension. OpenID will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:241) -
Could not find OAuthServlet extension. OAuth will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:248) -
Could not find IPRangeServlet extension. IPRange will be disabled!
17 Jun 2017 16:59:14,743 [main] INFO (JettyStart.java [run]:257) -
-----------------------------------------------------
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:258) -
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) -
http://XXX:8088/
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) -
https://XXX:8451/
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:263) -
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:269) - /
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:323) -
-----------------------------------------------------
Andreas Jung
2017-06-18 07:07:07 UTC
Permalink
So I started the restore process with

-ouri=xmldb:exist:///localhost:8088

However this leads to this error (I removed the dbx, log and lck files before starting the existdb instance as recommended.

———

Using locale: en_US.UTF-8
Starting restore of backup...
Processing backup: /tmp/full20170617-1651/db/system/security/__contents__.xml
Creating collection /db/system/security
An unrecoverable error occurred while restoring
collection '/db/system/security'. Aborting restore!
Finished restore of backup.
configuration error: org.exist.storage.BrokerPoolServiceException: org.exist.EXistException: The directory seems to be locked by another database instance. Found a valid lock file: /home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/dbx_dir.lck
------------------------------------
Problems occured found during restore:
WARN: An unrecoverable error occurred while restoring
collection '/db/system/security'. Aborting restore!
ERROR: configuration error: org.exist.storage.BrokerPoolServiceException: org.exist.EXistException: The directory seems to be locked by another database instance. Found a valid lock file: /home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/dbx_dir.lck


If you restored collections inside /db/apps, you may want
to rebuild the application repository. To do so, run the following query
as admin:

import module namespace repair="http://exist-db.org/xquery/repo/repair"
at "resource:org/exist/xquery/modules/expathrepo/repair.xql";
repair:clean-all(),
repair:repair()

org.xmldb.api.base.XMLDBException: configuration error: org.exist.storage.BrokerPoolServiceException: org.exist.EXistException: The journal log directory seems to be locked by another eXist process. A lock file: /home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/journal.lck is present in the log directory. Last access to the lock file: Jun 18, 2017 9:04:39 AM
at org.exist.xmldb.DatabaseImpl.configure(DatabaseImpl.java:116)
at org.exist.xmldb.DatabaseImpl.getLocalCollection(DatabaseImpl.java:179)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:165)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
Caused by: org.exist.EXistException: org.exist.storage.BrokerPoolServiceException: org.exist.EXistException: The journal log directory seems to be locked by another eXist process. A lock file: /home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/journal.lck is present in the log directory. Last access to the lock file: Jun 18, 2017 9:04:39 AM
since the recent changes of commandline parameter handling you have to use the -ouri=xmldb:exist:///
to connect to a vanilla eXistdb server on localhost:8080 (no default anymore, the docs still say so).
So I presume your backup will work with -ouri (and the correct port).
regards
Peter
Post by Andreas Jung
Hi there,
I am trying to migrate a project from exist 2.2 to 3.2.
I created a full backup of 2.2 and now I am trying a restore using
bin/backup.sh -u admin -p XXXX -r /tmp/full20170617-1651/db/__contents__.xml
This fails with
org.apache.xmlrpc.XmlRpcException: Failed to read server's response: Connection refused (Connection refused)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:161)
at org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(XmlRpcHttpTransport.java:143)
at org.apache.xmlrpc.client.XmlRpcSunHttpTransport.sendRequest(XmlRpcSunHttpTransport.java:69)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:56)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:167)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:158)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:147)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:81)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:72)
at org.exist.xmldb.DatabaseImpl.readCollection(DatabaseImpl.java:265)
at org.exist.xmldb.DatabaseImpl.getRemoteCollection(DatabaseImpl.java:227)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:167)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
Caused by: java.net.ConnectException: Connection refused (Connection refused)
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
at sun.net.www.http.HttpClient.New(HttpClient.java:339)
at sun.net.www.http.HttpClient.New(HttpClient.java:357)
at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1202)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1138)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1032)
at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:966)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream0(HttpURLConnection.java:1316)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1291)
at org.apache.xmlrpc.client.XmlRpcSunHttpTransport.writeRequest(XmlRpcSunHttpTransport.java:104)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:151)
... 22 more
java.net.ConnectException: Connection refused (Connection refused)
However the 3.2 server is running with default settings
anything I am missing?
Andreas
17 Jun 2017 16:59:14,237 [main] INFO (JettyStart.java [lifeCycleStarting]:616) - Jetty server starting...
17 Jun 2017 16:59:14,738 [main] INFO (JettyStart.java [lifeCycleStarted]:625) - Jetty server started.
17 Jun 2017 16:59:14,739 [main] WARN (JettyStart.java [run]:234) - Could not find OpenID extension. OpenID will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:241) - Could not find OAuthServlet extension. OAuth will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:248) - Could not find IPRangeServlet extension. IPRange will be disabled!
17 Jun 2017 16:59:14,743 [main] INFO (JettyStart.java [run]:257) - -----------------------------------------------------
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) - http://XXX:8088/
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) - https://XXX:8451/
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:269) - /
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:323) - -----------------------------------------------------
a***@uni-koeln.de
2017-06-18 09:32:22 UTC
Permalink
I usually clear the db with build.sh clean-default-data-dir after
shutdown (full backup and restore cycle!)

I am not an existdb guru, but I guess that an instance was running
during your restore attempt?!
the db must be shut down before restore

Peter

by the way, shouldnt it read -ouri=xmldb:exist://localhost:8088
Post by Andreas Jung
So I started the restore process with
-ouri=xmldb:exist:///localhost:8088
However this leads to this error (I removed the dbx, log and lck
files before starting the existdb instance as recommended.
———
Using locale: en_US.UTF-8
Starting restore of backup...
Processing backup: /tmp/full20170617-1651/db/system/security/__contents__.xml
Creating collection /db/system/security
An unrecoverable error occurred while restoring
collection '/db/system/security'. Aborting restore!
Finished restore of backup.
org.exist.EXistException: The directory seems to be locked by
/home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/dbx_dir.lck
------------------------------------
WARN: An unrecoverable error occurred while restoring
collection '/db/system/security'. Aborting restore!
org.exist.EXistException: The directory seems to be locked by
/home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/dbx_dir.lck
If you restored collections inside /db/apps, you may want
to rebuild the application repository. To do so, run the following query
import module namespace repair="http://exist-db.org/xquery/repo/repair"
at "resource:org/exist/xquery/modules/expathrepo/repair.xql";
repair:clean-all(),
repair:repair()
org.exist.EXistException: The journal log directory seems to be
/home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/journal.lck is
present in the log directory. Last access to the lock file: Jun 18,
2017 9:04:39 AM
at org.exist.xmldb.DatabaseImpl.configure(DatabaseImpl.java:116)
at org.exist.xmldb.DatabaseImpl.getLocalCollection(DatabaseImpl.java:179)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:165)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
org.exist.EXistException: The journal log directory seems to be
/home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/journal.lck is
present in the log directory. Last access to the lock file: Jun 18,
2017 9:04:39 AM
Post by a***@uni-koeln.de
since the recent changes of commandline parameter handling you have
to use the -ouri=xmldb:exist:///
to connect to a vanilla eXistdb server on localhost:8080 (no
default anymore, the docs still say so).
So I presume your backup will work with -ouri (and the correct port).
regards
Peter
Post by Andreas Jung
Hi there,
I am trying to migrate a project from exist 2.2 to 3.2.
I created a full backup of 2.2 and now I am trying a restore using
bin/backup.sh -u admin -p XXXX -r
/tmp/full20170617-1651/db/__contents__.xml
This fails with
org.apache.xmlrpc.XmlRpcException: Failed to read server's
response: Connection refused (Connection refused)
at
org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:161)
at
org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(XmlRpcHttpTransport.java:143)
at
org.apache.xmlrpc.client.XmlRpcSunHttpTransport.sendRequest(XmlRpcSunHttpTransport.java:69)
at
org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:56)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:167)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:158)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:147)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:81)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:72)
at org.exist.xmldb.DatabaseImpl.readCollection(DatabaseImpl.java:265)
at org.exist.xmldb.DatabaseImpl.getRemoteCollection(DatabaseImpl.java:227)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:167)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
Caused by: java.net.ConnectException: Connection refused
(Connection refused)
at java.net.PlainSocketImpl.socketConnect(Native Method)
at
java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at
java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at
java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
at sun.net.www.http.HttpClient.New(HttpClient.java:339)
at sun.net.www.http.HttpClient.New(HttpClient.java:357)
at
sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1202)
at
sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1138)
at
sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1032)
at
sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:966)
at
sun.net.www.protocol.http.HttpURLConnection.getOutputStream0(HttpURLConnection.java:1316)
at
sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1291)
at
org.apache.xmlrpc.client.XmlRpcSunHttpTransport.writeRequest(XmlRpcSunHttpTransport.java:104)
at
org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:151)
... 22 more
java.net.ConnectException: Connection refused (Connection refused)
However the 3.2 server is running with default settings…anything I
am missing?
Andreas
17 Jun 2017 16:59:14,237 [main] INFO (JettyStart.java
[lifeCycleStarting]:616) - Jetty server starting...
17 Jun 2017 16:59:14,738 [main] INFO (JettyStart.java
[lifeCycleStarted]:625) - Jetty server started.
17 Jun 2017 16:59:14,739 [main] WARN (JettyStart.java [run]:234)
- Could not find OpenID extension. OpenID will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:241)
- Could not find OAuthServlet extension. OAuth will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:248)
- Could not find IPRangeServlet extension. IPRange will be disabled!
17 Jun 2017 16:59:14,743 [main] INFO (JettyStart.java [run]:257)
- -----------------------------------------------------
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:258)
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) - http://XXX:8088/
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) - https://XXX:8451/
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:263)
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:269) - /
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:323)
- -----------------------------------------------------
Andreas Jung
2017-06-18 13:01:41 UTC
Permalink
hmm
ok


build.sh clean-default-data-dir

bin/backup.sh -u admin -r /tmp/full20170617-1651/db/__contents__.xml -ouri=xmldb:exist:///localhost:8088


-u admin -r /tmp/full20170617-1651/db/__contents__.xml -ouri=xmldb:exist:///localhost:8088
Using locale: en_US.UTF-8
Starting restore of backup...
Processing backup: /tmp/full20170617-1651/db/system/security/__contents__.xml
Creating collection /db/system/security
^[^[An unrecoverable error occurred while restoring
collection '/db/system/security'. Aborting restore!
Finished restore of backup.
Invalid URI: xmldb URI scheme does not start with xmldb:: localhost:8088
------------------------------------
Problems occured found during restore:
WARN: An unrecoverable error occurred while restoring
collection '/db/system/security'. Aborting restore!
ERROR: Invalid URI: xmldb URI scheme does not start with xmldb:: localhost:8088

@exist-team:

- the system tools should use the default port of existdb out of the box without further configuration
- the upgrade section or the backup/restore section of the documentation obviously needs a bit more love

Andreas

--
Andreas Jung
Hundskapfklinge 33
D-72074 TÃŒbingen
Tel. +49 7071 793257
I usually clear the db with build.sh clean-default-data-dir after shutdown (full backup and restore cycle!)
I am not an existdb guru, but I guess that an instance was running during your restore attempt?!
the db must be shut down before restore
Peter
by the way, shouldnt it read -ouri=xmldb:exist://localhost:8088
Post by Andreas Jung
So I started the restore process with
-ouri=xmldb:exist:///localhost:8088
However this leads to this error (I removed the dbx, log and lck files before starting the existdb instance as recommended.
———
Using locale: en_US.UTF-8
Starting restore of backup...
Processing backup: /tmp/full20170617-1651/db/system/security/__contents__.xml
Creating collection /db/system/security
An unrecoverable error occurred while restoring
collection '/db/system/security'. Aborting restore!
Finished restore of backup.
configuration error: org.exist.storage.BrokerPoolServiceException: org.exist.EXistException: The directory seems to be locked by another database instance. Found a valid lock file: /home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/dbx_dir.lck
------------------------------------
WARN: An unrecoverable error occurred while restoring
collection '/db/system/security'. Aborting restore!
ERROR: configuration error: org.exist.storage.BrokerPoolServiceException: org.exist.EXistException: The directory seems to be locked by another database instance. Found a valid lock file: /home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/dbx_dir.lck
If you restored collections inside /db/apps, you may want
to rebuild the application repository. To do so, run the following query
import module namespace repair="http://exist-db.org/xquery/repo/repair"
at "resource:org/exist/xquery/modules/expathrepo/repair.xql";
repair:clean-all(),
repair:repair()
org.xmldb.api.base.XMLDBException: configuration error: org.exist.storage.BrokerPoolServiceException: org.exist.EXistException: The journal log directory seems to be locked by another eXist process. A lock file: /home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/journal.lck is present in the log directory. Last access to the lock file: Jun 18, 2017 9:04:39 AM
at org.exist.xmldb.DatabaseImpl.configure(DatabaseImpl.java:116)
at org.exist.xmldb.DatabaseImpl.getLocalCollection(DatabaseImpl.java:179)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:165)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
Caused by: org.exist.EXistException: org.exist.storage.BrokerPoolServiceException: org.exist.EXistException: The journal log directory seems to be locked by another eXist process. A lock file: /home/ajung/sandboxes/existdb-32/webapp/WEB-INF/data/journal.lck is present in the log directory. Last access to the lock file: Jun 18, 2017 9:04:39 AM
since the recent changes of commandline parameter handling you have to use the -ouri=xmldb:exist:///
to connect to a vanilla eXistdb server on localhost:8080 (no default anymore, the docs still say so).
So I presume your backup will work with -ouri (and the correct port).
regards
Peter
Post by Andreas Jung
Hi there,
I am trying to migrate a project from exist 2.2 to 3.2.
I created a full backup of 2.2 and now I am trying a restore using
bin/backup.sh -u admin -p XXXX -r /tmp/full20170617-1651/db/__contents__.xml
This fails with
org.apache.xmlrpc.XmlRpcException: Failed to read server's response: Connection refused (Connection refused)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:161)
at org.apache.xmlrpc.client.XmlRpcHttpTransport.sendRequest(XmlRpcHttpTransport.java:143)
at org.apache.xmlrpc.client.XmlRpcSunHttpTransport.sendRequest(XmlRpcSunHttpTransport.java:69)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorker.java:56)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:167)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:158)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:147)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:81)
at org.exist.xmldb.RemoteCollection.instance(RemoteCollection.java:72)
at org.exist.xmldb.DatabaseImpl.readCollection(DatabaseImpl.java:265)
at org.exist.xmldb.DatabaseImpl.getRemoteCollection(DatabaseImpl.java:227)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:167)
at org.exist.xmldb.DatabaseImpl.getCollection(DatabaseImpl.java:156)
at org.xmldb.api.DatabaseManager.getCollection(Unknown Source)
at org.exist.backup.Main.process(Main.java:267)
at org.exist.backup.Main.main(Main.java:418)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.exist.start.Main.invokeMain(Main.java:140)
at org.exist.start.Main.run(Main.java:453)
at org.exist.start.Main.main(Main.java:64)
Caused by: java.net.ConnectException: Connection refused (Connection refused)
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at sun.net.NetworkClient.doConnect(NetworkClient.java:180)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.http.HttpClient.<init>(HttpClient.java:242)
at sun.net.www.http.HttpClient.New(HttpClient.java:339)
at sun.net.www.http.HttpClient.New(HttpClient.java:357)
at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:1202)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1138)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1032)
at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:966)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream0(HttpURLConnection.java:1316)
at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:1291)
at org.apache.xmlrpc.client.XmlRpcSunHttpTransport.writeRequest(XmlRpcSunHttpTransport.java:104)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStreamTransport.java:151)
... 22 more
java.net.ConnectException: Connection refused (Connection refused)
However the 3.2 server is running with default settings
anything I am missing?
Andreas
17 Jun 2017 16:59:14,237 [main] INFO (JettyStart.java [lifeCycleStarting]:616) - Jetty server starting...
17 Jun 2017 16:59:14,738 [main] INFO (JettyStart.java [lifeCycleStarted]:625) - Jetty server started.
17 Jun 2017 16:59:14,739 [main] WARN (JettyStart.java [run]:234) - Could not find OpenID extension. OpenID will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:241) - Could not find OAuthServlet extension. OAuth will be disabled!
17 Jun 2017 16:59:14,740 [main] WARN (JettyStart.java [run]:248) - Could not find IPRangeServlet extension. IPRange will be disabled!
17 Jun 2017 16:59:14,743 [main] INFO (JettyStart.java [run]:257) - -----------------------------------------------------
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) - http://XXX:8088/
17 Jun 2017 16:59:14,744 [main] INFO (JettyStart.java [run]:260) - https://XXX:8451/
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:269) - /
17 Jun 2017 16:59:14,745 [main] INFO (JettyStart.java [run]:323) - -----------------------------------------------------
Wolfgang Meier
2017-06-18 19:26:53 UTC
Permalink
try -ouri=xmldb:exist://localhost:8088/exist/xmlrpc <exist://localhost:8088/exist/xmlrpc>

The default is xmldb:exist://localhost:8080/exist/xmlrpc <exist://localhost:8080/exist/xmlrpc>

Wolfgang

Continue reading on narkive:
Loading...