Categories: technology tv Tags: media

Downloading from German TV Streams

I wanted to download German TV Streaming media, on a schedule (i.e. to grab a particular show on a weekly basis). That’s not particularly difficult, but it took a while

Source URLS:

Lots of good information here: the URL I wanted was for “Das Erste”:


I pretty quickly decided that VLC could do what I needed (via command line interface, cvlc). My first attempt was a bash script like so:

cd /temp/Video/
timeout 2h cvlc --sout file/ts:SavedFile_$(date +%F).ts


This nearly worked but with 2 problems:

Working Solution

I spent a lot of time trying to use different URLs, or to set a preferred resolution, without success. Final fix was to add an extra tool: Streamlink

This wasn’t in Debian at the time, but can be installed with pip. However, I was keen not to add repositories and to at least sort-of sandbox it, so installation steps I followed were:

pip install virtualenv
mkdir ~/src/StreamLink
cd ~/src/StreamLink
virtualenv StreamLink
source StreamLink/bin/activate
pip install streamlink

Then I reworked my bash script like so (note here I’m downloading at 540p):

source ~/src/StreamLink/StreamLink/bin/activate
cd ~/temp/Video/

timeout 2h streamlink --player="cvlc --sout file/ts:SavedFile_$(date +%F_%T)_540p.ts" \ 540p
>> Home