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

Raspberry Pi / Docker latest image not compatible due to timesync #1589

Closed
mboehm21 opened this issue Sep 20, 2021 · 9 comments
Closed

Raspberry Pi / Docker latest image not compatible due to timesync #1589

mboehm21 opened this issue Sep 20, 2021 · 9 comments

Comments

@mboehm21
Copy link

The time in the container is not in sync with the host which results in lots of problems like timeouts.

Might be related to this issue:

debuerreotype/docker-debian-artifacts#106

root@raspi3:~# 
root@raspi3:~# 
root@raspi3:~# docker ps | grep nextcloud
6c57f860b180   nextcloud:latest              "/entrypoint.sh apac…"   12 hours ago   Up 12 hours   80/tcp                         nextcloud-stack_nextcloud-1.1.qjbze6wwcfd36qnfk1lzwl87r
root@raspi3:~# cat /etc/os-release 
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
root@raspi3:~# docker exec -it nextcloud-stack_nextcloud-1.1.qjbze6wwcfd36qnfk1lzwl87r date
Thu Jan  1 00:00:00 UTC 1970
root@raspi3:~# 
root@raspi3:~# 
root@raspi3:~# date
Mon 20 Sep 11:33:45 CEST 2021
root@raspi3:~# cat /etc/os-release 
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
root@raspi3:~# docker exec -it nextcloud-stack_nextcloud-1.1.qjbze6wwcfd36qnfk1lzwl87r date
Thu Jan  1 00:00:00 UTC 1970
root@raspi3:~# docker exec -it nextcloud-stack_nextcloud-1.1.qjbze6wwcfd36qnfk1lzwl87r hwclock --show --verbose
hwclock from util-linux 2.36.1
System Time: -1092462948.-1225633632
Trying to open: /dev/rtc0
Trying to open: /dev/rtc
Trying to open: /dev/misc/rtc
No usable clock interface found.
hwclock: Cannot access the Hardware Clock via any known method.
@szaimen szaimen transferred this issue from nextcloud/server Sep 20, 2021
@ghost
Copy link

ghost commented Sep 20, 2021

Mount

volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro

Date an time will be the same as on host.

@mboehm21
Copy link
Author

mboehm21 commented Sep 20, 2021

Mount

volumes:

  • /etc/timezone:/etc/timezone:ro
  • /etc/localtime:/etc/localtime:ro

Date an time will be the same as on host.

Hey, it is not a timezone problem. The clock is not running at all inside the container. It stays Thu Jan 1 00:00:00 UTC 1970 forever.

it might be an issue with buster on the host and bullseye in the container?

@ghost
Copy link

ghost commented Sep 20, 2021

I just tested it on my Pi4. Buster on host and the latest nextcloud image (Debian 11). Everything was fine just 2 hours difference due to wrong timezone.

Strange.

@mboehm21
Copy link
Author

mboehm21 commented Sep 20, 2021

I just tested it on my Pi4. Buster on host and the latest nextcloud image (Debian 11). Everything was fine just 2 hours difference due to wrong timezone.

Strange.

Thanks for testing. Could you send me a “dpkg -l” and “docker images” of your host so that I can compare?

@ghost
Copy link

ghost commented Sep 20, 2021

REPOSITORY TAG IMAGE ID CREATED SIZE
nextcloud latest 0dd24a9c32e9 2 weeks ago 806MB
postgres latest 95cc60d09644 2 weeks ago 266MB

Ok, dpkg is a bit long . Over 500 entries. I put it in a text file.
list.txt

@mboehm21
Copy link
Author

Okay, that is fun:

You have:

ii libseccomp2:armhf 2.4.4-1~bpo10+1 armhf high level interface to Linux seccomp filter

I have:

ii libseccomp2:armhf 2.3.3-4 armhf high level interface to Linux seccomp filter

When I install the package of your version manually, everything works:

wget http://ftp.us.debian.org/debian/pool/main/libs/libseccomp/libseccomp2_2.4.4-1~bpo10+1_armhf.deb
dpkg -i libseccomp2_2.4.4-1~bpo10+1_armhf.deb
systemctl restart docker


pi@raspi3:~ $ docker exec -it nextcloud-stack_nextcloud-1.1.dra87g3uhs45838kjhh7v89v2 date
Mon Sep 20 17:11:55 UTC 2021

Would you mind to send me your active repos? I want to check why the package is not updated on my raspi.

@ghost
Copy link

ghost commented Sep 20, 2021

Yes, forgot about that. I was building a new image on bullseye basis and had a few errors. Someone on GitHub pointed me to this problem. This link helped: https://docs.linuxserver.io/faq#my-host-is-incompatible-with-images-based-on-ubuntu-focal-and-alpine-3-13

@J0WI
Copy link
Contributor

J0WI commented Sep 20, 2021

Unfortunately Raspbian uses some very old packages. There is nothing we can fix in our image. 😕

@mboehm21
Copy link
Author

@J0WI: I see but now we have a valid workaround till it is fixed by Raspbian.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants