Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Rocky-9-Azure-LVM.ks] lot of statements raise errors in %post section #5

Open
bioinfornatics opened this issue May 21, 2024 · 1 comment

Comments

@bioinfornatics
Copy link

Dear,

Thanks for your works on those kickstart file, after a try; the Rocky-9-Azure-LVM.ks recipe do not works as expected.

Indeed:

  1. dnf install command are not able to reach network and do not know the value of releasever
Unable to detect release version (use '--releasever' to specify release version)
Rocky Linux $releasever - BaseOS                                                                                                                                                                              0.0  B/s |   0  B     00:00    
Errors during downloading metadata for repository 'baseos':
  - Curl error (6): Couldn't resolve host name for https://mirrors.rockylinux.org/mirrorlist?arch=x86_64&repo=BaseOS-$releasever [Could not resolve host: mirrors.rockylinux.org]
Error: Failed to download metadata for repo 'baseos': Cannot prepare internal mirrorlist: Curl error (6): Couldn't resolve host name for https://mirrors.rockylinux.org/mirrorlist?arch=x86_64&repo=BaseOS-$releasever [Could not resolve host: mirrors.rockylinux.org]

  1. auth is deprecated

  2. missing repo statement
    I added these lines

repo           --name=epel                          --mirrorlist=https://mirrors.fedoraproject.org/mirrorlist?repo=epel-9&arch=x86_64
repo           --name=epel-next                     --mirrorlist=https://mirrors.fedoraproject.org/mirrorlist?repo=epel-next-9&arch=x86_64
repo           --name=packages-microsoft-com-prod   --baseurl=https://packages.microsoft.com/rhel/9.0/prod
repo           --name=rocky-BaseOS-9.4              --mirrorlist=https://mirrors.rockylinux.org/mirrorlist?repo=rocky-BaseOS-9.4&arch=x86_64
repo           --name=rocky-Extra-OS-9.4            --mirrorlist=https://mirrors.rockylinux.org/mirrorlist?repo=plus-9.4&arch=x86_64
repo           --name=rocky-Appstream-9.4           --mirrorlist=https://mirrors.rockylinux.org/mirrorlist?repo=rocky-AppStream-9.4&arch=x86_64
repo           --name=rocky-CRB-9.4                 --mirrorlist=https://mirrors.rockylinux.org/mirrorlist?repo=rocky-CRB-source-9.4&arch=x86_64
  1. dracut have some errors and warning
dracut: WARNING: <key>+=" <values> ": <values> should have surrounding white spaces!
dracut: WARNING: This will lead to unwanted side effects! Please fix the configuration file.

dracut: Cannot find module directory /lib/modules/6.8.9-300.fc40.x86_64/
dracut: and --no-kernel was not specified
  1. sed do not works
sed: can't read /etc/yum/pluginconf.d/product-id.conf: No such file or directory
sed: can't read /etc/yum/pluginconf.d/subscription-manager.conf: No such file or directory
  1. Missing tools
/tmp/ks-script-0v7t0w9h: line 9: grub2-install: command not found
/tmp/ks-script-0v7t0w9h: line 13: parted: command not found

As the command LANG=C sudo livecd-creator --verbose --fslabel=Rocky-9-Azure --config=Rocky-9-Azure-LVM.ks --cache=/var/cache/live is able to generate the .iso file I suspect that those error was not seen

@bioinfornatics
Copy link
Author

Also tried with mock without success as shown below

$ sudo setenforce 0
$ sudo usermod -a -G mock $USER
$ mock -r rocky-9-x86_64 --init
$ mock -r rocky-9-x86_64 --install lorax-lmc-novirt vim-minimal pykickstart git
$ mock -r rocky-9-x86_64 --shell --isolation=simple --enable-network
<mock-chroot> sh-5.1# git clone https://github.com/rocky-linux/kickstarts -b r9
<mock-chroot> sh-5.1# cd kickstarts
<mock-chroot> sh-5.1# livemedia-creator --ks Rocky-9-Workstation.ks \
  --no-virt \
  --resultdir /var/lmc \
  --project="Rocky Linux" \
  --make-iso \
  --volid Rocky-Workstation-9 \
  --iso-only \
  --iso-name Rocky-Workstation-9-x86_64.iso \
  --releasever=9 \
  --nomacboot
2024-05-21 15:46:56,023: livemedia-creator v34.9.25-1
2024-05-21 15:46:56,023: selinux is Disabled
/usr/lib/python3.9/site-packages/pykickstart/commands/partition.py:448: KickstartParseWarning: A partition with the mountpoint / has already been defined.
  warnings.warn(_("A partition with the mountpoint %s has already been defined.") % pd.mountpoint, KickstartParseWarning)
2024-05-21 15:46:56,062: disk_img = /var/lmc/lmc-disk-fteyc4ie.img
2024-05-21 15:46:56,062: Using disk size of 7752MiB
2024-05-21 15:46:56,155: Running anaconda.
2024-05-21 15:46:58,160: Starting installer, one moment...
2024-05-21 15:46:58,160: terminal size detection failed, using default width
2024-05-21 15:46:58,161: anaconda 34.25.4.9-1.el9_4.rocky.0.3 for Rocky Linux 9 (pre-release) started.
2024-05-21 15:46:58,161: 15:46:57 Service org.fedoraproject.Anaconda.Modules.Storage has failed to start: Process org.fedoraproject.Anaconda.Modules.Storage exited with status 1
2024-05-21 15:47:08,171: Running anaconda failed: process '['unshare', '--pid', '--kill-child', '--mount', '--propagation', 'unchanged', 'anaconda', '--kickstart', '/builddir/kickstarts/Rocky-9-Workstation.ks', '--cmdline', '--dirinstall', '--remotelog', '127.0.0.1:59215']' exited with status 1
2024-05-21 15:47:56,230: Install failed: novirt_install failed
2024-05-21 15:47:56,230: Removing bad disk image
2024-05-21 15:47:56,231: ERROR: Image creation failed: novirt_install failed
2024-05-21 15:47:56,231: Image creation failed: novirt_install failed
<mock-chroot> sh-5.1# 
logout
Finish: shell
Finish: run

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant