Search squid archive

RE: Ignore requests from certain hosts in access_log

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Wow, I still can't seem to get this working!  I can't figure out what I am doing wrong:

# Put the load balancers in an ACL so we can ignore requests (health checks) from them
acl loadbalancers src 172.26.100.136/255.255.255.255
acl loadbalancers src 172.26.100.137/255.255.255.255

# We want to append the X-Forwarded-For header
follow_x_forwarded_for allow loadbalancers
log_uses_indirect_client on
acl_uses_indirect_client on

# Define Logging (do not log loadbalancer health checks)
access_log /var/log/squid/access.log squid
log_access deny loadbalancers
coredump_dir /var/spool/squid
pid_filename /var/run/squid.pid
httpd_suppress_version_string on
shutdown_lifetime 5 seconds
# We don't cache, so there is no need to waste disk I/O on cache logging
cache_store_log none

These changes aren't suppressing any logs:

Health checks still show up:

1269265701.388      0 172.26.100.136 TCP_DENIED/400 2570 GET error:invalid-request - NONE/- text/html
1269265703.009      0 172.26.100.137 TCP_DENIED/400 2570 GET error:invalid-request - NONE/- text/html
1269265706.389      0 172.26.100.136 TCP_DENIED/400 2570 GET error:invalid-request - NONE/- text/html
1269265708.010      0 172.26.100.137 TCP_DENIED/400 2570 GET error:invalid-request - NONE/- text/html

.. as well as normal traffic using X-Forwarded-For.

What am I doing wrong here?

Thanks,

Josh

-----Original Message-----
From: Amos Jeffries [mailto:squid3@xxxxxxxxxxxxx] 
Sent: Friday, March 19, 2010 7:29 PM
To: squid-users@xxxxxxxxxxxxxxx
Subject: Re:  Ignore requests from certain hosts in access_log

Baird, Josh wrote:
> And, you still see the non-healthcheck, normal traffic logged using the X-Forwarded-For information?

Yes.

> 
> Here is my entire config, maybe this will help:
<snip>
> 
> # We want to append the X-Forwarded-For header for Websense
> follow_x_forwarded_for allow loadbalancers
> log_uses_indirect_client on
> acl_uses_indirect_client on
> 
> # Define Logging (do not log loadbalancer health checks)
> access_log /var/log/squid/access.log squid
> log_access deny !loadbalancers

Gah. Stupid me not reading that right earlier.

Means: deny all requests that are NOT loadbalancers.

You are wanting:
   log_access deny loadbalancers

So sorry.


Amos
-- 
Please be using
   Current Stable Squid 2.7.STABLE8 or 3.0.STABLE25
   Current Beta Squid 3.1.0.18


[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux