jlmontes
jlmontes

Reputation: 61

Docker 1.0 CentOS 6.5 “unable to mount sys as readonly” when running image

$ sudo docker run -i -t centos /bin/bash

Get the following error message:

2014/06/19 20:40:34 unable to remount sys readonly: unable to mount sys as readonly max retries reached

Added the the following parameter to /etc/sysconfig/docker and restarted the service (sudo service docker restart)

other_args="--exec-driver=lxc"

My /etc/sysconfig/docker looks like this (the --selinux-enabled was already in there before)

other_args="--exec-driver=lxc" other_args="--selinux-enabled"

Upvotes: 5

Views: 3746

Answers (2)

user3759460
user3759460

Reputation: 101

your /etc/sysconfig/docker needs to look like this:

other_args="--exec-driver=lxc --selinux-enabled"

otherwise it will not work.

Upvotes: 10

user3767301
user3767301

Reputation: 11

I also see this when I upgraded to 1.0 from 0.11 on RHEL 6.5

--selinux was already set in /etc/sysconfig/docker and I had to set --exec-driver=lxc for conatainers to started working again.

Upvotes: 1

Related Questions