Bug 1130499

Summary: Include nsinit binary from libcontainer in RHEL to enhance container debugging capabilities
Product: Red Hat Enterprise Linux 7 Reporter: Jeremy Eder <jeder>
Component: dockerAssignee: Daniel Walsh <dwalsh>
Status: CLOSED WONTFIX QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1CC: dwalsh, lsm5, vbatts
Target Milestone: rcKeywords: Extras
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-01-27 03:31:05 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1070851    

Description Jeremy Eder 2014-08-15 12:38:47 UTC
Description of problem:
See https://bugzilla.redhat.com/show_bug.cgi?id=1111916

(In reply to Vincent Batts from comment #1)
> and github.com/codegangsta/cli when we decide to start building `nsinit`

Look at all this glorious data:
http://perf1.perf.lab.eng.bos.redhat.com/jeder/docker/nsinit/nsinit-stats.out
http://perf1.perf.lab.eng.bos.redhat.com/jeder/docker/nsinit/nsinit-config.out

I'd imagine any customer looking for per-container statistics would strongly prefer a utility rather than spelunking through /sys/fs/cgroups and /sys/class/net to glue it all together.

In the end it would be nicer to have 'docker stats/config <CONTAINER_ID>', but in lieu of that, is any reason we're not building and shipping nsinit ?

The build/inclusion of nsinit in Fedora is complete via BZ1111916, and nsinit is in

$ rpm -ql golang-github-docker-libcontainer
/usr/bin/nsinit
/usr/share/doc/golang-github-docker-libcontainer
/usr/share/doc/golang-github-docker-libcontainer/LICENSE

But, 'nsinit stats' actually doesn't work on Fedora at the moment because it can't find the memory cgroup due to the way we've wired up systemd.  A very old version of nsinit was built for Fedora, and I'm not sure why.  Head of libcontainer git nsinit works fine on RHEL7.

I thought for RHEL7, nsinit should be included in the docker RPM itself...

Comment 1 Jeremy Eder 2014-08-15 12:45:11 UTC
Just want to make sure we pick up the latest for RHEL7:

https://bugzilla.redhat.com/show_bug.cgi?id=1130500

Comment 3 Lokesh Mandvekar 2014-08-15 20:20:08 UTC
There was an issue filed on github to include nsinit in the main docker repo itself, though I can't seem to find it atm. Dan, Vincent do you happen to know what was the outcome of that?

Comment 4 Lokesh Mandvekar 2014-08-15 20:24:01 UTC
hmm here it is: https://github.com/docker/docker/pull/7248 ... Closed atm.

Comment 5 Lokesh Mandvekar 2014-08-15 20:39:02 UTC
RHEL7 would need the golang-github-docker-libcontainer package included (since it's technically a separate repo now) unless we choose to build and install libcontainer and nsinit from within the vendor dir in docker (which would be way more convenient). The latter approach might be trouble in case docker and libcontainer updates are not in sync (but I could be wrong here).

Thoughts?

Comment 6 Daniel Walsh 2014-08-16 09:28:34 UTC
I would say we ship them together.  Hopefully eventually docker stats or some such call gets developed, but for now I think we should ship them together.

Comment 7 Daniel Walsh 2014-09-12 18:46:02 UTC
Fixed in docker-1.2