I'm struggling with a strange issue. I'm trying to create a self-installer environment based on F10, grub, local ISO and kickstart:
- created a /dev/sda5 filesystem and copied the DVD ISO onto this - extracted the images/install.img file onto /dev/sda5 - created a grub.conf:
title Install F10 kickstart root (hd0,0) kernel /vmlinuz ks=hd:sda1/ks.cfg repo=hd:/dev/sda5:/iso initrd /initrd.img
- in the kickstart I defined the hd path:
harddrive --partition=/dev/sda5 --dir=/iso
When I started the installer, it stopped almost with the same issue at https://bugzilla.redhat.com/show_bug.cgi?id=473351: anaconda can't find install.img
Here's the anaconda's relevant log:
09:45:23 INFO : Searching for file on path /tmp/mnt/ks.cfg 09:45:23 INFO : file copied to /tmp/ks.cfg 09:45:23 INFO : setting up kickstart 09:45:23 INFO : kickstartFromHD 09:45:23 INFO : results of hd ks, partition is /dev/sda5, dir is /iso 09:45:23 INFO : doing kickstart... setting it up 09:45:23 DEBUG : configuring device eth0 09:45:33 INFO : get_connection (1995): NetworkManager connected 09:45:33 DEBUG : going to set language to hu_HU.UTF-8 09:45:33 INFO : setting language to hu_HU.UTF-8 09:45:33 INFO : starting STEP_STAGE2 09:45:33 INFO : partition is /dev/sda5, dir is /iso 09:45:33 INFO : mounting device sda5 for hard drive install 09:45:33 INFO : Path to stage2 image is /mnt/isodir/iso 09:45:33 ERROR : failed to mount loopback device /dev/loop0 on /mnt/runtime as /tmp/install.img: mount: wrong fs type, bad option, bad superblock on /dev/loop0,
missing codepage or helper program, or other error (could this be the IDE device where you in fact use ide-scsi so that sr0 or sda or so is needed?) In some cases useful info is found in syslog - try dmesg | tail or so
But when anaconda asks me and I give exactly the same repo path to it (sda5, /iso dir), the installation continues well:
09:45:48 INFO : partition /dev/sda5 selected 09:45:48 INFO : mounting device /dev/sda5 for hard drive install 09:45:48 INFO : Path to stage2 image is /mnt/isodir/iso/images/install.img 09:45:50 INFO : mounted loopback device /mnt/runtime on /dev/loop0 as /tmp/install.img 09:45:50 INFO : Looking for updates for HD in /mnt/isodir/iso/images/updates.img 09:45:50 INFO : Looking for product for HD in /mnt/isodir/iso/images/product.img 09:45:50 INFO : got stage2 at url hd:/dev/sda5://iso/images/install.img 09:45:50 INFO : reset repo= parameter to hd:/dev/sda5://iso 09:45:50 INFO : Loading SELinux policy 09:45:50 INFO : getting ready to spawn shell now 09:45:51 INFO : Running anaconda script /usr/bin/anaconda 09:45:54 INFO : using only installclass _Fedora
Am I wrong?
Laszlo BERES <beres.laszlo <at> sys-admin.hu> writes:
- created a /dev/sda5 filesystem and copied the DVD ISO onto this
- extracted the images/install.img file onto /dev/sda5
- created a grub.conf:
title Install F10 kickstart root (hd0,0) kernel /vmlinuz ks=hd:sda1/ks.cfg repo=hd:/dev/sda5:/iso initrd /initrd.img
- in the kickstart I defined the hd path:
harddrive --partition=/dev/sda5 --dir=/iso
When I started the installer, it stopped almost with the same issue at https://bugzilla.redhat.com/show_bug.cgi?id=473351: anaconda can't find
I notice that in your kernel line you have ks=hd:sda1/ks.cfg there is a missing ":"
Should it not be: ks=hd:sda1:/ks.cfg
Mike
Mike wrote:
I notice that in your kernel line you have ks=hd:sda1/ks.cfg there is a missing ":"
Should it not be: ks=hd:sda1:/ks.cfg
Thanks, Mike, you're right, but that did't help for the original issue.
Laszlo BERES wrote:
Thanks, Mike, you're right, but that did't help for the original issue.
OK Laszlo - I was not sure that you had installed the directory images into the same directory as your iso? I believe that you need the images directory and its contents that include install.img - certainly I had to do that when I was having problems.
What I did was to have the iso, and the images directory with its install.img file in a directory /opt/Local/home/mike/isos/f10
The partition is mounted as /opt so when defining the repo file I needed: hd:/dev/sda6:/Local/home/mike/isos/f10
And this worked.
In your case I presume that you have a directory in /dev/sda5 called isos? If so then maybe copying images and its contents from the loop mount iso file using rsync -aXH might work? Certainly I fiddled for ages before I found the right combination defining the paths before it worked!
Mike Cloaked wrote:
What I did was to have the iso, and the images directory with its install.img file in a directory /opt/Local/home/mike/isos/f10
The partition is mounted as /opt so when defining the repo file I needed: hd:/dev/sda6:/Local/home/mike/isos/f10
As I read your BZ and earlier posts, you've used manual installation, am I right? The way you described works well in interactive mode, but not with kickstart.
Laszlo BERES wrote:
As I read your BZ and earlier posts, you've used manual installation, am I right? The way you described works well in interactive mode, but not with kickstart.
I am not sure what you mean by manual - but I also extracted the vmlinuz and initrd.img files from the iso, and placed them in /boot and then made an additional grub.conf entry like you did so that physical optical media were not need (but had burned a DVD in case of emergency). I also initiated the start of the install from the physical DVD as a test once I had fathomed out the correct HD install parameters.
I tried adding both the hd definition to the kernel boot line, as well as booting the install and adding the information from the graphical entry on screen - and all three methods now allow the install to continue.
In your case you are now doing the same (assuming you have images directory in the same dir as the iso) but the only difference is now that you also use a kickstart file in a different (and presumably non-root) partition (/dev/sda1). I wonder if the fact that the .ks file is also not in the same directory matters?
I think I would try to put the kickstart file in the same directory as the iso and see if that works. I am not sure why your method fails to work but then I was bitten by the change from previous tradition in my own case!
Mike
Laszlo BERES wrote:
As I read your BZ and earlier posts, you've used manual installation, am I right? The way you described works well in interactive mode, but not with kickstart.
By the way I looked at the install guide again at http://docs.fedoraproject.org/install-guide/f10/en_US/sn-automating-installa...
and noticed that in the kickstart section they include advice that you can add the kickstart source at the boot line - linux ks=location/kickstart-file.cfg
However the examples given below that infer that the hard drive definition is of the form: ks=hd:/device/directory/ks.cfg
i.e. there is no colon between the device and the directory - so presumably your original matches this. So now I am wondering if the advice in the install guide is correct? In my case it was not! it would be nice if someone else could confirm a kickstart works using the .ks file on HD or post any change to the way the file is defined?
I also note that in the release notes there is a paragraph about http definition of the ks file: "2.1.5. Kickstart HTTP issue
When using a Kickstart configuration file via HTTP, kickstart file retrieval may fail with an error that indicates the file could not be retrieved. Click the OK button several times without making modifications to override this error successfully. As a workaround, use one of the other supported methods to retrieve Kickstart configurations."
Maybe this is biting you also for the kickstart via HD?
Mike Cloaked wrote:
kernel /vmlinuz ks=hd:sda1/ks.cfg repo=hd:/dev/sda5:/iso initrd /initrd.img
- in the kickstart I defined the hd path:
harddrive --partition=/dev/sda5 --dir=/iso
I just noticed something else -
Your line: kernel /vmlinuz ks=hd:sda1/ks.cfg repo=hd:/dev/sda5:/iso seems to not have the standard definition for the device for the ks file...
Should it be: kernel /vmlinuz ks=hd:/dev/sda1/ks.cfg repo=hd:/dev/sda5:/iso ====
presuming that the ks.cfg file is in the root directory for the /dev/sda1 partition?
Did you copy the images directory to the "iso" directory?
On Mon, Dec 01, 2008 at 06:27:54AM -0800, Mike Cloaked wrote:
Laszlo BERES wrote:
As I read your BZ and earlier posts, you've used manual installation, am I right? The way you described works well in interactive mode, but not with kickstart.
I am not sure what you mean by manual - but I also extracted the vmlinuz and initrd.img files from the iso, and placed them in /boot and then made an additional grub.conf entry like you did so that physical optical media were not need (but had burned a DVD in case of emergency). I also initiated the start of the install from the physical DVD as a test once I had fathomed out the correct HD install parameters.
I tried adding both the hd definition to the kernel boot line, as well as booting the install and adding the information from the graphical entry on screen - and all three methods now allow the install to continue.
In your case you are now doing the same (assuming you have images directory in the same dir as the iso) but the only difference is now that you also use a kickstart file in a different (and presumably non-root) partition (/dev/sda1). I wonder if the fact that the .ks file is also not in the same directory matters?
I think I would try to put the kickstart file in the same directory as the iso and see if that works. I am not sure why your method fails to work but then I was bitten by the change from previous tradition in my own case!
You should have the ISO and the install.img file (from the images/ folder) stored on the source HDD like this:
sdaX --- some_folder/ ---- Fedora-10-i386-DVD.iso | +-- images/ | +-- install.img
Then you point to to sdaX (whatever X is for the partition you stored the images on), and folder "some_folder". In other words, the ISO file should be sitting next to an "images" folder which contains the "install.img" file.
Paul W. Frields írta:
You should have the ISO and the install.img file (from the images/ folder) stored on the source HDD like this:
sdaX --- some_folder/ ---- Fedora-10-i386-DVD.iso | +-- images/ | +-- install.img
Then you point to to sdaX (whatever X is for the partition you stored the images on), and folder "some_folder". In other words, the ISO file should be sitting next to an "images" folder which contains the "install.img" file.
I do have the environment you described, but works only when I installing in interactive mode. Kickstart somehow breaks accessing install.img, but I don't know yet how.
Mike Cloaked írta:
Your line: kernel /vmlinuz ks=hd:sda1/ks.cfg repo=hd:/dev/sda5:/iso seems to not have the standard definition for the device for the ks file...
Should it be: kernel /vmlinuz ks=hd:/dev/sda1/ks.cfg repo=hd:/dev/sda5:/iso ====
I corrected and nothing's wrong accessing kickstart file. Somehow anaconda can't find install.img when I'm kickstarting it.
Did you copy the images directory to the "iso" directory?
Of course I did.
Laszlo BERES wrote:
I corrected and nothing's wrong accessing kickstart file. Somehow anaconda can't find install.img when I'm kickstarting it.
OK I have run out of ideas! Someone else must surely have tried kickstart - including some devs?
Need more input from someone else now perhaps?
Laszlo BERES wrote:
I corrected and nothing's wrong accessing kickstart file. Somehow anaconda can't find install.img when I'm kickstarting it.
One more thought - I guess that jigdo for SIG spins must use a kickstart file - I wonder if the files the spins use can be looked at to see if there are any clues there?
Mike
On Mon, 1 Dec 2008, Mike Cloaked wrote:
Need more input from someone else now perhaps?
If it is any help the grub line used by preupgrade (including a kickstart file) looks like
kernel /upgrade/vmlinuz preupgrade repo=hd:UUID=00000000-0000-0000-0000-000000000000:/var/cache/yum/preupgrade stage2=hd:UUID=00000000-0000-0000-0000-000000000000:/upgrade/install.img ks=hd:UUID=00000000-0000-0000-0000-000000000000:/upgrade/ks.cfg
(UUIDs blanked out becuase I am paranoid)
Michael Young