解决 DOCKER RUN :MOUNTPOINT FOR DEVICES NOT FOUND

老的JenkinsCI(CentOS 6.x)在运行docker的时候,忽然提示 “mountpoint for devices not found“.

官方的描述里,这个应该是和Cgroup有关的问题。

官方提供的环境检查的脚本,可以运行看看:

https://github.com/docker/docker/blob/master/contrib/check-config.sh

看看是不是所有的配置都已经ok了。

如果是运行库缺失,参考

http://stackoverflow.com/questions/24396071/docker-error-mountpoint-not-found

进行修复。

如果前面几个步骤都没有发现问题,则可以看看Cgroup 的Mount是否有问题。

使用

mount -a

查看mount列表内是否有

cgroup on /sys/fs/cgroup type tmpfs (rw,uid=0,gid=0,mode=0755)

如果这个没有挂载,则会导致mount point for devices not found.

有两种方式可以挂载这个mountpoint,一个是在fstab死写,一个是用一个脚本动态挂载。

https://github.com/tianon/cgroupfs-mount/blob/master/cgroupfs-mount

Last modification:August 14th, 2017 at 10:20 pm
If you think my article is useful to you, please feel free to appreciate

Leave a Comment