Hi,
I encountered the same thing before. My solution was to apply the
patched as mentioned at the end of this page:
http://wiki.squid-cache.org/ConfigExamples/DynamicContent/YouTube/Discussion?highlight=%28ConfigExamples%2FIntercept%29|%28ConfigExamples%2FAuthenticate%29|%28ConfigExamples%2FChat%29|%28ConfigExamples%2FStreams%29|%28ConfigExamples%2FReverse%29|%28ConfigExamples%2FStrange%29
HTH,
Khem
On 05/27/2010 12:51 PM, Guillaume 4 wrote:
Hi there
I'm using a squid proxy with a youtube rewrite module to cache the vids.It's working ~fine except for *some* vids that won't load.
When trying to view the vids, youtube says : "An error occurred, please try again later."
This isn't really relevant, but in the store.log, here what I get :
1274876139.777 RELEASE -1 FFFFFFFF 2171EABA7915771683088F05E4A343B1 204 1274875723 -1 41629446 text/html 0/0 GET http://www.youtube.com/player_204?el=detailpage&fv=LNX%2010,1,53,22&scoville=1&ec=100&fexp=902919&plid=AASHfiKGfwfeoAfQ&rt=0.246&event=streamingerror&v=dk6Yu2BRC6g&fmt=34
1274876269.468 RELEASE -1 FFFFFFFF D0C3CF82B3C1E75EFFBBA2C475D7DEBE 204 1274875853 -1 41629446 text/html 0/0 GET http://www.youtube.com/player_204?el=detailpage&fv=LNX%2010,1,53,22&scoville=1&ec=100&fexp=902919&plid=AASHfiKGfwfeoAfQ&rt=129.896&event=streamingerror&v=dk6Yu2BRC6g&fmt=34
When I remove the store_url_rewrite part into the squid.conf, it does works fine.
Note this is only happening to *some* vids, the rest is woking fine and being cached properly.
Here's my store_url_rewrite script :
#!/usr/bin/perl$|=1;while (<>) { @X = split; $x = $X[0]; $_ = $X[1];
# compatibility from old cached get_video?video_idif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?(videoplayback\?id=.*?|video_id=.*?)\&(.*?)/) { $z = $2; $z =~ s/video_id=/get_video?video_id=/; print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $z . "\n";
# youtube HD itag=22} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?\&(itag=22).*?\&(id=[a-zA-Z0-9]*)/) { print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $2 . "&" . $3 . "\n";
# youtube Normal screen always HD itag 35, Normal screen never HD itag 34, itag=18<--normal?} elsif (m/^http:\/\/([0-9.]{4}|.*\.youtube\.com|.*\.googlevideo\.com|.*\.video\.google\.com).*?\&(itag=[0-9]*).*?\&(id=[a-zA-Z0-9]*)/) { print $x . "http://video-srv.youtube.com.SQUIDINTERNAL/" . $3 . "\n";
} else { print $x . $_ . "\n";}}
I really don't know where to search at the moment, any suggestion will be more than welcome! :)
Thanks in advance,Guillaume
_________________________________________________________________
Hotmail: Trusted email with powerful SPAM protection.
https://signup.live.com/signup.aspx?id=60969