[opensuse-autoinstall] Wrong disk-id with hw raid
Hi I'm having a problem with hardware raid and autoyast. First some background, I have the following setup: * HP ProLiant DL380 * SLES11 autoinstaller - all in one DVD * HP HW raid controller to set up hardware raid 5 on the system. * The software to set up hardware raid is put into the initrd of the SLES DVD A precondition is to be able to install without network and to bundle everything in one install DVD. The autoyast installer launches a pre-install script that sets up the hardware Raid. Now the actual problem: The data in /dev/disk/by-id is read and memorized by yast before raid is set up. After the raid setup script has completed all values have changed in /dev/disk/by-id. This causes the installer to crash when it later tries to set up Grub. Yast inserts the incorrect values it remembers into /boot/grub/device.map. The installer crashes with this error in y2log_bootloader: grub> setup --stage2=/boot/grub/stage2 --force-lba (hd0) (hd0,0) Error 21: Selected disk does not exist grub> quit Is it possible to make the yast bootloader re-read the values from /dev/disk/by-id before setting up grub? I tried to simply override the values in the files it touches in a chroot script, but yast simply removes my changes and creates a new incorrect file in its place. I have also tried to add the raid script to /etc/init.d/ inside initrd of the SLES installer, but I can't link it like I would on debian. Googling this I found that I need to run 'insserv' but I can't chroot into the initrd in any way to do this. I'm not even sure running it in a runlevel really early would be enough, but this is an option I have not been able to test fully, so some pointers or a link on where I can find info on setting up init-scripts in suse without insserv would be greatly appreciated. Warm regards, Tomas Ps. Thanks Uwe for solving the issue '[opensuse-autoinstall] Rule based auto-installation without network' for me Ds. -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
on Wednesday 08 July 2009 Tomas Rosenthal wrote:
Now the actual problem: The data in /dev/disk/by-id is read and memorized by yast before raid is set up. After the raid setup script has completed all values have changed in /dev/disk/by-id. This causes the installer to crash when it later tries to set up Grub. Yast inserts the incorrect values it remembers into /boot/grub/device.map.
can you try to pass exec=/tmp/my_raid_setup to linuxrc? That should be executed before yast starts and might help here. Of course you have to put the my_raid_setup binary/script into the initrd -- ciao, Uwe Gansert Uwe Gansert SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Business: http://www.suse.de/~ug -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
On Fri, 10 Jul 2009, Uwe Gansert wrote:
can you try to pass exec=/tmp/my_raid_setup to linuxrc? That should be executed before yast starts and might help here. Of course you have to put the my_raid_setup binary/script into the initrd
I appended 'Exec: /arraycfg.sh' to /linuxrc.config inside initrd (I'm extracting the original initrd, adds my changes, and puts it back again using cpio). This is btw the same way I invoked it before from the pre-install scripts and there it works. arraycfg.sh is just a basic shell script which invokes the hardware script which is also added to the initrd. But now when invoked from linuxrc, I'm calling the script so early that the initrd filesystem is not loaded, or something. It doesn't find basic commands such as grep, sed, head etc. What am I doing wrong? My linuxrc.config looks like this: KernelPCMCIA: 1 UseUSBSCSI: 1 Product: SUSE Linux Enterprise Server 11 UpdateDir: /linux/suse/x86_64-sles11 MemLoadImage: 204800 MemYaST: 123456 InstsysComplain: 1 InitrdID: 2009-03-10.f2a3c053 dud: disk:/?device=*usb* KexecReboot: 0 Exec: /arraycfg.sh Regards, Tomas -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
on Sunday 12 July 2009 Tomas Rosenthal wrote:
But now when invoked from linuxrc, I'm calling the script so early that the initrd filesystem is not loaded, or something. It doesn't find basic commands such as grep, sed, head etc.
What am I doing wrong? My linuxrc.config looks like this:
*argh* you are right. The exec is executed too early :-/ sorry. We can try something different. You have to change the initrd anyway, so create a directory like this: /linux/suse/x86_64-sles11/install/ and copy this shell script with the name update.pre into it: #! /bin/sh /my_raid_setup.sh or copy your raid_setup to /linux/suse/x86_64-sles11/install/update.pre That should run later. -- ciao, Uwe Gansert Uwe Gansert SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Business: http://www.suse.de/~ug -- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
Hi again. We solved it, but in another less beautiful way. We tried some combinations but didn't get it to work the way you suggested. Instead, we mounted the root in boot/x86_64/ and added a script called inst_setup in sbin and re-created the root. That did the trick. Regards, Tomas On Wed, 15 Jul 2009, Uwe Gansert wrote:
on Sunday 12 July 2009 Tomas Rosenthal wrote:
But now when invoked from linuxrc, I'm calling the script so early that the initrd filesystem is not loaded, or something. It doesn't find basic commands such as grep, sed, head etc.
What am I doing wrong? My linuxrc.config looks like this:
*argh* you are right. The exec is executed too early :-/ sorry.
We can try something different. You have to change the initrd anyway, so create a directory like this: /linux/suse/x86_64-sles11/install/ and copy this shell script with the name update.pre into it:
#! /bin/sh /my_raid_setup.sh
or copy your raid_setup to /linux/suse/x86_64-sles11/install/update.pre That should run later.
-- ciao, Uwe Gansert
-- To unsubscribe, e-mail: opensuse-autoinstall+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-autoinstall+help@opensuse.org
participants (2)
-
Tomas Rosenthal
-
Uwe Gansert