TransWikia.com

How do I get Cache Inspector to work when running Apache Traffic Server as a Forward Proxy Cache

Server Fault Asked by Mike Metully on January 3, 2021

When trying to use Cache Inspector on Apache Traffic Server (8.0.8) while configured for forward proxy caching it seems like it’s triggering a recursion when mapping is turned off (required for forward proxy).

-sh-4.2$ curl -v "localhost/myCI"
* About to connect() to localhost port 80 (#0)
*   Trying ::1...
* Connection refused
*   Trying 127.0.0.1...
* Connected to localhost (127.0.0.1) port 80 (#0)
> GET /myCI HTTP/1.1
> User-Agent: curl/7.29.0
> Host: localhost
> Accept: */*
>
< HTTP/1.1 400 Multi-Hop Cycle Detected
< Date: Tue, 28 Jul 2020 18:55:01 GMT
< Server: ATS/8.0.8
< Cache-Control: no-store
< Content-Type: text/html
< Content-Language: en
< Content-Length: 346
< Age: 2
< Connection: keep-alive
<
<HTML>
<HEAD>
<TITLE>Cycle Prohibited</TITLE>
</HEAD>

<BODY BGCOLOR="white" FGCOLOR="black">
<H1>Cycle Prohibited</H1>
<HR>

<FONT FACE="Helvetica,Arial"><B>
Description: Could not process your request for the document
because it would cause an HTTP proxy cycle.  Please check the URL and your
browser's proxy settings.
</B></FONT>
<HR>
</BODY>

my configs:

-sh-4.2$ traffic_ctl config diff
proxy.config.url_remap.remap_required has changed
        Current Value   : 0
        Default Value   : 1
proxy.config.reverse_proxy.enabled has changed
        Current Value   : 0
        Default Value   : 1
proxy.config.http.server_ports has changed
        Current Value   : 80
        Default Value   : 8080 8080:ipv6
proxy.config.http.cache.ignore_server_no_cache has changed
        Current Value   : 1
        Default Value   : 0
proxy.config.http.cache.heuristic_min_lifetime has changed
        Current Value   : 604800
        Default Value   : 3600
proxy.config.http.cache.heuristic_max_lifetime has changed
        Current Value   : 2592000
        Default Value   : 86400
proxy.config.net.connections_throttle has changed
        Current Value   : 3000
        Default Value   : 30000
proxy.config.http_ui_enabled has changed
        Current Value   : 1
        Default Value   : 0
proxy.config.http.cache.required_headers has changed
        Current Value   : 0
        Default Value   : 2
proxy.config.admin.user_id has changed
        Current Value   : <snipped>
        Default Value   : nobody
proxy.config.http.cache.enable_default_vary_headers has changed
        Current Value   : 1
        Default Value   : 0

note: this was occurring before I changed the port from 8080 to 80, I am pretty sure it is supposed to provide myCI on whatever is configured as the port.

note2: traffic_ctl config diff gives all non default config values.

Note3: Remote browser behavior matches localhost curl behavior.

One Answer

The issue was that I needed a closing slash on my URL eg /myCI/ instead of /myCI

Answered by Mike Metully on January 3, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP