Blog Archives
How to extract video URLs from YouTube
I know there are many tools out there that allow you to download videos from YouTube, like the Video Download Helper for Firefox, even online tools that convert the audio to mp3. The reasons I’m writing this article are a) because sometimes you just need the URL, for example to watch a video with a much less ressource consuming player like VLC or ffplay, b) because sometimes you just want to listen to the audio and save up even more ressources by not decoding the video and c) because I can 😉
Read the rest of this entry
How to make daily backups with rsync and cronjobs
It’s always a good idea to make backups of important data (documents, images, music, etc.), e.g. the worst case for students is to lose data of written reports or theses.
I wanted to make backups of my documents and source codes every day. The backup should be stored on a usb flash drive. But I also wanted to keep deleted files for a couple of days, in case of accidentally deleted files. There are many ways to complete this task, but I decided to use rsync and cronjobs for this purpose. Both tools make the backup process very flexible. It’s very easy to manage the time of the backup process with cronjobs and rsync makes it easy to change the destination (e.g. another folder, device or remote host).
My idea was to add a cronjob to start a bash script which uses rsync to copy the directories and files to the flash drive. But the device names of flash drives changes, if you plug them in a different order. To avoid this problem, I added a udev rule to create a symbolic link every time the flash drive is plugged.
Read the rest of this entry