From: Giovanni Biscuolo <g@xelera.eu>
To: "Gábor Boskovits" <boskovits@gmail.com>
Cc: help-guix <help-guix@gnu.org>
Subject: Re: "guix system vm" to libvirt XML domain
Date: Fri, 25 Jan 2019 12:21:38 +0100 [thread overview]
Message-ID: <87ftthasot.fsf@roquette.mug.biscuolo.net> (raw)
In-Reply-To: <CAE4v=pgvwU+u8YU4+fKYYOw=OPxCB0Zx+zHfABSg-KTrrG7qrQ@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1570 bytes --]
Hi Gabor,
thanks for your interest
Gábor Boskovits <boskovits@gmail.com> writes:
[...]
>> but now I've a problem with the /gnu/store mount in guest
>>
>> "9pnet_virtio: no channels available for device TAGjoptajej2oynju6yvboauz7pl6uj"
>>
>> ...still missimg someting
>>
>> any hint please?
>>
>
> I have seen this once, and the virtio-pci kernel module was missing.
I had excluded this since starting the VM using the "guix system vm"
generated script succeeds, I expect the libvirt defined one to run alike
long story short: my domain XML definition was *wrong*, I defined the
/gnu/store filesystem
--8<---------------cut here---------------start------------->8---
<filesystem type='mount' accessmode='passthrough'>
<driver type='path' wrpolicy='immediate'/>
<source dir='/gnu/store'/>
<target dir='TAGjoptajej2oynju6yvboauz7pl6uj'/>
</filesystem>
--8<---------------cut here---------------end--------------->8---
in the wrong part of the XML tree, namely outside
--8<---------------cut here---------------start------------->8---
<devices>
[...]
</devices>
--8<---------------cut here---------------end--------------->8---
and virsh ignored it (no error, no warning) when I used that XML to
define the VM via "virsh ... define cointainer-minimal.xml" [1]
hint: always use virsh-xml-validate to check the file, since virsh does
not validate it before registering the definition (AFAIK "virsh define"
also hasn't a proper flag to do it)
this is the correct XML domain definition, now working:
[-- Attachment #2: container-minimal-fixed.xml --]
[-- Type: application/xml, Size: 2431 bytes --]
<domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'>
<name>container-minimal</name>
<uuid>ecfe2538-5315-44aa-bba5-8fe4d86d5397</uuid>
<memory unit='GB'>2</memory>
<currentMemory unit='GB'>2</currentMemory>
<vcpu placement='static'>2</vcpu>
<os>
<type arch='x86_64' machine='pc-i440fx-2.8'>hvm</type>
<kernel>/gnu/store/y5aiijqiqna1y8ypn6c0jp367813xxnc-linux-libre-4.20.3/bzImage</kernel>
<initrd>/gnu/store/9xgqs9zf51i9binqjl5hgl8gl7ql40hc-system/initrd</initrd>
<cmdline>--root=/dev/vda1 --system=/gnu/store/9xgqs9zf51i9binqjl5hgl8gl7ql40hc-system --load=/gnu/store/9xgqs9zf51i9binqjl5hgl8gl7ql40hc-system/boot</cmdline>
</os>
<features>
<acpi/>
</features>
<clock offset='utc'/>
<on_poweroff>destroy</on_poweroff>
<on_reboot>destroy</on_reboot>
<on_crash>destroy</on_crash>
<devices>
<emulator>/gnu/store/4pnx934k40wni57r5swj2kr29l1j549f-qemu-3.1.0/bin/qemu-system-x86_64</emulator>
<disk type='file' device='disk'>
<driver name='qemu' type='qcow2' cache='writeback' error_policy='report'/>
<source file='/gnu/store/4mz1qqv7h5g5885q1aq0izlmy01knf1g-qemu-image'/>
<target dev='vda' bus='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
<readonly/>
</disk>
<filesystem type='mount' accessmode='passthrough'>
<driver type='path' wrpolicy='immediate'/>
<source dir='/gnu/store'/>
<target dir='TAGjoptajej2oynju6yvboauz7pl6uj'/>
</filesystem>
<controller type='usb' index='0' model='piix3-uhci'>
<address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
</controller>
<controller type='pci' index='0' model='pci-root'/>
<input type='mouse' bus='ps2'/>
<input type='keyboard' bus='ps2'/>
<graphics type='spice' port='3003' autoport='no' listen='127.0.0.1'>
<listen type='address' address='127.0.0.1'/>
</graphics>
<video>
<model type='qxl' ram='65536' vram='16384' vgamem='16384' heads='1' primary='yes'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
</video>
<memballoon model='none'/>
<rng model='virtio'>
<backend model='random'>/dev/urandom</backend>
</rng>
<interface type='network'>
<mac address='52:54:00:ae:72:b9'/>
<source network='gblabs'/>
<model type='rtl8139'/>
</interface>
</devices>
</domain>
[-- Attachment #3: Type: text/plain, Size: 175 bytes --]
hope this will help others!
happy hacking!
Giovanni
[...]
[1] /var/log/libvirt/qemu/container-minimal.log was helpful since the
command line used to start the VM lacked
[-- Attachment #4.1: Type: text/plain, Size: 53 bytes --]
--
Giovanni Biscuolo
Xelera IT Infrastructures
[-- Attachment #4.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
prev parent reply other threads:[~2019-01-25 11:27 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-24 18:18 "guix system vm" to libvirt XML domain Giovanni Biscuolo
2019-01-24 19:04 ` Giovanni Biscuolo
2019-01-24 20:01 ` Gábor Boskovits
2019-01-25 11:21 ` Giovanni Biscuolo [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ftthasot.fsf@roquette.mug.biscuolo.net \
--to=g@xelera.eu \
--cc=boskovits@gmail.com \
--cc=help-guix@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).