`lxc exec` hangs - how to troubleshoot? #764

Closed
techtonik opened this Issue Jun 14, 2015 · 12 comments

Comments

Projects
None yet
4 participants
Contributor

techtonik commented Jun 14, 2015

I've initialized container and trying to apt-get install stuff into it making snapshots on the way. Sometimes the lxc exec contain -- apt-get install git just hangs with no output and not responding to Ctrl-C etc. How to figure out what happens?

Member

tych0 commented Jun 15, 2015

On Sun, Jun 14, 2015 at 12:32:56PM -0700, anatoly techtonik wrote:

I've initialized container and trying to apt-get install stuff into it making snapshots on the way. Sometimes the lxc exec contain -- apt-get install git just hangs with no output and not responding to Ctrl-C etc. How to figure out what happens?

I think this was just fixed with
cf71a22, if you build with that it
should work.

Tycho


Reply to this email directly or view it on GitHub:
#764

Owner

stgraber commented Jun 15, 2015

Are you running with Go 1.4 by any chance?

Owner

stgraber commented Jun 15, 2015

@tych0 my commit indeed fixes a race in there, though we still have the problem that multi-threaded unix communication seem to be busted on Go 1.4 for some reason.

@stgraber stgraber added the Bug label Jun 15, 2015

@stgraber stgraber added this to the lxd-0.12 milestone Jun 15, 2015

Contributor

techtonik commented Jun 16, 2015

@stgraber strange thing. go version shows go version xgcc (Ubuntu 4.9.1-0ubuntu1) 4.9.1 linux/386. I don't know which version of Go lang is this.

Owner

stgraber commented Jun 16, 2015

Oh, looks like you're running gccgo then instead of golang-go. That version is 1.4 from gccgo.

I'd recommend you uninstall any gccgo.* package from your system and instead install golang-go. That compiler tends to be better on x86, especially for memory consumption.

For our own packages we only use gccgo for architectures which golang-go doesn't support, so currently arm64, powerpc and ppc64el.

Contributor

techtonik commented Jun 16, 2015

gccgo-go is the only alternative that is proposed for missing go binary. Should it be fixed?

Contributor

techtonik commented Jun 16, 2015

But it seems irrelevant. I removed gccgo.* and LXC still works. I am using LXC from PPA.

Owner

stgraber commented Jun 16, 2015

Odd, here I definitely have golang-go providing the go command.

Contributor

techtonik commented Jun 16, 2015

Why odd? LXC is compiled into binary and doesn't need go, no?

As for proposal, filled https://bugs.launchpad.net/ubuntu/+source/command-not-found/+bug/1465705

Owner

stgraber commented Jun 16, 2015

I was referring to the fact that gccgo-go is the only alternative for go. That shouldn't be the case as golang-go also provides it.

rcj4747 commented Jun 17, 2015

I've build from 3efd3a1 and recreated on vivid. My very temporary solution (which still occasionally fails) is:

sudo systemctl restart lxd
sleep 1
lxc stop vivid
sleep 1
lxc start vivid
sleep 1
lxc exec vivid /bin/bash

I build with golang-go in vivid per the instructions in README.md.

Owner

stgraber commented Jun 22, 2015

The fix for this was pushed last week but the issue wasn't closed. Doing so now.

@stgraber stgraber closed this Jun 22, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment