Re: libvirt-1.0.2 qith lxc and /proc/meminfo

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Mar 04, 2013 at 12:41:39PM +0100, Thierry Parmentelat wrote:
> Hello there
> 
> I'm using libvirt-1.0.2 to spawn off linux containers
> We currently have 2 very similar setups that run on fedora 16 and f18 respectively
> And I'm seeing one weird difference concerning /proc/meminfo
> While everything is fine on the fedora16 world, on the fedora18 side here is what the container sees
> 
> bash-4.2# ls /proc
> ls: cannot access /proc/meminfo: Permission denied
> 1   257        bus       devices      fb           irq        kpagecount     mdstat   net           schedstat  swaps          tty
> 10  377        cgroups   diskstats    filesystems  kallsyms   kpageflags     meminfo  pagetypeinfo  scsi       sys            uptime
> 15  522        cmdline   dma          fs           kcore      latency_stats  misc     partitions    self       sysrq-trigger  version
> 16  542        consoles  dri          interrupts   key-users  loadavg        modules  pidsu         slabinfo   sysvipc        vmallocinfo
> 18  acpi       cpuinfo   driver       iomem        keys       locks          mounts   procprotect   softirqs   timer_list     vmstat
> 19  buddyinfo  crypto    execdomains  ioports      kmsg       lxcsu          mtrr     sched_debug   stat       timer_stats    zoneinfo
> 
> bash-4.2# ls -l /proc | grep meminfo
> ls: cannot access /proc/meminfo: Permission denied
> -?????????  ? ?    ?                  ?            ? meminfo
> 
> bash-4.2# cat /proc/meminfo
> cat: /proc/meminfo: Permission denied

Indeed that looks wrong. I suspect this is probably a bug in the way
libvirt sets up FUSE. Guess we've not set the right permissions on
the meminfo file we bind into the container

> =====
> we rebuild libvirt-1.0.2 more or less as is modulo a few features that are turned off, our specfile can be found here
> http://git.onelab.eu/?p=libvirt.git;a=blob;f=libvirt.spec
> 
> the most obvious difference between both builds lies in using fuse:
> ---
> # fuse is used to provide virtualized /proc for LXC
> %if 0%{?fedora} >= 17 || 0%{?rhel} >= 7
>     %define with_fuse      0%{!?_without_fuse:1}
> %endif
> ---
> 
> I was wondering what exactly should be the requirements on the root context for running this properly
> In particular the fuse rpm was not pulled as part of the libvirt dependencies, which might be an omission ?
> Can I expect my problem to go away if I make sure fuse gets installed ?

We only need the fuse libraries, which are pulled in automatically by
the libvirt-daemon RPMs  \

$ rpm -q libvirt-daemon --requires | grep fuse
libfuse.so.2()(64bit)
libfuse.so.2(FUSE_2.2)(64bit)
libfuse.so.2(FUSE_2.5)(64bit)
libfuse.so.2(FUSE_2.6)(64bit)
libfuse.so.2(FUSE_2.8)(64bit)


Regards,
Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]