[Lxc-users] use libvirt-bin in lxc

Serge Hallyn serge.hallyn at canonical.com
Mon Oct 1 12:50:18 UTC 2012


Quoting 宣铭艺 (xuanmingyi at gmail.com):
> can we use libvirt-bin in lxc???

Yes, you can.  The failures you show are due to your apparmor policy
not allowing mounting of cgroups in the containers.  You can create a
new policy for your containers allowing just the permissions you need,
or (not recommended long term) simply make the containers unconfined
using the line

lxc.aa_profile = unconfined

in the container config.

-serge

> the output:
> 
> root at ubuntu:~# apt-get install libvirt-bin
> Reading package lists... Done
> Building dependency tree
> Reading state information... Done
> libvirt-bin is already the newest version.
> 0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.
> 2 not fully installed or removed.
> After this operation, 0 B of additional disk space will be used.
> Do you want to continue [Y/n]? y
> Setting up cgroup-bin (0.37.1-1ubuntu10) ...
> Loading configuration file /etc/cgconfig.conf failed
> Cgroup mounting failed
> start: Job failed to start
> invoke-rc.d: initscript cgconfig, action "start" failed.
> dpkg: error processing cgroup-bin (--configure):
>  subprocess installed post-installation script returned error exit status 1
> dpkg: dependency problems prevent configuration of libvirt-bin:
>  libvirt-bin depends on cgroup-lite | cgroup-bin; however:
>   Package cgroup-lite is not installed.
>   Package cgroup-bin is not configured yet.
> dpkg: error processing libvirt-bin (--configure):
>  dependency problems - leaving unconfigured
> No apport report written because the error message indicates its a followup
> error from a previous failure.
> Errors were encountered while processing:
>  cgroup-bin
>  libvirt-bin
> E: Sub-process /usr/bin/dpkg returned an error code (1)
> root at ubuntu:~#
> 
> 
> -- 
> 樱宝宝: http://www.xuanmingyi.com

> ------------------------------------------------------------------------------
> How fast is your code?
> 3 out of 4 devs don\\\'t know how their code performs in production.
> Find out how slow your code is with AppDynamics Lite.
> http://ad.doubleclick.net/clk;262219672;13503038;z?
> http://info.appdynamics.com/FreeJavaPerformanceDownload.html

> _______________________________________________
> Lxc-users mailing list
> Lxc-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/lxc-users





More information about the lxc-users mailing list