ubuntu - Device or resource busy - Docker -


when doing apt-get -y upgrade on new ubuntu 14.04 machine ubuntu:latest (xenial) image, raised error:

setting makedev (2.3.1-93ubuntu2~ubuntu16.04.1) ... mv: cannot move 'console-' 'console': device or resource busy makedev console c 5 1 root tty 0600: failed 

i've fresh install of docker on fresh ubuntu 14.04, using these command:

sudo apt-get remove docker docker-engine sudo apt-get update sudo apt-get install linux-image-extra-$(uname -r) linux-image-extra-virtual wget -qo- https://get.docker.com/ | sudo sh su - $user # logout , login 

docker hello-world runs fine:

$ docker run hello-world unable find image 'hello-world:latest' locally latest: pulling library/hello-world 78445dd45222: pull complete  digest: sha256:c5515758d4c5e1e838e9cd307f6c6a0d620b5e07e6f927b07d05f6d12a1ac8d7 status: downloaded newer image hello-world:latest  hello docker! message shows installation appears working correctly.  generate message, docker took following steps:  1. docker client contacted docker daemon.  2. docker daemon pulled "hello-world" image docker hub.  3. docker daemon created new container image runs     executable produces output reading.  4. docker daemon streamed output docker client, sent     terminal.  try more ambitious, can run ubuntu container with:  $ docker run -it ubuntu bash  share images, automate workflows, , more free docker id:  https://cloud.docker.com/  more examples , ideas, visit:  https://docs.docker.com/engine/userguide/ 

when create empty docker container with:

docker run -it ubuntu bash 

and ran following:

apt-get update apt-get install -y debconf-utils echo 'debconf debconf/frontend select noninteractive' | debconf-set-selections apt-get update apt-get -y upgrade 

the error:

setting makedev (2.3.1-93ubuntu2~ubuntu16.04.1) ... mv: cannot move 'console-' 'console': device or resource busy makedev console c 5 1 root tty 0600: failed 

is raised when doing last apt-get -y upgrade

the full docker log on: https://gist.github.com/alvations/ebe7175b984213d6f64a3c779ba3249e

agree other answers/comments apt-get -y upgrade isn't idea pulling newer/updated image. particular package required out of date in image, installing particular package enough (since dependencies updated necessary).

however, there no reason shouldnt able use apt-get -y upgrade , in fact, i'd consider bug, similar not same as:

https://bugs.launchpad.net/ubuntu/+source/makedev/+bug/1675163

the part failing first call makedev in postinst script handled , script continues. means there no current issue installing makedev. but may not true requires bug raised ubuntu have docker containers detected (somehow).

note: if care makedev ruining docker /dev/ directory or want make sure rid of error condition installing makedev, fix bug linked can used trick postinstall script not running. check in script says:

# don't stomp on lxc users if grep -q container=lxc /proc/1/environ     echo "lxc container detected, aborting due lxc managed /dev."     exit 0 fi 

so if add environment variable name ends in container value lxc, check tripped , no new devices installed

docker run -ti -e "imnotanlxccontainer=lxc" ubuntu 

this cause script exit, not create whole bunch of /dev/ entries, , output message:

setting makedev (2.3.1-93ubuntu2~ubuntu16.04.1) ... lxc container detected, aborting due lxc managed /dev. 

Comments

Popular posts from this blog

Command prompt result in label. Python 2.7 -

javascript - How do I use URL parameters to change link href on page? -

amazon web services - AWS Route53 Trying To Get Site To Resolve To www -