Getting kodi to run nicely on Raspbian

This blog post is about getting Kodi up and running with Netflix on Raspbian. This is not a tutorial, more a collection of notes for myself in order to reproduce the setup.

Basic install

Get a recent version of Raspbian from the Raspberry Pi website. (Or my ftp mirror). Extract it to a fresh micro-SD card and get the system ready. Follow this guide, if you need help. Boot into the system and run a update and install some handy tools

Next, we are gonna harden the system. For that do the following

  • Set root password
  • Rename user pi to something else
  • Remove the NOPASSWD for user pi
  • Permit root-ssh login only via public key

Install Kodi

First add the following repository

Now install kodi

Autostart Kodi

Ok, kodi is installed, now we need to start kodi. For that we create a systemd service by putting the following to /etc/systemd/system/kodi.service

Install the Netflix Plugin

The Netflix Plugin is hosted on GitHub. Download the plugin and install the zip-file. Best option seems to be to put it on a USB-Stick and install it from there. This plugin needs parted or fdisk, you install them on your kodi and then let the plugin install the widevine library, necessary for the DRM. The DRM is by the way also the thing, that was in the way of getting Netflix work in the first place. And it's still a bit of a mess, since we are using here a extraction of the libwidevine from the chromecast.

Well, as long as it works, but it's not nice and probably creating causing one or two times headache until it finally works.

Allow Kodi to reboot and shutdown

This is now more a quick fix, based on the suggestion from here. The original clue was posted long time ago on the kodi forums, but those posts were only of limited help. So, create the following file


I encountered the problem, that if Kodi runs for too long (multiple days), the Netflix plugin stopped working. No errors given, it just won't play a movie again. A quick fix is to schedule a reboot every night using a cronjob

Further work

This is of course just the basic installation. You will need to configure Kodi to your needs (Skins, Addons, Timezone, connect your NAS, ...)

Also, I might create an ansible-playbook to setup this procedure. This looks like a fun project to do on a rainy Sunday.

For now, I'm off, watching some Netflix ­čÖé

For fuck sake

(Sorry, it's in German) (Sorry again, ich bin w├╝tend)

In Anbetracht des aktuellen politischen Klimas: Woher kommt denn nochmals die ganze Politikverdrossenheit? Warum nochmals f├╝hlen sich vor allem j├╝ngere W├Ąhler nicht oder nicht mehr repr├Ąsentiert?

PS. Das Outcome der Entscheidung zum Uploadfilter ist hier vollkommen belanglos. Wir k├Ânnen einen Kampf f├╝hren und wir k├Ânnen auch verlieren. No hard feelings about that.

Aber WIE in den letzten Wochen mit Kritik umgegangen, wie von seitens einiger EU Parlamentarier bewusst diffamiert und beschwichtigt wurde, ist inakzeptabel.

Das werden wir nicht vergessen. Wir sehen uns bei den n├Ąchsten Wahlen.


I wrote a small bash script, that transforms IP addresses into HEX format. The tool consists of 10 lines of bash script

I needed the tool to match IP-addresses to HEX files for PXE boot. Normally PXE boot fetches first the MAC-address, and then iteratively for the HEX representation of the IP address, with reducing the number of matching characters. Oracle documents the behavior very nicely for the IP address ""which matches "C000025B" and the imaginary MAC-address "88:99:AA:BB:CC:DD". Then the PXE client probes for the following files (in the given order)

Now, with iphex I can easily convert the more used numerical representation of IP-addresses like into the IMHO not directly visible HEX representation.

Kernel build bug - KVM_AMD and CRYPTO_DEV_CPP

About a week ago, I failed to build a Kernel for my new Ryzen 2700X working machine. After some time of configuring my kernel I run into some weird problems

The problem

I wanted to have a Kernel with KVM_AMD support enabled. The build was going on fine, until some weird linker errors appeared.

(Full output [Pastebin])

Since I'm a Kernel rookie, it took me some time to realize what was going on. A google search didn't revealed a solution, other than something similar on Unix Stackexchange, that was not directly applicable for my case.

The problem persisted and is reproducible in linux-4.17.1 and linux-4.16.15, using this config file. Building linux-4.14.49 was doing fine. For any options that were not defined by the config file I chose the default suggestion.


The problem arises, if CONFIG_CRYPTO_DEV_CCP_DD is compiled as module [=m], also if the SEV is not used. Enabling CONFIG_CRYPTO_DEV_CCP_DD to be compiled in the kernel [=y] is a workaround for the issue.

This commit already revealed the issue.

I had to Include the "Secure Processor device driver", that is found in Cryptographic API > Hardware crypto devices

Weirdly, the suggested solution from Unix Stackexchange was not solving the problem for me, neither was it causing problems. I could build the Kernel (4.17.1) with "Kernel-based Virtual Machine Support" set as module. But those are just my two cents, it might have been an issue some versions ago ...

Unluckily I cannot contribute to Unix Stackexchange yet (not enough reputation *sigh*), so I cannot improve the answer there.

Thanks to Richard!

Many thanks to Richard, who provided me with support, regarding nailing it down to a bug in the Kernel build system.

AMD releases amdgpu-pro driver 17.30

Just some time ago, I let myself go and wrote about how upset I was about the (missing) support for my new RX 470 on Linux.

Today AMD released the amdgpu-pro driver 17.30, with support for Kernel 4.10 and Xorg 1.19. So my setup is finally not useless anymore. Details are on the AMD download page.

I've just installed the driver without any problems, after a reboot it works just fine. Videos are playing and I could start Civilization Beyond Earth from Steam under Ubuntu 16.04.3 with HWE.

It's two and a half minutes to midnight

The doomsday clock is at two-and-a-half minutes to midnight. The doomsday clock is a illustration of how close we are to a man-made global catastrophe, published by " The Bulletin of the Atomic Scientists' Science and Security Board".

Last time it was at that level has been 1953, during the tests of the Hydrogen-Fusion bombs.

Source: Wikipedia

The main reasons are

  • Rise of nationalism
This already-threatening world situation was
the backdrop for a rise in strident nationalism
worldwide in 2016
  • Trump
Donald Trump, made disturbing comments about
the use and proliferation of nuclear weapons and
expressed disbelief in the overwhelming scientific
consensus on climate change.
  • Conflict USA and Russia
both countries (USA and Russia)
continued wide-ranging
modernizations of their nuclear
forces, and serious arms control
negotiations were nowhere to
be seen
  • North Korea
North Korea conducted
its fourth and fifth underground
nuclear tests and gave every
indication it would continue
to develop nuclear weapons delivery capabilities.
The full statement is available here.

I consider this bulletin as a calibration to reality and a big F**K YOU in the direction of nationalism and the disbelief in science.
Although I'm a big Fallout fan and like the concept of Vaultec Vaults, it's not that we should now go and dig a whole in case of some president having a loose finger on the Atomic Football, but it is worrisome.
And I use it as reason to motivate more people to do a HAM-radio course and buy equipment ­čÖé

GPX to GeoJson convert tool

I hacked a C++ tool for converting GPX files to GeoJson, because the only one I could find used Node.js. The tool is available on GitHub. Binaries are available for GNU/Linux, the tool should be compatible with MacOS and Windows (Not tested).

Runtime comparison with togeojson (Node.js)

And now with my tool

It's dirty, I wrote in in about an hour, but it does the job for my purposes and I want to share it in case someone else finds it useful.