<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Wed, Dec 2, 2015 at 9:49 PM, Peter Steele <span dir="ltr"><<a href="mailto:pwsteele@gmail.com" target="_blank">pwsteele@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"><span class="">
On 12/01/2015 08:25 PM, Fajar A. Nugraha wrote:<br>
<blockquote type="cite">
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote">Is there a reason why you can't
install a centos7 container using the download template? It
would've been MUCH easier, and some of the things you asked
wouldn't even be an issue.</div>
</div>
</div>
</blockquote></span><br>
So, that long winded answer is why we can't just use the LXC
template for CentOS directly. I was assuming (hoping) that the
libvirt container image we build would be largely LXC friendly.
Apparently it's not going to be quite as straightforward as I'd
hoped. I'm going to have to dissect the steps used for creating a
CentOS LXC template and make sure our container image provides what
is needed/expected by LXC.</div></blockquote><div><br></div><div><br></div><div>Actually my point was about the config file :)</div><div><br></div><div>The rootfs should be OK as is, as any systemd-related problem inside the container should've also been fixed if you've managed to run it under libvirt. I was suggesting to create a centos7 container from the download template (which would reference the common configs, and use lxcfs), then copy its config file.</div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div bgcolor="#FFFFFF" text="#000000"><span class=""><br>
<blockquote type="cite">
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote">
<div> </div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">My
containers are coming up but things are running really
slowly, although CPU usage is low. I'm not entirely sure
what's going on and need to do some more digging.<br>
<br>
</blockquote>
<div><br>
</div>
<div>Works for me. However I seem to recall an issue with
centos' version of systemd sometime ago.</div>
<div><br>
</div>
</div>
</div>
</div>
</blockquote></span>
Yes, I hit that systemd issue early on and found the fix for it. The
slowness I'm seeing now is something else.<span class=""><br>
<blockquote type="cite">
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><br>
whereas under LXC /dev has the following:<br>
</blockquote>
<div> </div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><br>
I know how to trim the /dev/ttyN entries to match libvirt,
but I'm not sure what's needed for the others. For
example, how do I get rid of /dev/snd?
<div>
<div><br>
</div>
</div>
</blockquote>
<div><br>
</div>
<div>Here's mine. Centos 7 container, ubuntu 14.04 host,
lxc-1.1.4 and lxcfs-0.10 from ubuntu ppa:</div>
<div><br>
</div>
<div>
<div>c7 / # ls /dev</div>
<div>console core fd full hugepages initctl log lxc
mqueue null ptmx pts random shm stderr stdin
stdout tty tty1 tty2 tty3 tty4 urandom zero</div>
</div>
<div><br>
</div>
<br>
</div>
</div>
</div>
</blockquote></span>
That ultimately is very similar to my libvirt dev list. I clearly
need to dig into the CentOS template to see what's being done
differently compared to my libvirt image.<span class=""><font color="#888888"><br>
<br></font></span></div></blockquote><div><br></div><div><br></div><div>It occurs to me that the difference might be related to lxcfs. It provides a private, customized copy of parts of /sys and /proc to the container, so the container doesn't need to see what the host has. And IIRC libvirt has something that functions similarly to lxcfs.</div><div><br></div><div>Do you also have lxcfs installed? What version of lxc are you using? </div><div>Try installing lxcfs and use lxc-1.1.x. Then try to install a new container using download template to see if it's similar to what you want. If it is, copy it's config file (and modify things like name and paths, obviously) for your former-libvirt container.</div><div><br></div><div>-- </div><div>Fajar</div></div></div></div>