Hi,
With CentOS I’m used to install VM’s using kickstart without local media (e.g. a boot iso) with a command like:
virt-install ... -location "http://..../9-stream/BaseOS/x86_64/os/" \ --initrd-inject ks.cfg --extra-args="inst.ks=file:///ks.cfg"
When I try a similar command with Rocky Linux (I tried both .../os/ and .../kickstart/ in the URL paths) it loads vmlinuz and initrd.img, but it fails later: for version 8 and 9 different things happen (timeouts in 8 and endless loops in 9). Is there a way to achieve a virt-install with kickstart (and without downloading and mounting stuff)?
Thanks, Jos
Hello, I use ansible to read a var file and then create a kickstart file and command to execute remotely. It ends up looking something like this:
virt-install --name r9-sandbox2 --ram 2048 --disk path=/VM/r9-sandbox2-sda,size=20,bus=sata --vcpus 2 --os-type linux --os-variant rhel9.0 --network bridge=br0,model=virtio --graphics vnc,listen=0.0.0.0,port=5918 --initrd-inject=myks.ks --extra-args 'inst.text inst.ks=file:/myks.ks' --location http://dl.rockylinux.org/pub/rocky/9/BaseOS/x86_64/os/ --sound none --noautoconsole --autostart
Hope this helps, jorgy
On Saturday, April 29, 2023 at 06:56:37 AM MDT, Jos Vos via rocky rocky@lists.resf.org wrote:
Hi,
With CentOS I’m used to install VM’s using kickstart without local media (e.g. a boot iso) with a command like:
virt-install ... -location "http://..../9-stream/BaseOS/x86_64/os/" \ --initrd-inject ks.cfg --extra-args="inst.ks=file:///ks.cfg"
When I try a similar command with Rocky Linux (I tried both .../os/ and .../kickstart/ in the URL paths) it loads vmlinuz and initrd.img, but it fails later: for version 8 and 9 different things happen (timeouts in 8 and endless loops in 9). Is there a way to achieve a virt-install with kickstart (and without downloading and mounting stuff)?
Thanks, Jos
Hi,
On Sun, Apr 30, 2023 at 01:27:57AM +0000, Eric Jorgensen wrote:
I use ansible to read a var file and then create a kickstart file and command to execute remotely. It ends up looking something like this:
[...]
Thanks for your answer, but this is what I already did, using an existing kickstart file. When installing, it then stucks after "Starting dracut initqueue hook", after some timeout followed by a loop of errors, where (a.o.) it complains about a missing stage2.img.
But in the meantime I found the solution: either add "inst.repo=..." to the --extra-args or add an "url ..." entry in the kickstart file, with the base os URL (I guess you have that "url" entry in your ks). Now it works, both for Rocky 8 and 9.
For CentOS (8 and 9) neither of these extra url's are necessary, what caused the confusion. Probably their imstall media are slightly different.
Anyway, thanks,
Correct. I do have a line in my ks file: url --url="http://dl.rockylinux.org/pub/rocky/9/BaseOS/x86_64/os/"
I'm glad you figured it out. jorgy
On Monday, May 1, 2023 at 06:22:23 AM MDT, Jos Vos jos@xos.nl wrote:
Hi,
On Sun, Apr 30, 2023 at 01:27:57AM +0000, Eric Jorgensen wrote:
I use ansible to read a var file and then create a kickstart file and command to execute remotely. It ends up looking something like this:
[...]
Thanks for your answer, but this is what I already did, using an existing kickstart file. When installing, it then stucks after "Starting dracut initqueue hook", after some timeout followed by a loop of errors, where (a.o.) it complains about a missing stage2.img.
But in the meantime I found the solution: either add "inst.repo=..." to the --extra-args or add an "url ..." entry in the kickstart file, with the base os URL (I guess you have that "url" entry in your ks). Now it works, both for Rocky 8 and 9.
For CentOS (8 and 9) neither of these extra url's are necessary, what caused the confusion. Probably their imstall media are slightly different.
Anyway, thanks,