I am reposting this because it's been 2 or 3 weeks. Hello, Hopefully this is the right place to send a question like this... I'm attempting to automate creation of VMs using virt-install and a cloud-init disk image. To get this to work, I need to specify the location of the cloud-init configs by passing smbios key/value pairs. Normally, -smbios is provided to qemu to do this. With virt-install, the Internet says I should use --sysinfo. However, --sysinfo (as well as --qemu-comandline) is reported as an invalid command flag, and it is not present when I look at man virt-install and virt-install --help. I am hoping someone on the list knows why this isn't working or can explain how I might provide the arguments to qemu. The host is Debian 9. It is up-to-date as far as package versions are concerned, as much as Debian 9 can be. I can't find any indication about why the arguments would have been taken away. Thanks!
On Mon, Aug 10, 2020 at 12:49:37AM -0500, David wrote:> I am reposting this because it's been 2 or 3 weeks. > > Hello, > > Hopefully this is the right place to send a question like this... > > I'm attempting to automate creation of VMs using virt-install and a > cloud-init disk image. To get this to work, I need to specify the location > of the cloud-init configs by passing smbios key/value pairs. > > Normally, -smbios is provided to qemu to do this. With virt-install, the > Internet says I should use --sysinfo. However, --sysinfo (as well as > --qemu-comandline) is reported as an invalid command flag, and it is not > present when I look at man virt-install and virt-install --help. > > I am hoping someone on the list knows why this isn't working or can explain > how I might provide the arguments to qemu. The host is Debian 9. It is > up-to-date as far as package versions are concerned, as much as Debian 9 > can be. I can't find any indication about why the arguments would have been > taken away.Hi, Unfortunately for you it was not taken away as it was not introduced in the old version available in Debian 9. Based on Debian packages there is virt-manager 1.4.0 which is about 4 years old. Looking at virt-manager code-base Debian 9 just missed the --sysinfo and --qemu-commandline arguments as both were introduced in 1.4.1. I checked that there is no virt-manager in stretch-backports so your options are probably update to current stable (Debian 10) or get newer virt-manager from upstream. Just a not to keep in mind, virt-manager 1.5.0 is the last python-2 based version and since virt-manager 2.0.0 we support only python-3. Pavel
Thanks Pavel! Time to update the host to debian 10. I didn't realize it was that old. I will respond back later if there are any issues. Thanks for looking into it deeply. I will watch out for python 3, but it probably won't cause me much trouble and will feel good to get up to date. Kind regards, David On Mon, Aug 10, 2020, 2:46 AM Pavel Hrdina <phrdina@redhat.com> wrote:> On Mon, Aug 10, 2020 at 12:49:37AM -0500, David wrote: > > I am reposting this because it's been 2 or 3 weeks. > > > > Hello, > > > > Hopefully this is the right place to send a question like this... > > > > I'm attempting to automate creation of VMs using virt-install and a > > cloud-init disk image. To get this to work, I need to specify the > location > > of the cloud-init configs by passing smbios key/value pairs. > > > > Normally, -smbios is provided to qemu to do this. With virt-install, the > > Internet says I should use --sysinfo. However, --sysinfo (as well as > > --qemu-comandline) is reported as an invalid command flag, and it is not > > present when I look at man virt-install and virt-install --help. > > > > I am hoping someone on the list knows why this isn't working or can > explain > > how I might provide the arguments to qemu. The host is Debian 9. It is > > up-to-date as far as package versions are concerned, as much as Debian 9 > > can be. I can't find any indication about why the arguments would have > been > > taken away. > > Hi, > > Unfortunately for you it was not taken away as it was not introduced in > the old version available in Debian 9. Based on Debian packages there is > virt-manager 1.4.0 which is about 4 years old. > > Looking at virt-manager code-base Debian 9 just missed the --sysinfo > and --qemu-commandline arguments as both were introduced in 1.4.1. > > I checked that there is no virt-manager in stretch-backports so your > options are probably update to current stable (Debian 10) or get newer > virt-manager from upstream. Just a not to keep in mind, virt-manager > 1.5.0 is the last python-2 based version and since virt-manager 2.0.0 we > support only python-3. > > Pavel >
You do not need to pass parameters through smbios. When you define the image using XML create a cdrom image. The cdrom image must contain meta_data.json and network_data.json files. The following is the ansible snippet I use to create the CD image. genisoimage -output {{ cloud_init_iso_dir }}/{{ instance_id }}.iso -volid config-2 -joliet -r {{ cloud_init_src_dir }}/ This is what I use to create VM images (I am using Centos not Debian so some stuff is different but the basics are the same) On 8/10/20 1:49 AM, David wrote:> I am reposting this because it's been 2 or 3 weeks. > > Hello, > > Hopefully this is the right place to send a question like this... > > I'm attempting to automate creation of VMs using virt-install and a > cloud-init disk image. To get this to work, I need to specify the location > of the cloud-init configs by passing smbios key/value pairs. > > Normally, -smbios is provided to qemu to do this. With virt-install, the > Internet says I should use --sysinfo. However, --sysinfo (as well as > --qemu-comandline) is reported as an invalid command flag, and it is not > present when I look at man virt-install and virt-install --help. > > I am hoping someone on the list knows why this isn't working or can > explain > how I might provide the arguments to qemu. The host is Debian 9. It is > up-to-date as far as package versions are concerned, as much as Debian 9 > can be. I can't find any indication about why the arguments would have > been > taken away. > > > Thanks!-- Alvin Starr || land: (647)478-6285 Netvel Inc. || Cell: (416)806-0133 alvin@netvel.net ||