VideoCache
Videocache is no longer in development.

Cache not working at all

by Anonymous on 17 Nov 2008

I've followed the example below and installed the older version, just as the example asks.

http://sitegeisha.blogspot.com/2008/11/youtube-cache-with-squid.html

Exact install steps
Base debian install

apt-get update
apt-get install ssh python squid
apt-get install libnet-ssleay-perl openssl libauthen-pam-perl libio-pty-perl libmd5-perl
apt-get install python-urlgrabber
apt-get install lighttpd

wget http://debcache/linux/utils/libiniparser2_2.17-2~ppa4_i386.deb
wget http://debcache/linux/utils/youtube_cache-1.2.tar.gz
wget http://debcache/linux/utils/webmin_1.430_all.deb
wget http://debcache/linux/utils/iniparse-0.2.3.tar.gz

tar xzvf youtube_cache-1.2.tar.gz
tar xzvf iniparse-0.2.3.tar.gz
dpkg --install webmin_1.430_all.deb
cd iniparse-0.2.3
python setup.py install
cd ..
cd youtube_cache-1.2
vim setup.py
replace squid with proxy in group and user
replace apache_conf_dir with /etc/apache2/conf.d/
python setup.py install

mkdir /etc/apache2
mkdir /etc/apache2/conf.d

vim /etc/squid/squid.conf
add lines 
vim /etc/youtube_cache.conf
change base_dir to /var/www/video_cache
change cache_host = proper ip
change proxy = proper ip
cp -r /var/spool/squid/video_cache /var/www/
chown -R proxy:proxy /var/www/video_cache/
chmod -R 755 /var/www/video_cache/
/etc/init.d/squid restart
/etc/init.d/lighttpd restart

change proxy settings in firefox to ip 3128 not found
What did i do wrong?

14 Answers

by josgan on 17 Nov 2008

sorry i tried the .deb package for iniparser and that didn't install so i grabbed the gzipped too and apparently it didn't paste right into this field. but here's that command

wget http://debcache/linux/utils/iniparse-0.2.3.tar.gz

by Kulbir Saini on 18 Nov 2008

What is not found? Are you able to access http://your_ip_address/video_cache/ ? Also can you please paste your /var/log/squid/youtube_cache.log file somewhere so that I can get a clue whether your youtube cache is working or not.

by josgan on 18 Nov 2008

I can get to the Video_cache directory, but when I change firefox to use the proxy with the ip of the proxy server specified under "http" proxy and 3128 under port. I can't get anywhere. "Address not found"

youtube_cache.log

2008-11-17 11:55:31,736 INFO - - XMLRPCServer - Starting XMLRPCServer on port 9100.
2008-11-17 11:55:31,737 INFO - - SCHEDULEDER - Download Scheduler starting.
by Kulbir Saini on 18 Nov 2008

Then your squid needs to be fixed. Please paste your squid.conf file on pastebin.com.

by josgan on 18 Nov 2008

here it is
http://pastebin.com/m7fa83ee1

by Kulbir Saini on 18 Nov 2008

Squid.conf is also fine. Well, then its not a squid or youtube cache problem. "Address Not Found" should be because your system is not able to resolve the domain name of the website you are willing to visit. Please consult your operating system forum or irc channel for tackling this problem.

by josgan on 18 Nov 2008

The system can access the page when the proxy is not specified. There are no firewalls in place on either system. I can ping the website from both the proxy and the client.

by ezz on 9 Apr 2009

hi,
after extract youtube_cache1.2 and change some of lines , i typed python setup.py install at terminal but there`s an error which is :

Traceback (most recent call last):
  File "setup.py", line 39, in <module>
    mainconf =  readMainConfig(readStartupConfig(config_file, '/'))
  File "/home/ezz/Desktop/youtube_cache-1.2/youtube_cache/config.py", line 665,in readStartupConfig
    parser.readfp(confpp_obj)
  File "/usr/lib/python2.5/site-packages/iniparse/compat.py", line 106, in readfp
    self.data.readfp(fp)
  File "/usr/lib/python2.5/site-packages/iniparse/ini.py", line 471, in readfp
    for line in fp:
TypeError: iteration over non-sequence

can any one help me !!

by ezz on 9 Apr 2009

then after typed sudo tail -f /var/log/squid/youtube_cache.log
an error appeared : cannot open `/var/log/squid/youtube_cache.log' for reading: No such file or directory
tail: no files remaining

by Kulbir Saini on 9 Apr 2009

Ezz,

You are using a very old version of videocache. Download the latest version from download page. And follow the instructions on installation page.

Thank You!

by ezz on 9 Apr 2009

hi ,
the same error appeared with video_cache 1.9... what can i do ?
thx 4 reply :)

by bremboster on 26 May 2009

Sir,

Can you give an example squid.conf file which is
configured for cache video?

I had configure squid.conf with VideoCache 1.9 by reading the tutorial. It seems work for http cache. I can browse the net
if I point my firefox browser with proxy setting
i.e 192.168.1.200 port 3128

But couldnt cache any from youtube. Seems like my config for
VideoCache doesnt work at all.

I also got this error when I want to view the log

sudo tail -f /var/log/squid/youtube_cache.log
an error appeared : cannot open `/var/log/squid/youtube_cache.log' for reading: No such file or directory
tail: no files remaining

Thank you

by Anonymous on 13 Sep 2010

I have a problem in squid

when i restart service

-bash: /etc/init.d/lighttpd: No such file or directory

please give me solution

by Kulbir Saini on 24 Sep 2010

Hi!

Can you try using apache instead? Please check http://httpd.apache.org.

Thank You!