Hi, I try to write a simple external helper for test.
#!/bin/bash while read ip ; do if [ -e /tmp/test.err ] ; then echo "ERR" else echo "OK" fi done squid.conf external_acl_type test_helper ttl=0 negative_ttl=0 grace=0 %SRC /usr/lib64/squid/test.sh acl testacl external test_helper acl site1 dst 10.1.6.1 cache_peer proxy1.example.com parent 3128 0 name=P1 no-digest no-query cache_peer proxy2.example.com parent 3128 0 name=P2 no-digest no-query cache_peer_access P1 deny site1 testacl cache_peer_access P1 allow all cache_peer_access P2 allow all My plan is let site1 go through P1 proxy when exist /tmp/test.err file. But I'm fail because I found squid didn't check testacl. 0 requests in External ACL Statistics # FD PID # Requests # Pending Flags Time Offset Request 1 38 21919 0 0 0.000 0 (none) 2 39 21920 0 0 0.000 0 (none) But I configure like this: external_acl_type test_helper ttl=0 negative_ttl=0 grace=0 %SRC /usr/lib64/squid/test.sh acl testacl external test_helper http_access testacl all . . cache_peer_access P1 deny site1 testacl cache_peer_access P1 allow all It work. so, I think maybe external helper can't work first with cache_peer_access? My Squid Cache: Version 3.1.10 -- Regards, John Xue