Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot start container on boot2docker #2

Closed
fastnsilver opened this issue Jul 18, 2014 · 10 comments
Closed

Cannot start container on boot2docker #2

fastnsilver opened this issue Jul 18, 2014 · 10 comments

Comments

@fastnsilver
Copy link

I'm running Windows 7.
I downloaded and installed boot2docker 1.1.1.
I executed boot2docker ssh
I pulled your image with
docker pull

Next is a series of commands and output

docker@boot2docker:/devbox/sts$ docker version
Client version: 1.0.1
Client API version: 1.12
Go version (client): go1.2.1
Git commit (client): 990021a
Server version: 1.0.1
Server API version: 1.12
Go version (server): go1.2.1
Git commit (server): 990021a
docker@boot2docker:
/devbox/sts$ docker images
REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE
fans/sts-base latest c09dbe15c9d7 About an hour ago 1.936 GB
centos centos7 1a7dc42f78ba 9 days ago 236.4 MB
centos latest 1a7dc42f78ba 9 days ago 236.4 MB
svendowideit/samba latest 06d5f1237cf3 9 days ago 273.7 MB
ubuntu 12.04 ea7d6801c538 3 weeks ago 127.5 MB
phusion/baseimage latest dabfc8a44cb5 3 weeks ago 421.6 MB
ubuntu latest e54ca5efa2e9 4 weeks ago 276.5 MB
busybox latest a9eb17255234 6 weeks ago 2.433 MB
dorowu/ubuntu-desktop-lxde-vnc latest 15b04390c9f1 7 weeks ago 858.9 MB
docker@boot2docker:/devbox/sts$ docker run -t -i -p 6080:6080 15b04390c9f1
2014/07/18 22:58:11 Error response from daemon: Cannot start container 1e7b0c0f66678c3a23117d5c90561ff56ed21e7be9af4edcbdf43545460f613b: /mnt/sda1/var/lib/docker/aufs/mnt/1e7b0c0f66678c3a23117d5c90561
ff56ed21e7be9af4edcbdf43545460f613b is not within /mnt/sda1/var/lib/docker/aufs/mnt/1e7b0c0f66678c3a23117d5c90561ff56ed21e7be9af4edcbdf43545460f613b
docker@boot2docker:
/devbox/sts$ docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
1e7b0c0f6667 dorowu/ubuntu-desktop-lxde-vnc:latest /startup.sh 4 seconds ago sick_bohr
6bd235b0c6ea dorowu/ubuntu-desktop-lxde-vnc:latest /startup.sh 21 minutes ago romantic_poincare
44c5bcacd4d5 fans/sts-base:latest /startup.sh /sbin/my About an hour ago hungry_euclid
866aa3d16904 busybox:latest echo test About an hour ago Exited (0) About an hour ago sick_hoover
docker@boot2docker:~/devbox/sts$

Can you explain why I'm getting an error on startup? Is this a bug in boot2docker? Should I even attempt to run docker under boot2docker?

@fcwu
Copy link
Owner

fcwu commented Jul 21, 2014

Is the command "docker run -i -t -p 11111 ubuntu:12.04 /bin/bash" successfully?

@fastnsilver
Copy link
Author

Seems when I installed boot2docker 1.1.1 over an existing 1.0.1 installation things got funky. I completely removed all traces of boot2docker and re-installed 1.1.1. Next I used docker pull to fetch your container from docker hub registry. Finally I tried to start up. This is what I saw...

docker@boot2docker:~$ docker run -i -t -p 6080:6080 dorowu/ubuntu-desktop-lxde-vnc
User: ubuntu Pass: ubuntu
root@209cf4173993:/# ls -la
total 17316
drwxr-xr-x 106 root root 4096 Jul 21 13:09 .
drwxr-xr-x 106 root root 4096 Jul 21 13:09 ..
-rwxr-xr-x 1 root root 0 Jul 21 13:09 .dockerenv
-rwx------ 1 root root 17636373 Jul 21 13:02 .dockerinit
drwxr-xr-x 2 root root 4096 May 30 02:12 bin
drwxr-xr-x 2 root root 4096 Apr 10 22:12 boot
drwxr-xr-x 4 root root 360 Jul 21 13:09 dev
drwxr-xr-x 105 root root 4096 Jul 21 13:09 etc
drwxr-xr-x 3 root root 4096 Jul 21 13:09 home
drwxr-xr-x 15 root root 4096 Jul 21 13:04 lib
drwxr-xr-x 2 root root 4096 Apr 16 20:35 lib64
drwxr-xr-x 2 root root 4096 Apr 16 20:35 media
drwxr-xr-x 2 root root 4096 Apr 10 22:12 mnt
drwxr-xr-x 9 root root 4096 Jul 21 13:09 noVNC
drwxr-xr-x 2 root root 4096 Apr 16 20:35 opt
dr-xr-xr-x 174 root root 0 Jul 21 13:09 proc
drwx------ 2 root root 4096 Apr 16 20:36 root
drwxr-xr-x 9 root root 4096 Jul 21 13:09 run
drwxr-xr-x 2 root root 4096 May 30 02:12 sbin
drwxr-xr-x 2 root root 4096 Apr 16 20:35 srv
-rwxr-xr-x 1 root root 315 May 30 01:56 startup.sh
-rw-r--r-- 1 root root 1083 May 30 01:56 supervisord.conf
-rw-r--r-- 1 root root 1111 Jul 21 13:09 supervisord.log
-rw-r--r-- 1 root root 3 Jul 21 13:09 supervisord.pid
dr-xr-xr-x 13 root root 0 Jul 21 13:09 sys
drwxrwxrwt 4 root root 4096 Jul 21 13:09 tmp
drwxr-xr-x 22 root root 4096 Jul 21 13:08 usr
drwxr-xr-x 27 root root 4096 Jul 21 13:09 var
root@209cf4173993:/#

Great I thought. Let me try to hit w/ browser from my desktop.

Opened Firefox and browsed to http://127.0.0.1:6080/vnc.html

Nothing!

boot2docker does not make any other port but 22 available.

But, a look here, gave me what I needed...

https://github.com/boot2docker/boot2docker/blob/master/doc/WORKAROUNDS.md

So I Iaunched boot2docker w/

boot2docker ssh -L 6080:localhost:6080

and then I was able to visit http://127.0.0.1:6080/vnc.html, authenticate, and work with container.

Thanks!

(Just a thought... you might want to enhance your instructions to point the above out).

@fcwu fcwu closed this as completed Aug 12, 2014
@ghost
Copy link

ghost commented Oct 21, 2014

Thank you for reporting the solution! 👍 helped a lot!

@robertoandrade
Copy link

Another way would be to simply use the boot2docker ip instead of your localhost one:

$ open http://$(boot2docker ip):6080/vnc.html

@maderluc
Copy link

maderluc commented Dec 4, 2017

Hi, im trying to "su" to root user, but i dont see where the passwort for root is given! how can i get root access?

@fcwu
Copy link
Owner

fcwu commented Dec 5, 2017

Please use sudo. Default password is "ubuntu"

@maderluc
Copy link

maderluc commented Dec 5, 2017

Thanks Works perfect!!

@maderluc
Copy link

maderluc commented Dec 6, 2017

Hi, i want to change the password of the "ubuntu" user and the changes should be persistent after stopping the container. Can I change the default user to another one? I want to mount a drive from the Host, but i can only set a mountpoint by creating a new instance, do you know how i can customise that with a running container?

@xunhs
Copy link

xunhs commented Nov 9, 2019

Hi, excuse me. I run it successfuly in my computer, but when i close the web tab, after some minutes i reopen the url, the running programme (Baiduyunpan for linux) is closed and i sound reopen it. How could i close the web tab but remain programes running?
Thanks.

@alexstar55
Copy link

Hi, how to run gazebo in container generated by this image please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants