Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR: unable to download video data: <urlopen error [Errno 101] Network is unreachable> #13264

Closed
montanaflynn opened this issue Jun 2, 2017 · 3 comments

Comments

@montanaflynn
Copy link

@montanaflynn montanaflynn commented Jun 2, 2017

Before submitting an issue make sure you have:

  • I've verified and I assure that I'm running youtube-dl 2017.05.29
  • At least skimmed through README and most notably FAQ and BUGS sections
  • Searched the bugtracker for similar issues including closed ones

What is the purpose of your issue?

  • Bug report (encountered problems with youtube-dl)
  • Site support request (request for adding support for a new site)
  • Feature request (request for a new functionality)
  • Question
  • Other

If the purpose of this issue is a bug report, site support request or you are not completely sure provide the full verbose output as follows:

Add -v flag to your command line you run youtube-dl with, copy the whole output and insert it here. It should look similar to one below (replace it with your log inserted between triple ```):

$ youtube-dl -v --print-traffic "https://www.youtube.com/watch?v=DdIUuUY0L9c"
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'-v', u'--print-traffic', u'https://www.youtube.com/watch?v=DdIUuUY0L9c']
[debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2017.05.29
[debug] Python version 2.7.12 - Linux-4.4.35+-x86_64-with-Ubuntu-14.04-trusty
[debug] exe versions: ffmpeg 3.3.1-static, ffprobe 3.3.1-static
[debug] Proxy map: {}
[youtube] DdIUuUY0L9c: Downloading webpage
send: u'GET /watch?v=DdIUuUY0L9c&gl=US&hl=en&has_verified=1&bpctr=9999999999 HTTP/1.1\r\nAccept-Language: en-us,en;q=0.5\r\nAccept-Encoding: gzip, deflate\r\nConnection: close\r\nAccept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8\r\nUser-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20150101 Firefox/47.0 (Chrome)\r\nAccept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7\r\nHost: www.youtube.com\r\nCookie: PREF=f1=50000000&hl=en\r\n\r\n'
reply: 'HTTP/1.1 200 OK\r\n'
header: X-Frame-Options: SAMEORIGIN
header: P3P: CP="This is not a P3P policy! See http://support.google.com/accounts/answer/151657?hl=en for more info."
header: Expires: Tue, 27 Apr 1971 19:44:06 EST
header: Content-Type: text/html; charset=utf-8
header: Cache-Control: no-cache
header: X-XSS-Protection: 1; mode=block; report=https://www.google.com/appserve/security-bugs/log/youtube
header: Strict-Transport-Security: max-age=31536000
header: Content-Encoding: gzip
header: X-Content-Type-Options: nosniff
header: Date: Fri, 02 Jun 2017 18:40:36 GMT
header: Server: YouTubeFrontEnd
header: Set-Cookie: YSC=meJ2DAv1Blw; path=/; domain=.youtube.com; httponly
header: Set-Cookie: VISITOR_INFO1_LIVE=YSPh9eM8Sog; path=/; domain=.youtube.com; expires=Thu, 01-Feb-2018 06:33:36 GMT; httponly
header: Set-Cookie: s_gl=1d69aac621b2f9c0a25dade722d6e24bcwIAAABVUw==; path=/; domain=.youtube.com
header: Connection: close
header: Transfer-Encoding: chunked
[youtube] DdIUuUY0L9c: Downloading video info webpage
send: u'GET /get_video_info?el=info&ps=default&video_id=DdIUuUY0L9c&hl=en&sts=17318&gl=US&eurl= HTTP/1.1\r\nAccept-Language: en-us,en;q=0.5\r\nAccept-Encoding: gzip, deflate\r\nConnection: close\r\nAccept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8\r\nUser-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20150101 Firefox/47.0 (Chrome)\r\nAccept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7\r\nHost: www.youtube.com\r\nCookie: YSC=meJ2DAv1Blw; VISITOR_INFO1_LIVE=YSPh9eM8Sog; PREF=f1=50000000&hl=en; s_gl=1d69aac621b2f9c0a25dade722d6e24bcwIAAABVUw==\r\n\r\n'
reply: 'HTTP/1.1 200 OK\r\n'
header: Cache-Control: no-store
header: Content-Type: application/x-www-form-urlencoded
header: X-XSS-Protection: 1; mode=block; report=https://www.google.com/appserve/security-bugs/log/youtube
header: Expires: Tue, 27 Apr 1971 19:44:06 EST
header: Content-Encoding: gzip
header: X-Content-Type-Options: nosniff
header: P3P: CP="This is not a P3P policy! See http://support.google.com/accounts/answer/151657?hl=en for more info."
header: X-Frame-Options: SAMEORIGIN
header: Strict-Transport-Security: max-age=31536000
header: Date: Fri, 02 Jun 2017 18:40:37 GMT
header: Server: YouTubeFrontEnd
header: Set-Cookie: s_gl=1d69aac621b2f9c0a25dade722d6e24bcwIAAABVUw==; path=/; domain=.youtube.com
header: Connection: close
header: Transfer-Encoding: chunked
[youtube] DdIUuUY0L9c: Extracting video information
[youtube] DdIUuUY0L9c: Downloading MPD manifest
send: u'GET /api/manifest/dash/ms/au/mt/1496428761/as/fmp4_audio_clear%2Cfmp4_sd_hd_clear/mv/u/id/0dd214b946342fd7/sparams/as%2Cei%2Chfr%2Cid%2Cip%2Cipbits%2Citag%2Cmm%2Cmn%2Cms%2Cmv%2Cpl%2Cplayback_host%2Crequiressl%2Csource%2Cexpire/requiressl/yes/pl/20/source/youtube/ei/JbExWZevBMeOuAKN24-oBw/ip/35.188.93.89/ipbits/0/signature/07DEC6CD2FEB4A2799CDC8C3C879B084DFBB74F0.11111890F94D40C602A93AABC5D454209937B41A/hfr/1/key/yt6/mn/sn-vgqs7nez/mm/31/playback_host/r5---sn-vgqs7nez.googlevideo.com/expire/1496450437/itag/0 HTTP/1.1\r\nAccept-Language: en-us,en;q=0.5\r\nAccept-Encoding: gzip, deflate\r\nConnection: close\r\nAccept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8\r\nUser-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20150101 Firefox/47.0 (Chrome)\r\nAccept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7\r\nHost: manifest.googlevideo.com\r\n\r\n'
reply: 'HTTP/1.1 200 OK\r\n'
header: Content-Type: video/vnd.mpeg.dash.mpd
header: Date: Fri, 02 Jun 2017 18:40:37 GMT
header: Pragma: no-cache
header: Expires: Fri, 01 Jan 1990 00:00:00 GMT
header: Cache-Control: no-cache, must-revalidate
header: Content-Encoding: gzip
header: Server: HTTP server (unknown)
header: X-XSS-Protection: 1; mode=block
header: X-Frame-Options: SAMEORIGIN
header: Connection: close
header: Transfer-Encoding: chunked
[debug] Invoking downloader on u'https://r5---sn-vgqs7nez.googlevideo.com/videoplayback?id=0dd214b946342fd7&itag=133&source=youtube&requiressl=yes&ms=au&mv=u&pl=20&ei=JbExWZevBMeOuAKN24-oBw&mn=sn-vgqs7nez&mm=31&ratebypass=yes&mime=video/mp4&gir=yes&clen=1484497&lmt=1387353010324072&dur=48.415&mt=1496428761&signature=7D27F70FFE5CC048F01321AFA36569714E047AE3.232B16EB25B34BFDFF249359ECADF3BA20F17D75&key=dg_yt0&ip=35.188.93.89&ipbits=0&expire=1496450437&sparams=ip,ipbits,expire,id,itag,source,requiressl,ms,mv,pl,ei,mn,mm,ratebypass,mime,gir,clen,lmt,dur'
ERROR: unable to download video data: <urlopen error [Errno 101] Network is unreachable>
Traceback (most recent call last):
  File "/usr/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1797, in process_info
    partial_success = dl(fname, new_info)
  File "/usr/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1745, in dl
    return fd.download(name, info)
  File "/usr/bin/youtube-dl/youtube_dl/downloader/common.py", line 360, in download
    return self.real_download(filename, info_dict)
  File "/usr/bin/youtube-dl/youtube_dl/downloader/http.py", line 61, in real_download
    data = self.ydl.urlopen(request)
  File "/usr/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 2106, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/usr/lib/python2.7/urllib2.py", line 429, in open
    response = self._open(req, data)
  File "/usr/lib/python2.7/urllib2.py", line 447, in _open
    '_open', req)
  File "/usr/lib/python2.7/urllib2.py", line 407, in _call_chain
    result = func(*args)
  File "/usr/bin/youtube-dl/youtube_dl/utils.py", line 1082, in https_open
    req, **kwargs)
  File "/usr/lib/python2.7/urllib2.py", line 1198, in do_open
    raise URLError(err)
URLError: <urlopen error [Errno 101] Network is unreachable>

Description of your issue, suggested solution and other information

In the last few hours our servers have been unable to download videos from youtube using youtube-dl. Restarting the server works a for a little while and then the requests stop working again.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Jun 2, 2017

The reason is clearly explained in the error message.

@montanaflynn
Copy link
Author

@montanaflynn montanaflynn commented Jun 2, 2017

Is youtube known to rate-limit or blacklist servers that make too many requests?

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Jun 2, 2017

Yes, but it's not necessarily the case. Most likely an intermittent connectivity issue to some particular hosts namely r5---sn-vgqs7nez.googlevideo.com.

@ytdl-org ytdl-org deleted a comment from crystaler4 May 6, 2020
@ytdl-org ytdl-org locked and limited conversation to collaborators May 6, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.