osmosis
osmosis copied to clipboard
https_proxy under ubuntu 20.04
Not sure if this is an osmosis bug or not, i am having trouble setting the https_proxy for java/osmosis in ubuntu 20.04.
I successfully used JAVACMD_OPTIONS="-Dhttps.proxyHost=xxx -Dhttps.proxyPort=xxx -Dhttps.proxyUser=xxx -Dhttps.proxyPassword=xxx"
.
java -Dhttps.proxyHost=xxx -Dhttps.proxyPort=xxx -Dhttps.proxyUser=xxx -Dhttps.proxyPassword=xxx -cp /srv/osm-replicate/osmosis/lib/default/plexus-classworlds-2.5.2.jar -Dapp.home=/srv/osm-replicate/osmosis -Dclassworlds.conf=/srv/osm-replicate/osmosis/config/plexus.conf org.codehaus.classworlds.Launcher --rri workingDirectory=/srv/osm-replicate/osmosis-working-dir/ --simc --wxc /srv/osm-replicate/var/replicate-1604582744.osc.gz
Nov 05, 2020 1:26:37 PM org.openstreetmap.osmosis.core.Osmosis run
INFO: Osmosis Version 0.48.3
Nov 05, 2020 1:26:37 PM org.openstreetmap.osmosis.core.Osmosis run
INFO: Preparing pipeline.
Nov 05, 2020 1:26:37 PM org.openstreetmap.osmosis.core.Osmosis run
INFO: Launching pipeline execution.
Nov 05, 2020 1:26:37 PM org.openstreetmap.osmosis.core.Osmosis run
INFO: Pipeline executing, waiting for completion.
Nov 05, 2020 1:26:37 PM org.openstreetmap.osmosis.core.pipeline.common.ActiveTaskManager waitForCompletion
SEVERE: Thread for task 1-rri failed
org.openstreetmap.osmosis.core.OsmosisRuntimeException: Unable to read the state from the server.
at org.openstreetmap.osmosis.replication.common.ServerStateReader.getServerState(ServerStateReader.java:95)
at org.openstreetmap.osmosis.replication.common.ServerStateReader.getServerState(ServerStateReader.java:46)
at org.openstreetmap.osmosis.replication.v0_6.BaseReplicationDownloader.runImpl(BaseReplicationDownloader.java:273)
at org.openstreetmap.osmosis.replication.v0_6.BaseReplicationDownloader.run(BaseReplicationDownloader.java:372)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.io.IOException: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 407 Proxy Authentication Required"
at java.base/sun.net.www.protocol.http.HttpURLConnection.doTunneling(HttpURLConnection.java:2177)
at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:183)
at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1592)
at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1520)
at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:250)
at org.openstreetmap.osmosis.replication.common.ServerStateReader.getServerState(ServerStateReader.java:91)
... 4 more
Nov 05, 2020 1:26:37 PM org.openstreetmap.osmosis.core.Osmosis main
SEVERE: Execution aborted.
org.openstreetmap.osmosis.core.OsmosisRuntimeException: One or more tasks failed.
at org.openstreetmap.osmosis.core.pipeline.common.Pipeline.waitForCompletion(Pipeline.java:146)
at org.openstreetmap.osmosis.core.Osmosis.run(Osmosis.java:92)
at org.openstreetmap.osmosis.core.Osmosis.main(Osmosis.java:37)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchStandard(Launcher.java:330)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:238)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
at org.codehaus.classworlds.Launcher.main(Launcher.java:47)
I also tried changing jdk.http.auth.tunneling.disabledSchemes=""
in /etc/java-11-openjdk/net.properties
without any change.