geerlingguy / internet-monitoring

Monitor your network and internet speed with Docker & Prometheus
1.28k stars 139 forks source link

Speedtest container initialisation error #17

Closed PabloScolpino closed 3 years ago

PabloScolpino commented 3 years ago

Description

on startup the speedtest container crashes (and restarts continuously) with the following error:

speedtest_1   | Current thread 0xb6fa0390 (most recent call first):
speedtest_1   | <no Python frame>
speedtest_1   | Fatal Python error: init_interp_main: can't initialize time
speedtest_1   | Python runtime state: core initialized
speedtest_1   | PermissionError: [Errno 1] Operation not permitted

Environment

The OS for the raspberry pi was the provided raspberry OS from factory (which already makes me think I should make a fresh, controlled, install by myself).

The environment this is running is:

+pi@raspberrypi:~ $ whoami
pi
+pi@raspberrypi:~ $ groups
pi adm dialout cdrom sudo audio video plugdev games users input netdev lpadmin docker gpio i2c spi
+pi@raspberrypi:~ $ uname -a
Linux raspberrypi 5.10.17-v7l+ #1421 SMP Thu May 27 14:00:13 BST 2021 armv7l GNU/Linux
+pi@raspberrypi:~ $ cat /proc/cpuinfo  | grep Model
Model       : Raspberry Pi 4 Model B Rev 1.4

Instalation

The project setup was done following your article, up to the point of docker-compose up -d (since I'm running this locally and don't need remote access).

Fixes attempted

To Do

geerlingguy commented 3 years ago

Hmm... another thing I noticed: https://github.com/dchesterton/amcrest2mqtt/issues/20 (similar issue as the one you linked).

And that triggered my memory of https://github.com/geerlingguy/internet-pi/pull/11 — I have only been testing on the 64-bit version of Pi OS. Apparently there's an issue on 32-bit Pi OS.

gktval commented 3 years ago

The steps here worked: https://blog.samcater.com/fix-workaround-rpi4-docker-libseccomp2-docker-20/ I didn't quite understand it though, because my docker version went down from 20.10.7 to 20.10.5.

geerlingguy commented 3 years ago

@gktval - Well, for that blog post the author didn't want to use the Docker install script from Docker, so the version of docker installed via backports is actually slightly older (shouldn't be an issue though). My playbook (internet-pi) still installs Docker using the install script.

geerlingguy commented 3 years ago

Noting that the problem is, indeed, an outdated version of libseccomp2 on Raspberry Pi OS 32-bit, and the solution is to either use my internet-pi project (which has this fix: https://github.com/geerlingguy/internet-pi/pull/11), or to manually update that binary using the instructions linked earlier in this post.

PabloScolpino commented 3 years ago

The steps here worked: https://blog.samcater.com/fix-workaround-rpi4-docker-libseccomp2-docker-20/ I didn't quite understand it though, because my docker version went down from 20.10.7 to 20.10.5.

That post does not mention libseccomp2, my original installation satisfied both the criteria mentioned there (docker and OS versions) but as the libseccomp2 version installed was ~ 2.3.3 the error existed.

Reinstalled the os with the 64 bit lite version image from RaspberryOs official images and it's working perfectly out of the box (without tweaking the repo setup).

Thanks for the information and patience.

PS: I did not know rbOS 64 bit was in beta. I actually had thought it was the default. 🤦🏻

geerlingguy commented 3 years ago

@PabloScolpino - I wish it was the default :( Lots of things are fixed and work better in the 64-bit build.