pfSense Gold Subscription

Author Topic: Squid as cache to Windows Update  (Read 6594 times)

0 Members and 1 Guest are viewing this topic.

Offline Heitor Lessa

  • Full Member
  • ***
  • Posts: 170
  • Karma: +0/-0
    • View Profile
Squid as cache to Windows Update
« on: October 22, 2009, 01:22:24 pm »
I'd like if it possible to configure squid with above refresh_pattern on custom options:

refresh_pattern update.microsoft.com/.*\.(cab|exe|dll|msi) 10080 100% 43200 reload-into-ims
refresh_pattern windowsupdate.com/.*\.(cab|exe|dll|msi) 10080 100% 43200 reload-into-ims
refresh_pattern download.microsoft.com/.*\.(cab|exe|dll|msi) 10080 100% 43200 reload-into-ims
refresh_pattern www.microsoft.com/.*\.(cab|exe|dll|msi) 10080 100% 43200 reload-into-ims
refresh_pattern au.download.windowsupdate.com/.*\.(cab|exe|dll|msi) 4320 100% 43200 reload-into-ims

Cause in my squid (2.7) on pfsense seems not accept anyone commands from custom option, until more simple as "acl teste dstdomain ou url_regex" + http_access deny teste" not works.

 If anyone can help me... I'll appreciate.

Offline jimp

  • Administrator
  • Hero Member
  • *****
  • Posts: 14998
  • Karma: +4/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #1 on: October 22, 2009, 11:45:08 pm »
It works for me (custom options)

I have an article on the doc wiki that describes this process:

http://doc.pfsense.org/index.php/Squid_Package_Tuning#Caching_Windows_Updates

Make sure you end those custom options lines with a semicolon.
Need help fast? Commercial Support!

Co-Author of pfSense: The Definitive Guide. - Check the Doc Wiki for FAQs.

Do not PM for help!

Offline Heitor Lessa

  • Full Member
  • ***
  • Posts: 170
  • Karma: +0/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #2 on: October 23, 2009, 09:23:49 am »
It's strange, my squid not accept my custom options, but I include this as my normal squid running on Debian GNU/LINUX:

refresh_pattern update.microsoft.com/.*\.(cab|exe|dll|msi) 10080 100% 43200 reload-into-ims;refresh_pattern windowsupdate.com/.*\.(cab|exe|dll|msi) 10080 100% 43200 reload-into-ims;
refresh_pattern download.microsoft.com/.*\.(cab|exe|dll|msi) 10080 100% 43200 reload-into-ims;
refresh_pattern www.microsoft.com/.*\.(cab|exe|dll|msi) 10080 100% 43200 reload-into-ims;
refresh_pattern au.download.windowsupdate.com/.*\.(cab|exe|dll|msi) 4320 100% 43200 reload-into-ims;

Current version is 1.2.3-RC1.

 But I'll try your advice.

Thanks

Offline jimp

  • Administrator
  • Hero Member
  • *****
  • Posts: 14998
  • Karma: +4/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #3 on: October 23, 2009, 10:00:42 am »
Something else to watch out for, I just double checked mine and I have no newlines in it, so it's all one line, with statements separated by semicolons, so it looks like this:

refresh_pattern windowsupdate.com/.*\.(cab|exe) 4320 100% 43200 reload-into-ims;refresh_pattern download.microsoft.com/.*\.(cab|exe) 4320 100% 43200 reload-into-ims;refresh_pattern au.download.windowsupdate.com/.*\.(cab|exe) 4320 100% 43200 reload-into-ims;refresh_pattern guru.avg.com/.*\.(bin) 4320 100% 43200 reload-into-ims;range_offset_limit -1
Need help fast? Commercial Support!

Co-Author of pfSense: The Definitive Guide. - Check the Doc Wiki for FAQs.

Do not PM for help!

Offline Heitor Lessa

  • Full Member
  • ***
  • Posts: 170
  • Karma: +0/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #4 on: October 25, 2009, 06:37:46 pm »
oK.. thanks =).

 IŽll try tomorrow, but if I put the "wrong" way, the Pfsense fix automatical.

 But tomorrow IŽll test and post here again.

 Thanks one more time.

Offline Heitor Lessa

  • Full Member
  • ***
  • Posts: 170
  • Karma: +0/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #5 on: October 30, 2009, 07:26:32 pm »
Sorry about late.

 But when IŽll try to test I decided to upgrade to new version (1.2.3 RC-3), but now my pfsense cannot resolve names from internet more.

dnsmasq[31484]: exiting on receipt of SIGTERM <- This message appears for me, and now I canŽt connect to internet over Pfsense, I try to reinstall pfsense but not works.

 can you help me?

Offline jimp

  • Administrator
  • Hero Member
  • *****
  • Posts: 14998
  • Karma: +4/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #6 on: October 30, 2009, 07:39:32 pm »
Not sure what might be going on there, but that is unrelated to this thread. If you still need help, start a new thread in the appropriate board with a new subject.
Need help fast? Commercial Support!

Co-Author of pfSense: The Definitive Guide. - Check the Doc Wiki for FAQs.

Do not PM for help!

Offline Heitor Lessa

  • Full Member
  • ***
  • Posts: 170
  • Karma: +0/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #7 on: October 30, 2009, 07:43:00 pm »
Ok no problem.

 I prefer not disturb some users with my doubt, IŽll try to reinstall old version.

 Thanks for your information.

 You can close this topic.

Offline cylent

  • Full Member
  • ***
  • Posts: 101
  • Karma: +0/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #8 on: December 20, 2009, 11:23:41 am »
can the same be applied for youtube videos to cache flv videos?


Offline jimp

  • Administrator
  • Hero Member
  • *****
  • Posts: 14998
  • Karma: +4/-0
    • View Profile
Re: Squid as cache to Windows Update
« Reply #9 on: December 20, 2009, 11:33:25 am »
can the same be applied for youtube videos to cache flv videos?

No, but there are some other docs out there which cover that. There is an add-on for squid that will cache videos. Some searching should turn it up.
Need help fast? Commercial Support!

Co-Author of pfSense: The Definitive Guide. - Check the Doc Wiki for FAQs.

Do not PM for help!