บทความอัพเดทในเว็บ ขออนุญาตอัพเดทช่องทาง https://fb.com/siamcafefan

ผู้เขียน หัวข้อ: ผมใช้ squid 2.7 ของ windows xp ครับ ???  (อ่าน 4899 ครั้ง)

0 สมาชิก และ 1 บุคคลทั่วไป กำลังดูหัวข้อนี้

ออฟไลน์ ultramaxx

  • มือใหม่
  • *
  • กระทู้: 3
  • Reputation: 0
ผมใช้ squid 2.7 ของ windows xp ครับ ???
« เมื่อ: พฤษภาคม 26, 2009, 03:03:04 am »
ผมทำอย่างไรก็ cache youtube ไม่ได้ครับ
ลองหาข้อมูลดู เห็นมีแต่ config ที่เป็นของ ฝุ่ง linux ครับ
ลองเอามาประยุกใช้ดู ผมว่าผมติดที่ปัญหา store_url_rewriteนี่แหละครับ
ผมลองโหลด store_url_rewrite จากที่แจกๆกัน (ของ linux นะครับ) เอาไปใส่ตาม dir ที่เซ้ตใน config ไว้ ลองใช้ config นี้ เพิ่มดู
acl store_rewrite_list url_regex ^http://(.*?)/get_video\?
acl store_rewrite_list url_regex ^http://(.*?)/videodownload\?
acl store_rewrite_list url_regex ^http://i(.*?).photobucket.com/albums/(.*?)/(.*?)/(.*?)\?
acl store_rewrite_list url_regex ^http://vid(.*?).photobucket.com/albums/(.*?)/(.*?)\?

cache allow store_rewrite_list
cache allow all

storeurl_access allow store_rewrite_list
storeurl_access deny all
storeurl_rewrite_program C:/squid/bin/store_url_rewrite

acl QUERY urlpath_regex cgi-bin \? .acgi .asp .cgi .css .chtml .dll .htm .html .ini .jhtml .js .jsp .perl .phtml .pl .php .php3 .php4 .shtml .xhtml .xml .xtp updatelist$ FantaTennis FantaUpdater FantaLauncher AduRenderDll AduEngineDll Court_Ad Main_Ad Loading.jpg notice_popup korea.dat thailand.dat channel.dat CrazyKartClient.dat update_list.txt UCG.exe UCGA.exe UCG.DAT version.cfg
cache deny QUERY

-------อันนี้ส่วนที่อยู่ใน store_url_rewrite----------
#!/usr/bin/perl

$|=1;
 while (<>) {
    @X = split;
   $url = $X[0];
   $url =~ s@^http://(.*?)/get_video\?(.*)video_id=(.*?)&.*@squid://videos.youtube.INTERNAL/ID=$3@;
   $url =~ s@^http://(.*?)/get_video\?(.*)video_id=(.*?)$@squid://videos.youtube.INTERNAL/ID=$3@;
   $url =~ s@^http://(.*?)/videodownload\?(.*)docid=(.*?)$@squid://videos.google.INTERNAL/ID=$3@;
   $url =~ s@^http://(.*?)/videodownload\?(.*)docid=(.*?)&.*@squid://videos.google.INTERNAL/ID=$3@;
   $url =~ s@^http://(.*?)/albums\?&.*@squid://images.photobucket.INTERNAL/ID=$3@;
   $url =~ s@^http://(.*?)/albums\?$@squid://images.photobucket.INTERNAL/ID=$3@;
   $url =~ s@^http://(.*?)/albums\?&.*@squid://videos.photobucket.INTERNAL/ID=$3@;
   $url =~ s@^http://(.*?)/albums\?$@squid://videos.photobucket.INTERNAL/ID=$3@;
      print "$url\n";
 }

----------------------------------------------


ปรากฏว่า เข้าไปyoutube ได้ครับ แต่ ดู vdo ไม่ได้อีกเลย error ตลอด แต่เวปอื่นเข้าได้ หรือว่าคำสั่งใน store_url_rewriteของ ver windows ไม่ใช่แบบนี้ครับ งงมาก
ใครมี config สำหรับ xp ที่ มันจะ cache youtube ได้ ช่วยมาแบ่งปันกันหน่อยนะครับ หมดปัญญาแล้วครับ
Signature cleanned by Admin