安装完Docker后,启动时报错:
[root@localhost /]# systemctl start docker.service
Job for docker.service canceled.
[root@localhost /]# systemctl status docker.service
● docker.service - Docker Application Container Engine
Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since 三 2019-12-04 13:45:42 CST; 11min ago
Docs: https://docs.docker.com
Process: 1591 ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock (code=exited, status=127)
Main PID: 1591 (code=exited, status=127)
12月 04 13:45:42 localhost.localdomain systemd[1]: Starting Docker Application Container Engine...
12月 04 13:45:42 localhost.localdomain dockerd[1591]: /usr/bin/dockerd: error while loading shared libraries: /lib64/libseccom... short
12月 04 13:45:42 localhost.localdomain systemd[1]: docker.service: main process exited, code=exited, status=127/n/a
12月 04 13:45:42 localhost.localdomain systemd[1]: Stopped Docker Application Container Engine.
12月 04 13:45:42 localhost.localdomain systemd[1]: Unit docker.service entered failed state.
12月 04 13:45:42 localhost.localdomain systemd[1]: docker.service failed.
Hint: Some lines were ellipsized, use -l to show in full.
[root@localhost /]# /usr/bin/dockerd
/usr/bin/dockerd: error while loading shared libraries: /lib64/libseccomp.so.2: file too short
解决办法
重新安装提示错误的依赖包即可
yum reinstall libseccomp