Hi,
I'm having problem with videocache-1.6-1, I got this error.
Exception in thread Thread-2:
Traceback (most recent call last):
File "/usr/lib64/python2.4/threading.py", line 442, in "bootstrap
self.run()
File "/usr/share/videocache/videocache.py", line 790, in run
download_scheduler()
File "/usr/share/videocache/videocache.py", line 759, in download_scheduler
if video_id_pool.get_conn_number() < max_parallel_downloads:
File "/usr/lib64/python2.4/xmlrpclib.py", line 1096, in "call"
return self."send(self."name, args)
File "/usr/lib64/python2.4/xmlrpclib.py", line 1383, in "request
verbose=self."verbose
File "/usr/lib64/python2.4/xmlrpclib.py", line 1129, in request
self.send_content(h, request_body)
File "/usr/lib64/python2.4/xmlrpclib.py", line 1243, in send_content
connection.endheaders()
File "/usr/lib64/python2.4/httplib.py", line 798, in endheaders
self._send_output()
File "/usr/lib64/python2.4/httplib.py", line 679, in _send_output
self.send(msg)
File "/usr/lib64/python2.4/httplib.py", line 646, in send
self.connect()
File "/usr/lib64/python2.4/httplib.py", line 630, in connect
raise socket.error, msg
error: (111, 'Connection refused')
My system is:
Fedora Core 6 X64
videocache-1.6-1 (rpm install)
python-2.4.3-18.fc6
python-urlgrabber-2.9.9-2
python-iniparse-0.2.2-1.fc6
httpd-2.2.6-1.fc6
How to fix this error? Thanks.
15 Answers
Restarting or reloading the squid proxy server should normally solve this problem. But in case you can't get rid of it, then please check your SELinux settings. Please disable it to run videocache without any problems.
SELinux is already disabled, restarting squid and the problem still exist. Did I miss something?
Please see if anything else (other service) is listening on the port 9100.
Use netstat -atpn |grep 9100
If anything else is listening on this port, change the port to some number on which no other application is listening.
Otherwise contact using contact tab on top.
Thank you for using videocache :)
You need to wait until ALL the TIME_WAIT sockets go away too,
You might also want to try the HEAD version which fixes some issues with the XMLRPC client/server comms.
Thanks Imriz for the insight. But what do you think may be the reason for TIME_WAIT sockets? I can't really get into the depth of this.
Hi,
here is my netstat -atpn |grep 9100:
tcp 0 0 127.0.0.1:9100 0.0.0.0:* LISTEN 22654/(python)
tcp 0 0 127.0.0.1:9100 127.0.0.1:26467 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26466 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26465 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25953 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26464 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25952 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26471 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26470 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26469 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26468 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26475 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26474 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26473 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26472 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26479 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26478 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26477 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26476 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26483 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26482 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26481 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26480 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26487 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26486 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26485 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26484 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26490 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26489 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26488 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26495 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26494 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26493 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26492 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25947 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25946 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25945 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25951 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25950 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26462 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26461 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25949 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26460 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:25948 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26499 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26498 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26497 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26496 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26503 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26502 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26501 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26500 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26507 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26505 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26504 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26510 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26509 TIME_WAIT -
tcp 0 0 127.0.0.1:9100 127.0.0.1:26508 TIME_WAIT -
and here is from cache.log;
2008/12/17 23:45:21| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:45:21| redirectHandleReply: {}
2008/12/17 23:46:04| redirectStart: 'http://v8.cache.googlevideo.com/get_video?origin=sjc-v242.sjc.youtube.com&video_id=9sWeOHsX2Xw&ip=203.91.159.27®ion=0&signature=CD26DB7A5FB8D51C74F9FADF47E5592D9608C001.C3C473C0352E5ABB0AD5678B88E18B393ED96BC0&sver=2&expire=1229553996&key=yt4&ipbits=0'
2008/12/17 23:46:04| redirectHandleReply: {}
2008/12/17 23:46:05| redirectStart: 'http://v4.cache.googlevideo.com/videoplayback?id=f6c59e387b17d97c&itag=6&begin=0&len=604800000&ip=203.91.159.27®ion=0&signature=1F4190F1D54ED4C6D841E47501E825922B71FDBD.376AC157C40A5F5B1BD0576AD17EFC8DDB257175&sver=2&expire=1229553998&key=yt4&ipbits=0'
2008/12/17 23:46:05| redirectHandleReply: {}
2008/12/17 23:46:13| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:46:13| redirectHandleReply: {}
2008/12/17 23:46:13| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:46:13| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:46:13| redirectHandleReply: {}
2008/12/17 23:46:13| redirectHandleReply: {}
2008/12/17 23:46:13| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:46:13| redirectHandleReply: {}
2008/12/17 23:46:15| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:46:15| redirectHandleReply: {}
2008/12/17 23:46:15| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:46:15| redirectHandleReply: {}
2008/12/17 23:46:15| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:46:15| redirectHandleReply: {}
2008/12/17 23:46:16| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/Z1DDQG1P6.flv?start=0'
2008/12/17 23:46:16| redirectHandleReply: {}
2008/12/17 23:46:43| redirectStart: 'http://v.mccont.com/ItemFiles/%5BFrom%20www.metacafe.com%5D%202174884.9150173.11.flv?"gda"=1229539630_31694528b6fd1ad063bc8ebace6d73e3'
2008/12/17 23:46:43| redirectHandleReply: {}
2008/12/17 23:47:13| redirectStart: 'http://dl.redtube.com/_videos_t4vn23s9jc5498tgj49icfj4678/0000019/62XXQA1MP.flv?start=0'
2008/12/17 23:47:13| redirectHandleReply: {}
2008/12/17 23:48:12| redirectStart: 'http://v1.cache.googlevideo.com/get_video?origin=sjc-v184.sjc.youtube.com&video_id=JSLApQSV80s&ip=203.91.159.141®ion=0&signature=2F18E015E7771EE32ADC1A71DFECB8F3F9B8A929.3ADF7FEBE3DDFE35CACAFDFDADD3F4CADC628140&sver=2&expire=1229554125&key=yt4&ipbits=0'
2008/12/17 23:48:12| redirectHandleReply: {}
2008/12/17 23:48:12| redirectStart: 'http://v13.cache.googlevideo.com/get_video?origin=mia-v238.mia.youtube.com&video_id=eCyp6qRTgpk&ip=203.91.159.27®ion=0&signature=5F8555B7621637EF8CC87185A455374D20ADC86B.113B09C9203FAB26083A16063BFB6583943F54C5&sver=2&expire=1229554124&key=yt4&ipbits=0'
2008/12/17 23:48:12| redirectHandleReply: {}
2008/12/17 23:48:32| redirectStart: 'http://v9.cache.googlevideo.com/get_video?origin=sjc-v287.sjc.youtube.com&video_id=R8UYzrfyXh4&ip=203.91.159.152®ion=0&signature=73D6BF63CC1D9638BC435CD0B300A5334080123C.84E40B4A18C613735EC205CF9EDC096816903AC7&sver=2&expire=1229554130&key=yt4&ipbits=0'
2008/12/17 23:48:32| redirectHandleReply: {}
2008/12/17 23:48:40| redirectStart: 'http://v11.cache.googlevideo.com/videoplayback?id=ff0811308d929cbe&itag=5&begin=0&len=604800000&ip=203.91.159.27®ion=0&signature=BB862140951EAE49877B66F4EADE919B786BE977.D9DDDA8203BBA770D71D3CC803C2E0900477084F&sver=2&expire=1229554152&key=yt4&ipbits=0'
2008/12/17 23:48:40| redirectHandleReply: {}
2008/12/17 23:48:40| redirectStart: 'http://v19.cache.googlevideo.com/videoplayback?id=ff0811308d929cbe&itag=6&begin=0&len=604800000&ip=203.91.159.27®ion=0&signature=BA2B821A3458B385B54A5ABB186E412395912A7B.4F95D202493E0CDC5348E3C52E8E0F45174F86ED&sver=2&expire=1229554153&key=yt4&ipbits=0'
2008/12/17 23:48:40| redirectHandleReply: {}
2008/12/17 23:48:56| redirectStart: 'http://v6.cache.googlevideo.com/videoplayback?id=bb93ecc18883ca0f&itag=18&begin=0&len=604800000&ip=203.91.159.152®ion=0&signature=606682C0CAE4D937358C78214AC038D02A13B338.AD02C84D7EE00C582F2301A06196B9E1FBC270E0&sver=2&expire=1229553081&key=yt4&ipbits=0'
2008/12/17 23:48:56| redirectHandleReply: {}
2008/12/17 23:49:17| redirectStart: 'http://v24.cache.googlevideo.com/get_video?origin=sjc-v169.sjc.youtube.com&video_id=knIcSXGwUGI&ip=203.91.159.141®ion=0&signature=94D4D349C9598BC3161517D14203D489B342D96E.4A8655FCA6491690E8E44DBD85F139250C88E6A1&sver=2&expire=1229554191&key=yt4&ipbits=0'
2008/12/17 23:49:17| redirectHandleReply: {}
Hi Sizulku,
Can you please try replacing your /usr/share/videocache/videocache.py with this videocache.py? Otherwise contact me using this contact form, we'll figure it out :)
Hi Kulbir,
I try to contact you through contact form but seemed you did not receive it.
I've try to use videocache.py from the given link but it still did not work, its also shutdown squid when I try to restart squid's service. Here is the logs:
2008/12/18 11:20:14| redirectStart: 'http://v16.cache.googlevideo.com/videoplayback?id=046c65caa2d8a332&itag=6&ip=203.91.159.27®ion=0&signature=5666DEED91E550BC38BA3A30C02AA971FAA58C40.5BCC1502D1E3E4AAC4CF026F67F532605ABE499C&sver=2&expire=1229595652&key=yt4&ipbits=0'
2008/12/18 11:20:14| redirectHandleReply: {}
2008/12/18 11:21:20| redirectStart: 'http://ash-v712.ash.youtube.com/get_video?video_id=mG4SLxgyhKI&ip=203.91.153.134&signature=DCB49788121694BF9054842C4D77436E22543DF3.78DA329344D030EC59E5C7BE72BB24CA6028F912&sver=2&expire=1229595718&key=yt4&ipbits=0'
2008/12/18 11:21:20| redirectHandleReply: {}
2008/12/18 11:22:28| redirectStart: 'http://v20.cache.googlevideo.com/get_video?origin=sjl-v104.sjl.youtube.com&video_id=wblFGSaA9M8&ip=202.152.20.202®ion=0&signature=92AC73288B063F75D56317B5A9FC81149C0B8223.DEA35BA01AF7E4C1EB98A37692768698138FCE22&sver=2&expire=1229595779&key=yt4&ipbits=0'
2008/12/18 11:22:28| redirectHandleReply: {}
2008/12/18 11:23:24| redirectStart: 'http://v16.cache.googlevideo.com/videoplayback?id=046c65caa2d8a332&itag=6&ip=203.91.159.27®ion=0&signature=6C38284382647BAF317FF4807AB5847513F0A854.851DC107745B48C83A97856741E3E5A6CC58FC19&sver=2&expire=1229595842&key=yt4&ipbits=0'
2008/12/18 11:23:24| redirectHandleReply: {}
CPU Usage: 51.734 seconds = 18.066 user + 33.668 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 0
Memory usage for squid via mallinfo():
total space in arena: 857716 KB
Ordinary blocks: 857367 KB 647 blks
Small blocks: 0 KB 4 blks
Holding blocks: 127064 KB 11 blks
Free Small blocks: 0 KB
Free Ordinary blocks: 348 KB
Total in use: 984431 KB 100%
Total free: 348 KB 0%
FATAL: The url_rewriter helpers are crashing too rapidly, need help!
Squid Cache (Version 2.7.STABLE5-20081114): Terminated abnormally.
CPU Usage: 4.022 seconds = 1.094 user + 2.929 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 0
Memory usage for squid via mallinfo():
total space in arena: 87352 KB
Ordinary blocks: 87239 KB 2 blks
Small blocks: 0 KB 0 blks
Holding blocks: 77744 KB 11 blks
Free Small blocks: 0 KB
Free Ordinary blocks: 112 KB
Total in use: 164983 KB 100%
Total free: 112 KB 0%
FATAL: The url_rewriter helpers are crashing too rapidly, need help!
Squid Cache (Version 2.7.STABLE5-20081114): Terminated abnormally.
CPU Usage: 5.916 seconds = 1.626 user + 4.290 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 0
Memory usage for squid via mallinfo():
total space in arena: 130120 KB
Ordinary blocks: 130077 KB 2 blks
Small blocks: 0 KB 0 blks
Holding blocks: 80104 KB 11 blks
Free Small blocks: 0 KB
Free Ordinary blocks: 42 KB
Total in use: 210181 KB 100%
Total free: 42 KB 0%
FATAL: The url_rewriter helpers are crashing too rapidly, need help!
Squid Cache (Version 2.7.STABLE5-20081114): Terminated abnormally.
CPU Usage: 4.011 seconds = 1.031 user + 2.981 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 0
Memory usage for squid via mallinfo():
total space in arena: 87224 KB
Ordinary blocks: 87084 KB 2 blks
Small blocks: 0 KB 0 blks
Holding blocks: 77744 KB 11 blks
Free Small blocks: 0 KB
Free Ordinary blocks: 139 KB
Total in use: 164828 KB 100%
Total free: 139 KB 0%
FATAL: The url_rewriter helpers are crashing too rapidly, need help!
Squid Cache (Version 2.7.STABLE5-20081114): Terminated abnormally.
CPU Usage: 1.910 seconds = 0.491 user + 1.419 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 0
Memory usage for squid via mallinfo():
total space in arena: 40360 KB
Ordinary blocks: 40271 KB 2 blks
Small blocks: 0 KB 0 blks
Holding blocks: 75104 KB 11 blks
Free Small blocks: 0 KB
Free Ordinary blocks: 88 KB
Total in use: 115375 KB 100%
Total free: 88 KB 0%
FATAL: The url_rewriter helpers are crashing too rapidly, need help!
Squid Cache (Version 2.7.STABLE5-20081114): Terminated abnormally.
CPU Usage: 5.011 seconds = 1.362 user + 3.649 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 0
Memory usage for squid via mallinfo():
total space in arena: 110716 KB
Ordinary blocks: 110645 KB 2 blks
Small blocks: 0 KB 0 blks
Holding blocks: 80104 KB 11 blks
Free Small blocks: 0 KB
Free Ordinary blocks: 70 KB
Total in use: 190749 KB 100%
Total free: 70 KB 0%
Hi Sizulku,
I am sorry I couldn't reply. I have replied now. Check your mail.
Thank you for considering videocache :)
It is a feature of the TCP stack (http://www.developerweb.net/forum/showthread.php?t=2941).
I think we have those after a videocache shutdown beacause the XML-RPC server is not releasing the socket properly.
FATAL: The url_rewriter helpers are crashing too rapidly, need help!
I have the same problem, running in python 2.5 on MAC OX 10.5.6.
Any solution?
Hi Joaquim,
Can you please lookup your squid cache.log file and check for python tracebacks in there? It would help me in suggesting a solution.
Thank you for considering videocache :)
in 10.5.6 running apache and the latest videocache, followed the tutorial exactly, using php 2.4 ...
cache.log has many of these
Exception in thread Thread-2:
Traceback (most recent call last):
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/threading.py", line 442, in "bootstrap
self.run()
File "/usr/share/videocache/videocache.py", line 791, in run
download_scheduler()
File "/usr/share/videocache/videocache.py", line 759, in download_scheduler
if video_id_pool.get_conn_number() < max_parallel_downloads:
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/xmlrpclib.py", line 1096, in "call"
return self."send(self."name, args)
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/xmlrpclib.py", line 1383, in "request
verbose=self."verbose
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/xmlrpclib.py", line 1129, in request
self.send_content(h, request_body)
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/xmlrpclib.py", line 1243, in send_content
connection.endheaders()
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/httplib.py", line 798, in endheaders
self._send_output()
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/httplib.py", line 679, in _send_output
self.send(msg)
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/httplib.py", line 646, in send
self.connect()
File "/opt/local/Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/httplib.py", line 630, in connect
raise socket.error, msg
error: (61, 'Connection refused')
Also i have confirmed that i do see that metacafe cached... but youtube isnt for some reason.