>Do you mean you are getting 127.0.0.1 as remote address in logs or in > REMOTE_ADDR CGI variable? If it is the first, did you check "Accept > Forwarded IPs" option in "YourVirtualServer->Logging" section?. If > it's the second, then it's the expected behaviour as well, AFAIK.
Yes am getting 127.0.0.1 as remote address on application backend. There is something odd going on. X_Forwarded_For continued to be wrong and considering the steps we go through to get to the back end I suspect IIS might be the culprit. We are moving away from IIS, so disinterested in solving it if the culprit :) Workflow: INTERNET ---> Varnish ---> Cherokee (reverse proxy) ---> IIS ---> Coldfusion Found Varnish to cache things were don't want cached like .cfm files (Coldfusion dynamic application pages, personalized logged in pages, etc.). Mainly was interested in caching static only elements like .GIF, .JPG, .PNG, .CSS, etc. Varnish documentation and config for advanced stuff is really lacking... so... So we axed the flawed workflow above and created these new workflows which are working mostly right (still some issues with rewrites that we need to resolve - like when image like this: www.pubcrawler.com/art/logo.gif ---> point to ---> images.pubcrawler.com/art/logo.gif): .cfm files: (www.pubcrawler.com) INTERNET ---> Cherokee (reverse proxy) ---> IIS ---> Coldfusion .gif, .jpg, .png, .css, etc. (images.pubcrawler.com) INTERNET ---> Cherokee ---> Varnish --> Cherokee Seeing over 90% cache hit rate with Varnish currently and the resource consumption by Varnish is barely noticeable. Comes with some nice tools Of course this might sound like additional wasted resources since Cherokee provides IOCache of static elements it serves, however this use slightly different. Varnish gives us a central shared cache that can be used from anywhere as a resource and gives extensive control over cache life (including manually overriding cache time). Most interesting, Varnish allows for survival serving of documents even when servers are offline/crashed. Once I get this all perfected (Cherokee + Varnish) I will write up a how-to to share with the community. 2009/8/27 Antonio Pérez <[email protected]>: > Hi, > > On Wed, Aug 26, 2009 at 2:12 PM, pub crawler<[email protected]> wrote: > >> Having issues with the IP information when we put Varnish in front. If >> we run Varnish and bypass Cherokee going directly to our web server >> the IP information is fine. Similarly, if we eliminate Varnish and run >> Cherokee going directly to our web server the IP information is >> fine/correct. >> >> [...] >> >> My guess here is that Cherokee is taking the CGI.REMOTE_ADDR or >> equivalent on requests and not utilizing the X-Forwarded-For when such >> is already set and available. > > Do you mean you are getting 127.0.0.1 as remote address in logs or in > REMOTE_ADDR CGI variable? If it is the first, did you check "Accept > Forwarded IPs" option in "YourVirtualServer->Logging" section?. If > it's the second, then it's the expected behaviour as well, AFAIK. > > > -- > Saludos: > Antonio Pérez > _______________________________________________ Cherokee mailing list [email protected] http://lists.octality.com/listinfo/cherokee
