rancher/os

system-docker container logs

ohauer opened this issue · 2 comments

RancherOS Version: (ros os version)
v1.5.5

I got a corrupt log file for a system-docker container, running system-docker inspect $container shows:
"LogPath": "/var/lib/system-docker/containers/6bbbbe....

My idea was to flush this log, however /var/lib/system-docker does not exist ...
Any hint where I can find the logs for system containers to flush this log before it reach the max size of 25m?

A little late to the party; but having looked for it myself I think it could be useful for others. You can tweak the instructions for loading external driver modules found under the loading kernel modules docs to get access to the folder:

[rancher@Rancher ~]$ sudo system-docker run --rm -it --entrypoint bash --privileged \
-v /var:/host/var -v $(pwd):/data -w /data rancher/os-console:v1.5.4

Obviously changing the version for the version number you have. You can then access system-docker under /host/var/lib/system-docker

Thanks