Greetings to all,
I am new to FreeBSD. I actually installed FreeBSD yesterday and migrated one of my servers (Squid Proxy) and I am facing an issue with a very simple script running with an acl. The same script and acl did work in Linux like a charm. I used Ubuntu Server 11.10 and Slackware 13.37. Anyways, Squid 3.1.10 is rocking but this small glitch.
Every single time the script is being run, I get -->
I have checked all the permissions of the script, ad_block.txt and temp_ad_file. I have chmod 777 and chown to squid user all the files including script. The script functions corrctly but seems to give up when the command [cmd=]squid -k reconfigure[/cmd] is being issued.
I would really appreciate any help of course and if not thank you for taking the time reading my post
Kind Regards,
Here is the acl I am using:
Here is the script being used:
I am new to FreeBSD. I actually installed FreeBSD yesterday and migrated one of my servers (Squid Proxy) and I am facing an issue with a very simple script running with an acl. The same script and acl did work in Linux like a charm. I used Ubuntu Server 11.10 and Slackware 13.37. Anyways, Squid 3.1.10 is rocking but this small glitch.
Every single time the script is being run, I get -->
Code:
2011/10/25 19:59:45| Warning: empty ACL: acl ads dstdom_regex "/usr/local/etc/squid/ad_block.txt"
I have checked all the permissions of the script, ad_block.txt and temp_ad_file. I have chmod 777 and chown to squid user all the files including script. The script functions corrctly but seems to give up when the command [cmd=]squid -k reconfigure[/cmd] is being issued.
I would really appreciate any help of course and if not thank you for taking the time reading my post
Kind Regards,
Here is the acl I am using:
Code:
acl ads dstdom_regex "/etc/squid/ad_block.txt"
Here is the script being used:
Code:
#!/bin/bash
## get new ad server list
/usr/bin/wget -O /tmp/temp_ad_file \
[url]http://pgl.yoyo.org/adservers/serverlist.php?hostformat=squid-dstdom-regex;showintro=0[/url]
## clean html headers out of list
cat /tmp/temp_ad_file | grep "(^|" > /etc/squid/ad_block.txt
## refresh squid
/usr/sbin/squid -k reconfigure
## rm temp file
rm -rf /tmp/tmp_ad_file