美文网首页
ubuntu snap docker服务器断电启动失败

ubuntu snap docker服务器断电启动失败

作者: yuerumylove | 来源:发表于2020-11-21 12:10 被阅读0次

    使用snap在ubuntu上安装docker。某次异常断电之后,docker异常无法重启,查看系统日志:

    Nov 21 11:30:27 uascent-local kernel: aufs aufs_fill_super:912:mount[24769]: no arg
    Nov 21 11:30:27 uascent-local kernel: overlayfs: missing 'lowerdir'
    Nov 21 11:30:31 uascent-local sudo[24797]: flighter : TTY=pts/2 ; PWD=/home/flighter/snap/docker ; USER=root ; COMMAND=/bin/systemctl restart docker
    Nov 21 11:30:31 uascent-local sudo[24797]: pam_unix(sudo:session): session opened for user root by flighter(uid=0)
    Nov 21 11:30:31 uascent-local sudo[24797]: pam_unix(sudo:session): session closed for user root
    Nov 21 11:30:39 uascent-local sudo[24802]: flighter : TTY=pts/2 ; PWD=/home/flighter/snap/docker ; USER=root ; COMMAND=/usr/bin/apt-get install docker
    Nov 21 11:30:39 uascent-local sudo[24802]: pam_unix(sudo:session): session opened for user root by flighter(uid=0)
    Nov 21 11:30:40 uascent-local sudo[24802]: pam_unix(sudo:session): session closed for user root
    Nov 21 11:30:42 uascent-local docker.dockerd[24731]: failed to start containerd: timeout waiting for containerd to start
    Nov 21 11:30:42 uascent-local systemd[1]: snap.docker.dockerd.service: Main process exited, code=exited, status=1/FAILURE
    Nov 21 11:30:42 uascent-local systemd[1]: snap.docker.dockerd.service: Failed with result 'exit-code'.
    Nov 21 11:30:43 uascent-local systemd[1]: snap.docker.dockerd.service: Service hold-off time over, scheduling restart.
    Nov 21 11:30:43 uascent-local systemd[1]: snap.docker.dockerd.service: Scheduled restart job, restart counter is at 35.
    Nov 21 11:30:43 uascent-local systemd[1]: Stopped Service for snap application docker.dockerd.
    

    aufs异常:

    Nov 21 11:30:27 uascent-local kernel: aufs aufs_fill_super:912:mount[24769]: no arg
    Nov 21 11:30:27 uascent-local kernel: overlayfs: missing 'lowerdir'
    

    参考google:

    https://docs.google.com/document/d/1JHa6tkuR9PtpnAVVmAJIAKuyKBy8E9ZkvG5Wbc6HZSY/edit#

    Docker.compose is used to run docker-compose in series 16. A docker-compose snap would allow using the docker-compose name. Docker and docker-compose snaps could be kept in sync via assertions, however it’s not clear how we’d pull docker when docker-compose gets pulled – perhaps we don’t need to. Generally, docker-compose is supposed to work with older docker versions so that shouldn’t be much of an issue.
    Aufs warnings on startup
    ubuntu@localhost:~$ sudo snap install --devmode --channel=edge docker
    16.11 MB / 16.36 MB [=====================================>_] 98.44 % 2.53 MB/s

    docker (edge) 1.11.2-1 from 'canonical' installed
    ubuntu@localhost:~$ [ 68.915607] aufs aufs_fill_super:906:mount[2117]: no arg
    [ 69.006572] overlayfs: missing 'lowerdir'
    [ 71.986169] aufs aufs_fill_super:906:mount[2163]: no arg
    These warnings are normal and nothing to worry about. However, if the warnings are repeated, this indicates an issue starting the daemon (typically because required modules can’t be loaded or because the docker group is missing).

    根本原因是因为containerd没有正常停止,删除 containerd的 pid文件即可

    rm -rf /var/snap/docker/471/run/docker/containerd/containerd.pid
    

    相关文章

      网友评论

          本文标题:ubuntu snap docker服务器断电启动失败

          本文链接:https://www.haomeiwen.com/subject/cqnsiktx.html