Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MySQL with Squid proxy server

Status
Not open for further replies.

grobinson

Programmer
Feb 4, 2005
1
GB
I was just wondering, does anyone have any experience of setting up Squid to work with MySQL? Basically, I have a number of allowed web sites that I want squid to be able to access, but by default Squid doesn't support MySQL and I'm having difficulty finding sources with information on how to enable access. I know it's possible because the current (soon to be deprecated) proxy has this functionality - shame we're no longer in contact with the person who set it up!

The only other solution I can think of is to write the database to a file every so often, as the list of allowed sites is constantly being updated. Is there a way in MySQL to write the contents of a database to a text file say every 5 minutes?

Any help would be greatly appreciated.
 
Yes, there is. Check out "cron" for the scheduling, then write a script which exports the database for Squid. This is what I did once, and it works fine as long as the site list isn't too large.

If you have a large list, check out SquidGuard which uses a database and seems quite a bit more efficient.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top