Open logdotexe opened 3 years ago
Yes, I have the same issue which doesn't exist with the x86 version of lancache. For some reason, _lancache-rpi_dns1 does not restart on startup. However, it will work when you run your restart script from the lancache directory with _./rebootlancache.sh or simply run docker-compose restart
Weird. The docker-compose.yml
has restart: always
set for each container. What is the output of docker inspect lancache-rpi_dns_1
?
Hello, I have been following this thread as my setup does the same thing.
After Restart:
pi@Steve:~/lancache-rpi $ docker inspect lancache-rpi_dns_1 [ { "Id": "1ff294099a3d00881ba52f6dc98dba11a1987c57869f3d70d050e08b09a76e61", "Created": "2021-05-16T17:23:09.228553435Z", "Path": "/bin/bash", "Args": [ "-e", "/init/entrypoint", "/init/supervisord" ], "State": { "Status": "running", "Running": true, "Paused": false, "Restarting": false, "OOMKilled": false, "Dead": false, "Pid": 1269, "ExitCode": 0, "Error": "", "StartedAt": "2021-07-28T19:31:32.442245818Z", "FinishedAt": "2021-07-28T19:31:03.841807523Z" }, "Image": "sha256:8ea156aae7ebf23663e2926b062358790e35b80f820480fa72441c50b5a2c36e", "ResolvConfPath": "/var/lib/docker/containers/1ff294099a3d00881ba52f6dc98dba11a1987c57869f3d70d050e08b09a76e61/resolv.conf", "HostnamePath": "/var/lib/docker/containers/1ff294099a3d00881ba52f6dc98dba11a1987c57869f3d70d050e08b09a76e61/hostname", "HostsPath": "/var/lib/docker/containers/1ff294099a3d00881ba52f6dc98dba11a1987c57869f3d70d050e08b09a76e61/hosts", "LogPath": "/var/lib/docker/containers/1ff294099a3d00881ba52f6dc98dba11a1987c57869f3d70d050e08b09a76e61/1ff294099a3d00881ba52f6dc98dba11a1987c57869f3d70d050e08b09a76e61-json.log", "Name": "/lancache-rpi_dns_1", "RestartCount": 0, "Driver": "overlay2", "Platform": "linux", "MountLabel": "", "ProcessLabel": "", "AppArmorProfile": "", "ExecIDs": null, "HostConfig": { "Binds": [], "ContainerIDFile": "", "LogConfig": { "Type": "json-file", "Config": {} }, "NetworkMode": "lancache-rpi_default", "PortBindings": { "53/tcp": [ { "HostIp": "192.168.1.3", "HostPort": "53" } ], "53/udp": [ { "HostIp": "192.168.1.3", "HostPort": "53" } ] }, "RestartPolicy": { "Name": "always", "MaximumRetryCount": 0 }, "AutoRemove": false, "VolumeDriver": "", "VolumesFrom": [], "CapAdd": null, "CapDrop": null, "Dns": [], "DnsOptions": [], "DnsSearch": [], "ExtraHosts": null, "GroupAdd": null, "IpcMode": "shareable", "Cgroup": "", "Links": null, "OomScoreAdj": 0, "PidMode": "", "Privileged": false, "PublishAllPorts": false, "ReadonlyRootfs": false, "SecurityOpt": null, "UTSMode": "", "UsernsMode": "", "ShmSize": 67108864, "Runtime": "runc", "ConsoleSize": [ 0, 0 ], "Isolation": "", "CpuShares": 0, "Memory": 0, "NanoCpus": 0, "CgroupParent": "", "BlkioWeight": 0, "BlkioWeightDevice": null, "BlkioDeviceReadBps": null, "BlkioDeviceWriteBps": null, "BlkioDeviceReadIOps": null, "BlkioDeviceWriteIOps": null, "CpuPeriod": 0, "CpuQuota": 0, "CpuRealtimePeriod": 0, "CpuRealtimeRuntime": 0, "CpusetCpus": "", "CpusetMems": "", "Devices": null, "DeviceCgroupRules": null, "DiskQuota": 0, "KernelMemory": 0, "MemoryReservation": 0, "MemorySwap": 0, "MemorySwappiness": null, "OomKillDisable": null, "PidsLimit": 0, "Ulimits": null, "CpuCount": 0, "CpuPercent": 0, "IOMaximumIOps": 0, "IOMaximumBandwidth": 0, "MaskedPaths": [ "/proc/asound", "/proc/acpi", "/proc/kcore", "/proc/keys", "/proc/latency_stats", "/proc/timer_list", "/proc/timer_stats", "/proc/sched_debug", "/proc/scsi", "/sys/firmware" ], "ReadonlyPaths": [ "/proc/bus", "/proc/fs", "/proc/irq", "/proc/sys", "/proc/sysrq-trigger" ] }, "GraphDriver": { "Data": { "LowerDir": "/var/lib/docker/overlay2/ea8acd304cb11b004ad939ea9c2ecbcd8570197bcea74869a6f060d57f604362-init/diff:/var/lib/docker/overlay2/f778585a9ed31beb9ff43c127b16c3e18c16b1561309d118928207a5c21eb168/diff:/var/lib/docker/overlay2/cd43786b4feedfc8f0031e1cfa78fc6c26581e3dc22a85990990497f6b7207d1/diff:/var/lib/docker/overlay2/a3b03377d50a4035cf1fb9499760c1e35972af222dde35cbb26ab1057dcf83ed/diff:/var/lib/docker/overlay2/0393f059ebaf77f207ad47045c55ff828ab9edf837cac14280198d84a12a1e1d/diff:/var/lib/docker/overlay2/a7aee561aca8b067268748860612107e23c74c1a95a32687f5e52b0d8d6206c6/diff:/var/lib/docker/overlay2/dfe3c0e0f9d3cadbbdd2602b93165abb1f6d992c33f6f2023f0b310b82424ec3/diff:/var/lib/docker/overlay2/6f39524184e5bec86e728826f2fe5bf63572f37620e4f5449a5f544f29102571/diff:/var/lib/docker/overlay2/3eeb5b3fd14f56183fba96b9c8d81ba2834863873be72c3b1cdb767866eb60c5/diff:/var/lib/docker/overlay2/76c0caf1990272192cbadc8047ddb538e5c337f4952446ac52118ee11e53294b/diff:/var/lib/docker/overlay2/6248ad5879f9a35bdf8b875580846961a7fce7ab9f30747abc44efd27fad1206/diff:/var/lib/docker/overlay2/36731ff2cc48c7671fc227aef16b027026fbccbb6cc3d5eed4b39df14dee3273/diff:/var/lib/docker/overlay2/7bec97e7be86a5fa430b1f81808346bf007562d56cf0e2474e304d6762c28b86/diff:/var/lib/docker/overlay2/306cf4e9a494a0781900f181db6bf4d496322101426cccc7da8fcf8f5d65a6b7/diff", "MergedDir": "/var/lib/docker/overlay2/ea8acd304cb11b004ad939ea9c2ecbcd8570197bcea74869a6f060d57f604362/merged", "UpperDir": "/var/lib/docker/overlay2/ea8acd304cb11b004ad939ea9c2ecbcd8570197bcea74869a6f060d57f604362/diff", "WorkDir": "/var/lib/docker/overlay2/ea8acd304cb11b004ad939ea9c2ecbcd8570197bcea74869a6f060d57f604362/work" }, "Name": "overlay2" }, "Mounts": [], "Config": { "Hostname": "1ff294099a3d", "Domainname": "", "User": "", "AttachStdin": false, "AttachStdout": false, "AttachStderr": false, "ExposedPorts": { "53/tcp": {}, "53/udp": {} }, "Tty": false, "OpenStdin": false, "StdinOnce": false, "Env": [ "USE_GENERIC_CACHE=true", "LANCACHE_IP=192.168.1.3", "DNS_BIND_IP=192.168.1.3", "UPSTREAM_DNS=192.168.1.1", "CACHE_ROOT=/mnt/USBHDD/share/Cache", "CACHE_MEM_SIZE=500m", "CACHE_DISK_SIZE=350000m", "CACHE_MAX_AGE=3650d", "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin", "SUPERVISORD_EXIT_ON_FATAL=1", "LC_ALL=en_GB.UTF-8", "LANG=en_GB.UTF-8", "LANGUAGE=en_GB.UTF-8", "TZ=Europe/London", "SUPERVISORD_LOGLEVEL=WARN", "STEAMCACHE_DNS_VERSION=1", "ENABLE_DNSSEC_VALIDATION=false", "LANCACHE_DNSDOMAIN=cache.lancache.net", "CACHE_DOMAINS_REPO=https://github.com/uklans/cache-domains.git", "CACHE_DOMAINS_BRANCH=master" ], "Cmd": [ "/init/supervisord" ], "ArgsEscaped": true, "Image": "jrcichra/lancachenet-lancache-dns:latest", "Volumes": null, "WorkingDir": "/scripts", "Entrypoint": [ "/bin/bash", "-e", "/init/entrypoint" ], "OnBuild": null, "Labels": { "com.docker.compose.config-hash": "334fffc2dc11263d8854a61760005cadc343531d02663554a72ae18d7396ce51", "com.docker.compose.container-number": "1", "com.docker.compose.oneoff": "False", "com.docker.compose.project": "lancache-rpi", "com.docker.compose.service": "dns", "com.docker.compose.version": "1.21.0" } }, "NetworkSettings": { "Bridge": "", "SandboxID": "071bfe1175fbb2291a24076faec8150f8c53b5c65fc24283e6f78f3620f8fd8b", "HairpinMode": false, "LinkLocalIPv6Address": "", "LinkLocalIPv6PrefixLen": 0, "Ports": { "53/tcp": [ { "HostIp": "192.168.1.3", "HostPort": "53" } ], "53/udp": [ { "HostIp": "192.168.1.3", "HostPort": "53" } ] }, "SandboxKey": "/var/run/docker/netns/071bfe1175fb", "SecondaryIPAddresses": null, "SecondaryIPv6Addresses": null, "EndpointID": "", "Gateway": "", "GlobalIPv6Address": "", "GlobalIPv6PrefixLen": 0, "IPAddress": "", "IPPrefixLen": 0, "IPv6Gateway": "", "MacAddress": "", "Networks": { "lancache-rpi_default": { "IPAMConfig": null, "Links": null, "Aliases": [ "dns", "1ff294099a3d" ], "NetworkID": "bf4412b4b753a8471e6a5710a5ac6910dcbe09137ca2cfc0266577481d7fcf7b", "EndpointID": "60d204e55661c93ced6262b6eec667f465ced5283e36d491a804c5dca026b55e", "Gateway": "172.18.0.1", "IPAddress": "172.18.0.3", "IPPrefixLen": 16, "IPv6Gateway": "", "GlobalIPv6Address": "", "GlobalIPv6PrefixLen": 0, "MacAddress": "02:42:ac:12:00:03", "DriverOpts": null } } } } ]
Weird. The
docker-compose.yml
hasrestart: always
set for each container. What is the output ofdocker inspect lancache-rpi_dns_1
?
Yep and that should be enough.
I was unable to recreate the issue on a recent version of Manjaro on the Raspberry Pi. After rebooting all the containers came up.
I guess we could make a little workaround script that runs on a systemd timer, which parses the docker ps -a
output. If any of the lancache containers aren't running, do a docker-compose restart
The RPi that I have with the issue is using 5.10.52-v71+ and it looks like a Ubuntu compile for RPi (Ubuntu/Linaro 8.4.0-3Ubuntu1) I can try a RPiOS 32 bit version and see if it has the same problem.
Edit: I tried the current RPiOS 32bit version (7th of May 2021) and the error does not occur on this build. 5.10.52-v7l+ #1441 SMP Tue Aug 3 18:11:56 BST 2021 armv7l GNU/Linux
The above issue does exist on Ubuntu 21.04 Server for RPi. Linux version 5.11.0-1015-raspi (buildd@bos02-arm64-044) (gcc (Ubuntu 10.3.0-1ubuntu1)
I've updated the container since they changed the upstream dockerfile.
When I restart the rpi and from terminal I check docker stats with "docker stat", it shows only "lancache monolithic" (and the cache not work). If I do a docker-compose up -d all works fine. What could be the problem?