Forum Discussion
X-Remote-Addr is showing as 0.0.0.0
Dear Dev Team,
Users are trying to access the URL "www.test.com/connect"
We are seeing X-Remote-Addr as 0.0.0.0 in HTTP header for some requests and we are seeing the "actual client ip address" for some requests on the same VIP
Nodes will determine the action to be performed based on -X-Remote-Addr.
Whenever the request consists of X-Remote-Addr as "0.0.0.0" the requests are failing.
BTW, we have LTM with WA module.
Could you pls someone give any suggession on how to overcome this behaviour?
6 Replies
- What_Lies_Bene1
Cirrostratus
What is inserting this header, the F5 or something else? If the F5 how are you doing this. If not then I'll assume it's some upstream device that's the cause of the issue. - muzammil_88686
Nimbostratus
X-Remote-Addr is getting inserted by Web Accelerator.
GET /connect HTTP/1.1
Connection: keep-alive
Host: www.test.com
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
User-Agent: Mozilla/5.0 (X11; CrOS x86_64 3912.43.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.69 Safari/537.36
X-Chrome-UMA-Enabled: 1
X-Chrome-Variations: CM61yQEIj7bJAQictskBCKa2yQEIqLbJAQiptskBCLq2yQEI/IPKAQishcoB
Accept-Language: en-US,en;q=0.8
Cookie: test_cookie=2063336970.20480.0000
Surrogate-Capabilities: WA="ESI/1.0", WA="ESI-Inline/1.0"
Accept-Encoding: identity
X-Remote-Addr: 0.0.0.0
X-Client: WA
X-PvMAC: 00:01:D7:A2:6B:01 - What_Lies_Bene1
Cirrostratus
Have any actual users complained? Could this just be monitoring traffic? - afedden_1985
Cirrus
how are you doing this via the web accelerator? "X-Remote-Addr is getting inserted by Web Accelerator."
This is normally done in the HTTP profile in version 10 and 11, by selecting > Insert X-Forwarded-For enabled - Drew_Kane_23142Historic F5 AccountThe pvac process (pvac is the WebAccelerator data plane daemon in 9.x and 10.x) will insert the X-Remote-Addr for traffic it processes. If pvac processing is bypassed- for example, when the system is under a lot of load and the request queue is full- then the chunk pvac code that writes the client IP address into the X-Remote-Addr header can be bypassed as well. Hence, you see 0.0.0.0 rather than the real client IP address.
You can use an iRule to change the X-Remote-Addr header's value to what it should be. Something like this:
when HTTP_REQUEST_SEND {
clientside {
if { [HTTP::header exists "X-Remote-Addr"] and [HTTP::header "X-Remote-Addr"] equals "0.0.0.0" } {
HTTP::header replace "X-Remote-Addr" [IP::client_addr]
}
}
}
Addressing the cause of the WebAccelerator bypass or enabling/using the X-Forwarded-For header are other options to do instead of/in addition to the iRule workaround above. - muzammil_88686
Nimbostratus
Thank you Kane for your reply!
We have lot of other iRules on LTM for the same VIP for different URI/Paths.
Can we get this iRule to be modified for specific URI/Path( for example /connect) only? Could you pls suggest one Irule for specific URL(www.test.com/connect)?
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com