nlf / dlite

The simplest way to use Docker on OS X
MIT License
2.34k stars 54 forks source link

dlite starts, but "docker images" hangs #160

Closed synic closed 8 years ago

synic commented 8 years ago

I can start dlite just fine, and I can type dlite ssh, and it asks me for a password.

I can type screen /dev/ttys000 and log in as root.

/etc/hosts has the correct entry:

# begin dlite
192.168.64.4 local.docker
# end dlite

But when I type docker images, it just hangs forever.

If I stop dlite, it stops fine, but if I try to start it again, it just says Starting the agent: forever, and never goes beyond that unless I kill all dlite instances.

Everything looks normal:

[~]$ ls -lh /var/run/docker.sock
srwxrwxrwx 1 root daemon 0 Apr  4 13:10 /var/run/docker.sock
[~]$ dlite ip
192.168.64.4
[~]$

OS X firewall is off (and I have rebooted)

nlf commented 8 years ago

the stop/start commands behaving oddly are because the ssh setup failed, that's also why dlite ssh doesn't work directly for you.

the beta of 2.0.0 is still a bit buggy in a few areas, but i do have some fixes in the works.

my suggestion would be once your logged in, run cat /var/log/docker.log and see if there are any errors listed there that can give us a hint as to why docker's failing. also if you haven't already, see if the docker images command works while you're in the virtual machine

synic commented 8 years ago

Docker daemon isn't running. I see this in the logs:

# cat /var/log/docker.log
time="2016-04-04T19:10:35.152409365Z" level=warning msg="/!\\ DON'T BIND ON ANY IP ADDRESS WITHOUT setting -tlsverify IF YOU DON'T KNOW WHAT YOU'RE DOING /!\\"
time="2016-04-04T19:10:35.152702663Z" level=fatal msg="Error starting daemon: error initializing graphdriver: prerequisites for driver not satisfied (wrong filesystem?)"
nlf commented 8 years ago

sounds like your disk image didn't build correctly. try shutting it down and running dlite rebuild and then start it back up and try again

synic commented 8 years ago
ata5: DUMMY
ata6: DUMMY
tun: Universal TUN/TAP device driver, 1.6
tun: (C) 1999-2004 Max Krasnyansky <maxk@qualcomm.com>
rtc_cmos rtc_cmos: rtc core: registered rtc_cmos as rtc0
rtc_cmos rtc_cmos: alarms up to one day, 114 bytes nvram
device-mapper: ioctl: 4.33.0-ioctl (2015-8-18) initialised: dm-devel@redhat.com
ledtrig-cpu: registered to indicate activity on CPUs
Netfilter messages via NETLINK v0.30.
nfnl_acct: registering with nfnetlink.
ip_tables: (C) 2000-2006 Netfilter Core Team
Initializing XFRM netlink socket
NET: Registered protocol family 17
NET: Registered protocol family 15
Key type dns_resolver registered
AVX2 version of gcm_enc/dec engaged.
AES CTR mode by8 optimization enabled
registered taskstats version 1
Btrfs loaded
Key type encrypted registered
rtc_cmos rtc_cmos: setting system clock to 2016-04-04 19:17:52 UTC (1459797472)
ata1: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
ata1.00: READ LOG DMA EXT failed, trying unqueued
ata1.00: ATA-9: BHYVE SATA DISK, 001, max UDMA/133
ata1.00: 41943040 sectors, multi 128: LBA48 NCQ (depth 31/32)
ata1.00: configured for UDMA/133
scsi 0:0:0:0: Direct-Access     ATA      BHYVE SATA DISK  001  PQ: 0 ANSI: 5
Freeing unused kernel memory: 896K (ffffffff81902000 - ffffffff819e2000)
Write protecting the kernel read-only data: 8192k
Freeing unused kernel memory: 1124K (ffff8800014e7000 - ffff880001600000)
Freeing unused kernel memory: 72K (ffff8800017ee000 - ffff880001800000)
Starting logging: OK
Starting acpid: OK
Automounting: OK
Initializing random number generator... random: dd urandom read with 2 bits of entropy available
done.
Starting rpcbind: NET: Registered protocol family 10
OK
Setting hostname:DONE
Starting network...
udhcpc: option -h NAME is deprecated, use -x hostname:NAME
udhcpc (v1.24.1) started
Sending discover...
Sending select for 192.168.64.4...
Lease of 192.168.64.4 obtained, lease time 85536
deleting routers
adding dns 192.168.64.1
Mounting NFS share:clocksource: tsc: mask: 0xffffffffffffffff max_cycles: 0x2cad505ea80, max_idle_ns: 440795360394 ns
clocksource: Switched to clocksource tsc
mount: mounting 192.168.64.1:/Users on /Users failed: Permission denied
OK
Starting dropbear sshd: OK
Starting docker: OK
Configuring sysctl: OK
Starting crond: OK
Starting NFS statd: done
Starting NFS services: exportfs: can't open /run/nfs/xtab for reading
done
Starting NFS daemon: rpc.nfsd: Unable to access /proc/fs/nfsd errno 2 (No such file or directory).
Please try, as root, 'mount -t nfsd nfsd /proc/fs/nfsd' and then restart rpc.nfsd to correct the problem
done
Starting NFS mountd: done
nlf commented 8 years ago

what version of dlite are you running?

synic commented 8 years ago

2.0.0-beta5

nlf commented 8 years ago

it trying to start nfs sounds like it got the wrong version of the OS. shut everything down and dlite update -v 3.0.0-beta4; dlite rebuild and try again

synic commented 8 years ago

Seems like it's working now :D Thanks!

nlf commented 8 years ago

great :)

AlexMikhalev commented 8 years ago

Bump! I spend several hours before finding this solution. I hope fix will make it into production.