Hello
We've been running Archiva on our servers for a number of years, and this
server hasn't required a proxy to access the internet. Recently this server has
been migrated to another host, and that host requires a proxy to access the
internet. Since the migration, I've added a "Network Proxy" to Archiva:
Name: proxy
Protocol: http
Host: X.Y.160.19
Port: 8080
with no username/password, and ntlm not enabled.
I've then modified our "Remote Repository", to set the proxy to "proxy". I then
tried to download the remote index, but I get the following error in the
archiva.log file:
2023-07-26 13:23:03,781 [taskScheduler#indexDownloadRemote-1] INFO
org.apache.archiva.scheduler.indexing.DownloadRemoteIndexTask$DownloadListener
[] - error of transfer file nexus-maven-repository-index.properties: Connect to
repo.maven.apache.org:443 [repo.maven.apache.org/151.101.64.215,
repo.maven.apache.org/151.101.128.215, repo.maven.apache.org/151.101.192.215,
repo.maven.apache.org/151.101.0.215,
repo.maven.apache.org/2a04:4e42:400:0:0:0:0:215,
repo.maven.apache.org/2a04:4e42:0:0:0:0:0:215,
repo.maven.apache.org/2a04:4e42:200:0:0:0:0:215,
repo.maven.apache.org/2a04:4e42:600:0:0:0:0:215] failed: Network is unreachable
(connect failed)
org.apache.http.conn.HttpHostConnectException: Connect to
repo.maven.apache.org:443 [repo.maven.apache.org/151.101.64.215,
repo.maven.apache.org/151.101.128.215, repo.maven.apache.org/151.101.192.215,
repo.maven.apache.org/151.101.0.215,
repo.maven.apache.org/2a04:4e42:400:0:0:0:0:215,
repo.maven.apache.org/2a04:4e42:0:0:0:0:0:215,
repo.maven.apache.org/2a04:4e42:200:0:0:0:0:215,
repo.maven.apache.org/2a04:4e42:600:0:0:0:0:215] failed: Network is unreachable
(connect failed)
at
org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:156)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.http.impl.conn.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:376)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.http.impl.execchain.MainClientExec.establishRoute(MainClientExec.java:393)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:236)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:186)
~[httpclient-4.5.13.jar:4.5.13]
at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:89)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:185)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:83)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.execute(AbstractHttpClientWagon.java:832)
~[wagon-http-2.9.jar:2.9]
at
org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.fillInputData(AbstractHttpClientWagon.java:983)
[wagon-http-2.9.jar:2.9]
at
org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.fillInputData(AbstractHttpClientWagon.java:960)
[wagon-http-2.9.jar:2.9]
at
org.apache.maven.wagon.StreamWagon.getInputStream(StreamWagon.java:116)
[wagon-provider-api-2.9.jar:2.9]
at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:88)
[wagon-provider-api-2.9.jar:2.9]
at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61)
[wagon-provider-api-2.9.jar:2.9]
at
org.apache.archiva.scheduler.indexing.DownloadRemoteIndexTask$WagonResourceFetcher.retrieve(DownloadRemoteIndexTask.java:352)
[archiva-scheduler-indexing-2.2.10.jar:?]
at
org.apache.maven.index.updater.DefaultIndexUpdater.downloadIndexProperties(DefaultIndexUpdater.java:459)
[indexer-core-5.1.1.jar:5.1.1]
at
org.apache.maven.index.updater.DefaultIndexUpdater.access$000(DefaultIndexUpdater.java:76)
[indexer-core-5.1.1.jar:5.1.1]
at
org.apache.maven.index.updater.DefaultIndexUpdater$IndexAdaptor.setProperties(DefaultIndexUpdater.java:589)
[indexer-core-5.1.1.jar:5.1.1]
at
org.apache.maven.index.updater.DefaultIndexUpdater.fetchAndUpdateIndex(DefaultIndexUpdater.java:857)
[indexer-core-5.1.1.jar:5.1.1]
at
org.apache.maven.index.updater.DefaultIndexUpdater.fetchAndUpdateIndex(DefaultIndexUpdater.java:136)
[indexer-core-5.1.1.jar:5.1.1]
at
org.apache.archiva.scheduler.indexing.DownloadRemoteIndexTask.run(DownloadRemoteIndexTask.java:187)
[archiva-scheduler-indexing-2.2.10.jar:?]
at
org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
[spring-context-4.2.9.RELEASE.jar:4.2.9.RELEASE]
at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[?:1.8.0_332]
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[?:1.8.0_332]
at
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
[?:1.8.0_332]
at
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
[?:1.8.0_332]
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[?:1.8.0_332]
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[?:1.8.0_332]
at java.lang.Thread.run(Thread.java:750) [?:1.8.0_332]
Caused by: java.net.ConnectException: Network is unreachable (connect failed)
at java.net.PlainSocketImpl.socketConnect(Native Method) ~[?:1.8.0_332]
at
java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
~[?:1.8.0_332]
at
java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
~[?:1.8.0_332]
at
java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
~[?:1.8.0_332]
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
~[?:1.8.0_332]
at java.net.Socket.connect(Socket.java:607) ~[?:1.8.0_332]
at
org.apache.http.conn.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:368)
~[httpclient-4.5.13.jar:4.5.13]
at
org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:142)
~[httpclient-4.5.13.jar:4.5.13]
... 29 more
The server itself can reach maven central:
[root@lg-bld-java01 logs]# curl -Lvvv https://repo.maven.apache.org/maven2
* Uses proxy env variable no_proxy ==
'127.0.0.1,localhost,development.local,nps-update,nps-ubuntu,X.Y.82.79,nis-tc3-yum01,X.Y.84.254,X.Y.82.201,tc3-v-ivanti01.global.internal,UK1-V-DSM01.global.internal,172.29.100.110,vm-nds-bld01.global.internal,vm-nds-bld02.global.internal,vm-nds-bld03.global.internal,vm-beis-bld01.global.internal,vm-bld-ruby01.global.internal,vm-ndips-bld01.global.internal,vm-nds-dev02.global.internal,vm-beis-dev02.global.internal,vm-rstp-dev01.global.internal,vm-ndips-tst02.global.internal,vm-nds-tst02.global.internal,vm-beis-tst02.global.internal,vm-rstp-tst01.global.internal,vm-ndips-tst01.global.internal,vm-devops-dev01.global.internal,vm-bld-cont01.development.local,X.Y.65.246'
* Uses proxy env variable https_proxy == 'http://X.Y.160.19:8080/'
* Trying X.Y.160.19...
* TCP_NODELAY set
* Connected to X.Y.160.19 (X.Y.160.19) port 8080 (#0)
* allocate connect buffer!
* Establish HTTP proxy tunnel to repo.maven.apache.org:443
> CONNECT repo.maven.apache.org:443 HTTP/1.1
> Host: repo.maven.apache.org:443
> User-Agent: curl/7.61.1
> Proxy-Connection: Keep-Alive
>
< HTTP/1.1 200 Connection established
<
* Proxy replied 200 to CONNECT request
* CONNECT phase completed!
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
* CAfile: /etc/pki/tls/certs/ca-bundle.crt
CApath: none
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* CONNECT phase completed!
* CONNECT phase completed!
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Change cipher spec (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-RSA-AES128-GCM-SHA256
* ALPN, server accepted to use h2
* Server certificate:
* subject: CN=repo.maven.apache.org
* start date: Mar 15 17:45:12 2023 GMT
* expire date: Apr 15 17:45:11 2024 GMT
* subjectAltName: host "repo.maven.apache.org" matched cert's
"repo.maven.apache.org"
* issuer: C=BE; O=GlobalSign nv-sa; CN=GlobalSign Atlas R3 DV TLS CA 2023 Q1
* SSL certificate verify ok.
* Using HTTP2, server supports multi-use
* Connection state changed (HTTP/2 confirmed)
* Copying HTTP/2 data in stream buffer to connection buffer after upgrade: len=0
* Using Stream ID: 1 (easy handle 0x55ec766686d0)
> GET /maven2 HTTP/2
> Host: repo.maven.apache.org
> User-Agent: curl/7.61.1
> Accept: */*
>
* Connection state changed (MAX_CONCURRENT_STREAMS == 100)!
< HTTP/2 302
< x-amz-error-code: Found
< x-amz-error-message: Resource Found
< location: /maven2/
< content-type: text/html; charset=utf-8
< via: 1.1 varnish, 1.1 varnish
< accept-ranges: bytes
< date: Wed, 26 Jul 2023 12:36:57 GMT
< age: 646475
< x-served-by: cache-iad-kiad7000111-IAD, cache-lon420084-LON
< x-cache: HIT, HIT
< x-cache-hits: 190, 2
< x-timer: S1690375017.418599,VS0,VE0
< vary: Fastly-SSL,
< content-length: 313
<
* Ignoring the response-body
* Connection #0 to host X.Y.160.19 left intact
* Issue another request to this URL: 'https://repo.maven.apache.org/maven2/'
* Uses proxy env variable no_proxy ==
'127.0.0.1,localhost,development.local,nps-update,nps-ubuntu,X.Y.82.79,nis-tc3-yum01,X.Y.84.254,X.Y.82.201,tc3-v-ivanti01.global.internal,UK1-V-DSM01.global.internal,172.29.100.110,vm-nds-bld01.global.internal,vm-nds-bld02.global.internal,vm-nds-bld03.global.internal,vm-beis-bld01.global.internal,vm-bld-ruby01.global.internal,vm-ndips-bld01.global.internal,vm-nds-dev02.global.internal,vm-beis-dev02.global.internal,vm-rstp-dev01.global.internal,vm-ndips-tst02.global.internal,vm-nds-tst02.global.internal,vm-beis-tst02.global.internal,vm-rstp-tst01.global.internal,vm-ndips-tst01.global.internal,vm-devops-dev01.global.internal,vm-bld-cont01.development.local,X.Y.65.246'
* Uses proxy env variable https_proxy == 'http://X.Y.160.19:8080/'
* Found bundle for host repo.maven.apache.org: 0x55ec7666b920 [can multiplex]
* Re-using existing connection! (#0) with proxy X.Y.160.19
* Connected to X.Y.160.19 (X.Y.160.19) port 8080 (#0)
* Using Stream ID: 3 (easy handle 0x55ec766686d0)
> GET /maven2/ HTTP/2
> Host: repo.maven.apache.org
> User-Agent: curl/7.61.1
> Accept: */*
>
< HTTP/2 200
< last-modified: Fri, 21 Jul 2023 05:41:46 GMT
< etag: "bc826df4f76537981671432d519724bd"
< content-type: text/html
< via: 1.1 varnish, 1.1 varnish
< accept-ranges: bytes
< date: Wed, 26 Jul 2023 12:36:57 GMT
< age: 96954
< x-served-by: cache-iad-kjyo7100044-IAD, cache-lon420084-LON
< x-cache: HIT, HIT
< x-cache-hits: 380, 12
< x-timer: S1690375017.424695,VS0,VE0
< content-length: 125411
<
<!DOCTYPE html>
<html>
<head>
<title>Central Repository: </title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style>
body {
background: #fff;
}
</style>
</head>
<body>
<header>
<h1></h1>
</header>
<hr/>
<main>
<pre id="contents">
<a href="../">../</a>
<a href="HTTPClient/" title="HTTPClient/">HTTPClient/</a>
- -
<a href="abbot/" title="abbot/">abbot/</a>
- -
<a href="academy/" title="academy/">academy/</a>
- -
<a href="acegisecurity/" title="acegisecurity/">acegisecurity/</a>
- -
<a href="activation/" title="activation/">activation/</a>
- -
<a href="activecluster/" title="activecluster/">activecluster/</a>
- -
<a href="activeio/" title="activeio/">activeio/</a>
- -
<a href="activemq/" title="activemq/">activemq/</a>
- -
<a href="activemq-jaxb/" title="activemq-jaxb/">activemq-jaxb/</a>
- -
<a href="activesoap/" title="activesoap/">activesoap/</a>
- -
<a href="activespace/" title="activespace/">activespace/</a>
- -
<a href="adarwin/" title="adarwin/">adarwin/</a>
- -
<a href="ae/" title="ae/">ae/</a>
- -
<a href="aelfred/" title="aelfred/">aelfred/</a>
- -
<a href="aero/" title="aero/">aero/</a>
- -
<a href="africa/" title="africa/">africa/</a>
- -
<a href="ag/" title="ag/">ag/</a>
- -
<a href="ai/" title="ai/">ai/</a>
- -
<a href="aislib/" title="aislib/">aislib/</a>
- -
<a href="al/" title="al/">al/</a>
- -
<a href="altrmi/" title="altrmi/">altrmi/</a>
- -
<a href="am/" title="am/">am/</a>
- -
<a href="andromda/" title="andromda/">andromda/</a>
- -
<a href="annogen/" title="annogen/">annogen/</a>
- -
<a href="ant/" title="ant/">ant/</a>
- -
<a href="ant-contrib/" title="ant-contrib/">ant-contrib/</a>
- -
<a href="ant-doxygen/" title="ant-doxygen/">ant-doxygen/</a>
- -
<a href="ant4eclipse/" title="ant4eclipse/">ant4eclipse/</a>
- -
<a href="antlr/" title="antlr/">antlr/</a>
- -
<a href="anttex/" title="anttex/">anttex/</a>
- -
<a href="aopalliance/" title="aopalliance/">aopalliance/</a>
- -
<a href="apache-jaxme/" title="apache-jaxme/">apache-jaxme/</a>
- -
<a href="app/" title="app/">app/</a>
- -
<a href="aptconvert/" title="aptconvert/">aptconvert/</a>
- -
<a href="ar/" title="ar/">ar/</a>
- -
<a href="args4j/" title="args4j/">args4j/</a>
- -
<a href="art/" title="art/">art/</a>
- -
<a href="as/" title="as/">as/</a>
- -
<a href="ashkay/" title="ashkay/">ashkay/</a>
- -
<a href="ashkelon/" title="ashkelon/">ashkelon/</a>
- -
<a href="asia/" title="asia/">asia/</a>
- -
<a href="asm/" title="asm/">asm/</a>
- -
<a href="aspectj/" title="aspectj/">aspectj/</a>
- -
<a href="aspectwerkz/" title="aspectwerkz/">aspectwerkz/</a>
- -
<a href="at/" title="at/">at/</a>
- -
[snipped]
Can anyone help?
Thanks in advance.
Richard Tearle
Senior DevOps Engineer
Cyber, Service & Technology (CST)
E: [email protected]
W: www.necsws.com<http://www.necsws.com>
NEC Software Solutions
Please consider the environment before printing this email
This email is sent on behalf of NEC Software Solutions UK Limited and its
associated companies (together "NEC Software Solutions") and is strictly
confidential and intended solely for the addressee(s). Full details of those
companies can be found at https://www.necsws.com/group-company-details/ If you
are not the intended recipient of this email you must: (i) not disclose, copy
or distribute its contents to any other person nor use its contents in any way
or you may be acting unlawfully; (ii) contact NEC Software Solutions
immediately on +44(0)1442 768445 quoting the name of the sender and the
addressee then delete it from your system. NEC Software Solutions has taken
reasonable precautions to ensure that no viruses are contained in this email,
but does not accept any responsibility once this email has been transmitted.
You should scan attachments (if any) for viruses.