kata-containers/agent

Could not create destination mount point: /etc/resolv.conf

keloyang opened this issue · 0 comments

docker can' t start a kata container, error is the fowllong,

[root@centos1 ~]# docker run --rm -ti --runtime kata-runtime  busybox ash
docker: Error response from daemon: OCI runtime create failed: rpc error: code = Internal desc = Could not create destination mount point: /etc/resolv.conf: open /etc/resolv.conf: read-only file system: unknown.

kata-containers/osbuilder#366 have a check for /etc/resolv.conf and create if it is not exist.
but sometimes, I only update kata-agent, not the entire rootfs, and don't run osbuilder/rootfs-builder/rootfs.sh again. so /etc/resolv.conf is not exist in rootfs, at last , it causes the container to fail to run.