:: Re: [DNG] Automate devuan install o…
Page principale
Supprimer ce message
Répondre à ce message
Auteur: wirelessduck
Date:  
À: B Stack
CC: Dng
Anciens-sujets: Re: [DNG] Automate devuan install on VMware vsphere
Sujet: Re: [DNG] Automate devuan install on VMware vsphere
Thanks for the tips. I've finally found some time to get back on to
trying this again.

I've tried to test it out with the following command:

vm=testhost ; time sudo virt-install --name="${vm}" --memory=2048
--vcpus=1 --os-variant debiantesting --hvm --disk size=20
--location=/home/devuan/Downloads/devuan_chimaera_4.0.0_amd64_netinstall.iso
--initrd-inject=/home/devuan/preseed/devuan.preseed --extra-args
"hostname=${vm} NOTIFYEMAIL=email@??? interface=auto" --debug
--network type=bridge,source=virbr0 --noautoconsole

but it can't find the installation media.

----8<----
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (guest:320)
Setting Guest osinfo name <_OsVariant name=generic>
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (guest:320)
Setting Guest osinfo name <_OsVariant name=debiantesting>
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urlfetcher:38)
Using scratchdir=/var/lib/libvirt/boot
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:284)
Finding distro store for
location=/home/devuan/Downloads/devuan_chimaera_4.0.0_amd64_netinstall.iso
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:874)
variant=debiantesting has distro=debian, looking for matching distro
store to prioritize
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:883)
Prioritizing distro store=<class
'virtinst.install.urldetect._DebianDistro'>
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urlfetcher:332)
Running isoinfo: ['isoinfo', '-J', '-i',
'/home/devuan/Downloads/devuan_chimaera_4.0.0_amd64_netinstall.iso',
'-f']
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:45)
Failed to acquire file=current/images/MANIFEST
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:45)
Failed to acquire file=current/legacy-images/MANIFEST
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:45)
Failed to acquire file=daily/MANIFEST
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urlfetcher:320)
Running isoinfo: ['isoinfo', '-J', '-i',
'/home/devuan/Downloads/devuan_chimaera_4.0.0_amd64_netinstall.iso',
'-x', '/.disk/info']
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urlfetcher:72)
Fetching URI: /.disk/info
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:108)
found filename=.disk/info but regex=Debian.* didn't match
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:45)
Failed to acquire file=.treeinfo
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:45)
Failed to acquire file=treeinfo
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:45)
Failed to acquire file=content
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:108)
found filename=.disk/info but regex=Ubuntu.* didn't match
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (urldetect:45)
Failed to acquire file=VERSION
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (cli:255)   File
"/usr/bin/virt-install", line 8, in <module>
    virtinstall.runcli()
  File "/usr/share/virt-manager/virtinst/virtinstall.py", line 1158, in runcli
    sys.exit(main())
  File "/usr/share/virt-manager/virtinst/virtinstall.py", line 1145, in main
    guest, installer = build_guest_instance(conn, options)
  File "/usr/share/virt-manager/virtinst/virtinstall.py", line 586, in
build_guest_instance
    installer_detect_distro(guest, installer, osdata)
  File "/usr/share/virt-manager/virtinst/virtinstall.py", line 549, in
installer_detect_distro
    fail(_("Error validating install location: %s") % str(e))
  File "/usr/share/virt-manager/virtinst/cli.py", line 255, in fail
    log.debug("".join(traceback.format_stack()))


[Thu, 20 Jul 2023 19:48:03 virt-install 6546] ERROR (cli:256) Error
validating install location: Could not find an installable
distribution at URL
'/home/devuan/Downloads/devuan_chimaera_4.0.0_amd64_netinstall.iso'

The location must be the root directory of an install tree.
See virt-install man page for various distro examples.
[Thu, 20 Jul 2023 19:48:03 virt-install 6546] DEBUG (cli:258)
Traceback (most recent call last):
  File "/usr/share/virt-manager/virtinst/virtinstall.py", line 544, in
installer_detect_distro
    autodistro = installer.detect_distro(guest)
  File "/usr/share/virt-manager/virtinst/install/installer.py", line
532, in detect_distro
    ret = self._treemedia.detect_distro(guest)
  File "/usr/share/virt-manager/virtinst/install/installertreemedia.py",
line 306, in detect_distro
    cache = self._get_cached_data(guest, fetcher)
  File "/usr/share/virt-manager/virtinst/install/installertreemedia.py",
line 185, in _get_cached_data
    store = urldetect.getDistroStore(guest, fetcher,
  File "/usr/share/virt-manager/virtinst/install/urldetect.py", line
319, in getDistroStore
    raise ValueError(msg)
ValueError: Could not find an installable distribution at URL
'/home/devuan/Downloads/devuan_chimaera_4.0.0_amd64_netinstall.iso'


The location must be the root directory of an install tree.
----8<----

/.disk/info on the ISO doesn't include "Debian" anywhere so I'm not
entirely surprised by the error.

Is there some magic incantation required to get virt-install working
with Devuan?

I've tried changing to `--os-variant
name=debiantesting,detect=off,require=off` but still get the same
error.

Tom

On Tue, 25 Oct 2022 at 22:42, B Stack <bgstack15@???> wrote:
>
> Tom,
>
> My example from my blog [0] is over a year old, but it demonstrates
> the answers that were in use at the time. I probably need to publish a
> new version. Beware that I'm pretty sure my preseed file installed the
> old grub and not current grub so you probably don't want to just use
> the whole thing. Old grub was the first one I got working with preseed
> I think, and I forget why I was using old grub otherwise.
>
> In the past I had had trouble with the Devuan installer ISO files, and
> I normally used beta ones. Also specifically in my situation for
> instantiating VMs in libvirt/qemu/kvm, I had to modify libvirt to
> extract the correct filenames for our different-from-debian iso file
> such as initrd.gz. That will be documented somewhere on my blog too
> [1] but I doubt that will affect VMWare.
>
> B. Stack
>
> [0]: https://bgstack15.ddns.net/blog/posts/2021/05/23/use-virt-install-to-fully-automate-the-install-for-devuan-ceres-with-preseed-may-2021-edition/
> [1]: https://bgstack15.ddns.net/blog/posts/2020/03/26/use-virt-install-to-fully-automate-the-install-for-devuan-ceres-with-preseed-march-2020-edition/
>
> On Tue, Oct 25, 2022 at 4:46 AM wirelessduck--- via Dng
> <dng@???> wrote:
> >
> >
> >
> > On 25 Oct 2022, at 00:55, Linux O'Beardly <linux.obeardly@???> wrote:
> >
> > 
> > I don't have an opinion on this, but I do hope you keep us informed. I would like to know the results of your efforts.
> >
> >
> > Thanks, will do.
> >
> > I’m still looking to find any devuan-specific preseed options eg. init system choice. Haven’t found anything searching through devuan Gitea.
> >
> > I might try to run the linked script on https://preseed.debian.net/debian-preseed/ against the devuan mirror if nothing else comes up.
> >
> > https://git.einval.com/cgi-bin/gitweb.cgi?p=steve-scripts.git;a=blob_plain;f=extract_template.pl;hb=HEAD
> >
> > If the preseed fails, I will probably wait for the upcoming Devuan docker hub images before attempting cloud-init.
> >
> > Tom
> > _______________________________________________
> > Dng mailing list
> > Dng@???
> > https://mailinglists.dyne.org/cgi-bin/mailman/listinfo/dng




--
Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html