[lxc-devel] lxc + gento + qemu, almost there
Stéphane Graber
stgraber at ubuntu.com
Tue Mar 10 15:49:31 UTC 2015
On Thu, Mar 05, 2015 at 02:28:42PM +0000, Joakim Tjernlund wrote:
> I am running a gentoo ppc stage3 on lxc amd64.
>
> All I needed to do for this to boot was:
> Add to gentoo template
> chroot()
> {
> rr=$1
>
> shift 1
> proot -w / -r "${rr}" -q qemu-ppc "$@"
> }
>
> ppc-qemu.conf:
> lxc.network.type = veth
> lxc.network.link = virbr0
> lxc.network.flags = up
> #for user emulation of PPC arch
> lxc.mount.entry=/usr/bin/qemu-ppc usr/bin/qemu-ppc none ro,bind,optional 0 0
>
>
> lxc-create -n cusfpv3 -t gentoo -f /etc/lxc/ppc-qemu.conf -- -a ppc -v ppc
>
> touch /var/lib/lxc/cusfpv3/rootfs/usr/bin/qemu-ppc # create a handle for bind mount
You can avoid that by passing create=file as a mount option in lxc.mount.entry
>
> lxc-start -n cusfpv3
>
> Could this be added to the template?
> Obviously some rework is needed, but I suck at shell programming :(
>
> the new chroot() function should be replaced with a bind mount of /usr/bin/qemu-ppc in ${rootfs}
>
> Jocke
> _______________________________________________
> lxc-devel mailing list
> lxc-devel at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-devel
--
Stéphane Graber
Ubuntu developer
http://www.ubuntu.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20150310/ba46d61c/attachment.sig>
More information about the lxc-devel
mailing list