ProLiant Deployment and Provisioning
1821584 Members
3611 Online
109633 Solutions
New Discussion юеВ

PXE Boot Image from an ISO

 
Oliver Hookins
Occasional Advisor

Re: PXE Boot Image from an ISO

1. Mount the FW860.2009_0803.38.iso and SS830.2009_0817.183-x86.iso files somewhere and take the vmlinuz and initrd.img files from the system directory within the ISOs.

2. Use the "vsos" boot line from the system/isolinux.cfg, but replace the kernel with the path to the respective vmlinuz files you copied from the ISOs. Add this to your pxelinux.cfg/default (or whatever) file, with the following exceptions:
a. Change media=cdrom to media=network
b. Add iso1=nfs://192.168.1.1/tftpboot/hp/FW860.2009_0803.38.iso iso1mnt=/mnt/bootdevice

Obviously you will need to substitute your own NFS server's IP, and a correct NFS path.

3. As you can probably guess, put the ISO images on your NFS server in the path you just specified. It seems the ISOs will mount and access as root then mount the ISO as loopback on the same path, so you will need to either grant world-read/write privileges on the ISO path or configure the export with no_root_squash.

4. Boot the image(s) from your TFTP server.
5. ...
6. Profit!

I'm fairly certain it was that easy after sorting our network issues out.
Forhad_1
Regular Visitor

Re: PXE Boot Image from an ISO

Thanks Oliver for your quick reply. But I am not having any luck with it. All I get is blue screen with a cursor. It stays there forever. Here is my default file

label vsos
MENU LABEL Firmware Maintenance 8.60
kernel fw-0860/vmlinuz
append initrd=fw-0860/initrd.img media=network rw root=/dev/ram0 ramdisk_size=164212 init=/bin/init loglevel=3 ide=nodma ide=noraid pnpbios=off vga=788 splash=silent showopts iso1=nfs://192.168.0.110/home/fwupdate/fw-0860/FW860.2009_0803.38.iso iso1mnt=/mnt/bootdevice

I don't know what I am missing here.

Thanks
Forhad
Oliver Hookins
Occasional Advisor

Re: PXE Boot Image from an ISO

When the blue screen is up, it is attempting to load drivers and mount the NFS filesystem. I also had this problem but my issue was a network loop. I would suggest checking access logs of your NFS server (auditctl can be useful for this) and perhaps running a tcpdump of the traffic between your blade and the TFTP/NFS server(s) to see what is going on.

Most likely it will be an issue getting to or accessing the NFS server with correct privileges, that seems to be the consensus so far.
Arco van Geest
Frequent Advisor

Re: PXE Boot Image from an ISO

You can switch to a console and check if you have an IP adres. (you can switch with ctrl+alt+F1, on text consoles it's enough to use ALT+Fn .

I saw this behaviour when ports are not portfast or have the native vlan taggged and untagged.
Forhad_1
Regular Visitor

Re: PXE Boot Image from an ISO

It works finally. I had issue with the network. Thanks guys for your help.

Bill Streeter
Advisor

Re: PXE Boot Image from an ISO

And...with 8.70 we start the fun all over again.

Using the same method as with 8.60 fails to mount the boot iso on the nfs server. I believe it's because the network isn't starting. When booting off the CD directly, the systems get an IP address. However, when booting off the network, no IP address is retrieved. Looking through the various scripts, I'm uncertain as to why the systems wouldn't be getting an IP address.
Bill Streeter
Advisor

Re: PXE Boot Image from an ISO

Anyone have any ideas?

I'm still stuck on why the systems aren't getting an IP address for any NICs when I boot the initrd from the network instead of the physical CD.
Peter Capriccio
Frequent Advisor

Re: PXE Boot Image from an ISO

From a quick glance, it looks like they modified supermount.sh again. I thought I had a quick and dirty solution by setting "media=usb", which triggers the "isomount" function and tries to start the network, but it rolls over and dies. When it tries to bring up the interfaces via DHCP, I get a
"glibc not found" error from the dhcp client. Too soon to tell how serious a situation this is, but I'll be looking into this very soon...
Bill Streeter
Advisor

Re: PXE Boot Image from an ISO

In my snooping around, I noticed "BOOTMEDIA" and "OSMEDIA" variables in the supermount file. When booted from a CD (I havent' tried USB yet) BOOTMEDIA=cdrom and OSMEDIA=[null]. Booting from PXE, BOOTMEDIA=network and OSMEDIA is still null. Putting BOOTMEDIA and OSMEDIA on append line didn't do anything. Perhaps messing with these could do something.

I'll have to put the disc on USB and see what happens with it there.
Peter Capriccio
Frequent Advisor

Re: PXE Boot Image from an ISO

Well, I was totally wrong about supermount.sh -- it hasn't changed. The dhcpcd problem seems to be a real one though -- this is what I see in
/root/compaq/log/cdrom.log:

Attempting to configure eth0 using DHCP
dhcpcd: /lib/libc.so.6: version `GLIBC_2.1' not found (required by dhcpcd)
dhcpcd: /lib/libc.so.6: version `GLIBC_2.2' not found (required by dhcpcd)
dhcpcd: /lib/libc.so.6: version `GLIBC_2.0' not found (required by dhcpcd)
return from dhcpcd 1

However, it doesn't look like libc or dhcpcd has changed between 8.60 and 8.70. Also, the versions reported in the library look compatible to me:

# strings /lib/libc.so.6 | grep GLIBC
GLIBC_2.0
GLIBC_2.1
GLIBC_2.1.1
GLIBC_2.1.2
GLIBC_2.1.3
GLIBC_2.2
GLIBC_2.2.1
GLIBC_2.2.2
GLIBC_2.2.3
GLIBC_2.2.4
GLIBC_2.2.6
GLIBC_2.3
GLIBC_2.3.2
GLIBC_2.3.3
GLIBC_2.3.4
GLIBC_2.4
GLIBC_PRIVATE

The other oddity is that when I boot from the 8.70 CD (well, via iLO vMedia), the network does come up as you had stated, however it is not from dhcpcd -- I get the same GLIBC not found error. Also, the IP address assigned is not from my DHCP server's scope:

# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:11:85:EA:B4:5B
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
.
.

My DHCP server uses a 16-bit mask and the scope starts at 192.168.2.0/16.

Bill, what address did your systems see when you booted from the 8.70 CD?

Puzzled Pete
Bill Streeter
Advisor

Re: PXE Boot Image from an ISO

I've had several, but 192.168.0.143/24 would be a typical address. I also had noted the GLIB errors when attempting to start the network service.

If they aren't getting an IP address using dhcpd, then where from?
Peter Capriccio
Frequent Advisor

Re: PXE Boot Image from an ISO

Here's the scoop so far -- its one of those "good news/bad news" situations...

The good news is that from what I can tell, the dhcpcd file seems to be "bad". When I was comparing the binaries, I was just using the "strings" command from within the 8.60 and 8.70 environments and they were showing the same version (DHCP Client Daemon v.1.3.22-pl4). When I did a "diff" on the binaries from another machine, it reported they were different and then an md5sum confirmed it:

linuxdc:/home/working/FW-0860/mnt# md5sum bin/dhcpcd
bfc8139ede893a442e49268c75c20e2e bin/dhcpcd

linuxdc:/home/working/FW-0870# md5sum bin/dhcpcd
f7d29e466712279c77bc196859ccf204 bin/dhcpcd

Luckily, the firmware CD's base system version has not changed since the 8.60 release (at least according to "/etc/SuSE-release", they both report "SUSE Linux Enterprise Server 10 (i586), VERSION = 10, PATCHLEVEL = 2") so you can fix the dhcpcd problem by using the copy in the latter release. Unfortunately, this means unpacking and repacking the initramfs (they went from an initrd to an initramfs in this release).

Now, the bad news is that the strange IP address situation is causing a problem, depending on your configuration. There seems to be something "hardcoded" to configure interface eth0 -- after "patching" my initramfs with the dhcpcd binary from 8.60, I was able to boot via the network and everything seemed to be working. However, when I looked at the network interfaces, this is what I saw using an "ifconfig" command:

eth0 Link encap:Ethernet HWaddr 00:11:85:E9:C9:FD
inet addr:192.168.0.1 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Interrupt:201

eth1 Link encap:Ethernet HWaddr 00:11:85:E9:C9:FC
inet addr:192.168.4.126 Bcast:192.168.255.255 Mask:255.255.0.0
inet6 addr: fe80::211:85ff:fee9:c9fc/64 Scope:Link
UP BROADCAST NOTRAILERS RUNNING MULTICAST MTU:1500 Metric:1
RX packets:61425 errors:0 dropped:0 overruns:0 frame:0
TX packets:41193 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:92829090 (88.5 Mb) TX bytes:4074672 (3.8 Mb)
Interrupt:209
.
.

For my testing, I was using a ProLiant DL380G4 with PXE boot enabled on embedded NIC2 (which disables PXE boot on the embedded NIC1) and there was no physical connection to NIC1. Since netconfig tries to bring up all available interfaces, eth1 picked up an address from my DHCP server and so it could NFS mount the ISO, etc. For giggles, I reversed the NIC settings to their defaults (PXE boot enabled on NIC1 and disabled on NIC2) and had only a physical connection to NIC1. This time, I was staring at the "X" cursor against a gray screen and eth0 had the "192.168.0.1" address again. Stranger still is that the ISO was showing up as mounted, but the routing table only showed the 192.168.0.0/24 network, so eth0 must be getting "overwritten" after dhcpcd has been run.

Back to the drawing board...
Peter Capriccio
Frequent Advisor

Re: PXE Boot Image from an ISO

Found the culprit -- these lines in the script called "usr/bin/bootrun" is doing the deed:

# Add default IPv4 address to eth0 interface. This is needed to resolve HPSUM hangs
# on host name resolving to IP address
NET_IFACE=`ifconfig | grep eth0`
if [ -n "$NET_IFACE" ]; then
ifconfig eth0 192.168.0.1 netmask 255.255.255.0
fi

Hopefully just commenting this out won't have any nasty side effects...
Peter Capriccio
Frequent Advisor

Re: PXE Boot Image from an ISO

Here's my solution, albeit not very elegant...

First off, there are no less than two copies of the previously mentioned "bootrun" script that set the IP address of "eth0" (if it exists) to 192.168.0.1/24 -- one in /usr/bin within the initramfs (looks like they removed the compressed "usr.iso" and just expanded it into the initramfs) and another in the "_autorun" directory of the CD itself. I'm not sure if both of them get executed, but if I only "patch" the one in the initramfs, I still see "eth0" forced to 192.168.0.1/24 (my thought is that I might as well "patch" both of them, since I have to be mucking around in the initramfs anyway). Unfortunately, because the one on the "CD" causes a problem, you also have to modify the ISO image.

So, in short, to get this version to work using the "low maintenance" method we've been enjoying, requires anything but that (which totally goes against my mantra of "I could be sleeping instead of doing this "):

- unpack the initramfs "initrd.img"
- replace the file "bin/dhcpcd" with the one from version 8.60
- edit the file "usr/bin/bootrun" and comment out the following section:

NET_IFACE=`ifconfig | grep eth0`
if [ -n "$NET_IFACE" ]; then
ifconfig eth0 192.168.0.1 netmask 255.255.255.0
fi

- repack the initramfs
- unpack the ISO
- edit the file "_autrun/bootrun" and comment out the same section (shown above)
- repack the ISO

Attached is an example of what I did, but who knows if it is correct (seems to work so far, but you non-cavemen might have a better solution).

One last thing -- a big thanks to Bill for bringing this updated version to my attention; I was perfectly happy with the previous version... :) :)
Bill Streeter
Advisor

Re: PXE Boot Image from an ISO

I wonder...would it work properly to just copy the compaq folder from the 8.70 iso into the 8.60 iso?

It seems to boot on a virutal machine, but I don't have an HP server handy to actually test it on.
Arco van Geest
Frequent Advisor

Re: PXE Boot Image from an ISO

Merging the hpfw 8.60 "OS" with the 8.70 HPSUM/FW would probably work. I can see no real relation between them. The only point a problem can exist are the ilo or rack drivers.
Arco van Geest
Frequent Advisor

Re: PXE Boot Image from an ISO

Probably a bit offtopic. Since 8.60 the hpsum is unusable in the Windows PE (from W2008). Did anyone manage to get hpsum firmware upgrade working in the new PE?
daveStyle
Occasional Advisor

Re: PXE Boot Image from an ISO

Does anyone have the script for 8.70?
Arco van Geest
Frequent Advisor

Re: PXE Boot Image from an ISO

I have made another live linux based on centos with the psp in it. That works but need some pollish.

If the build script is tested I will post it here. If you like living dangerous I can send it to you.
daveStyle
Occasional Advisor

Re: PXE Boot Image from an ISO

Yea, whack it up.
Somebody might find it useful :)
Marcus Daubaras
New Member

Re: PXE Boot Image from an ISO

I used Peter's solution for the 8.70 release and it works great with one minor modification, my mkisofs needed -J to get the Joliet format.

Since this thread has been so helpful I thought I'd give something back by calling attention to gPXE. I haven't seen anyone mention it here and it is a big improvement over regular PXE because it has extensions for booting from a variety of network sources (i.e. HTTP). This is especially helpful for larger files like the firmware/smartstart ram disks that can be unreliable over TFTP.

gPXE can be found on recent syslinux releases (I'm currently using 3.82). Just copy the gpxelinux.0 file to your TFTP server and modify your DHCP boot file option to use gpxelinux.0 instead of pxelinux.0. An example of the entry for the 8.70 firmware is attached.
Arco van Geest
Frequent Advisor

Re: PXE Boot Image from an ISO

As requested the kickstart for a centos livecd. don't use this on live centos systems! create a simple VM for this purpose (without LVM)
Arco van Geest
Frequent Advisor

Re: PXE Boot Image from an ISO

and a little script I use to generate the iso and the tftp tree.

I know it lacks documention. but these are the steps:
- create live build system
- copy i386 part of the PSP in /var/www/html/yum/
- createrepo /var/www/html/yum ( and start the webservice)
- put the ks and the create_iso in /data
- start create_iso
Belac
New Member

Re: PXE Boot Image from an ISO

First off, thanks for all the great information in this thread. It helped me get the HP diags up and running over PXE boot, which is a real life saver (I test over a hundred desktops a day at times). I've been trying to take it one step further and the Diags completely unattended from boot, but haven't had much successes. Anyone have any insight (sorry for the pun) into where I should start on this? I've looking through all the boot script files (awake.sh and subsequent calls) and understand (sorta) whats going on, but I don't know how to break in and tell the hpdags daemon to run a set of specific test, and tell mozilla to load the monitoring page for said test. Any help would be greatly appreciated.
J. Muellers
New Member

Re: PXE Boot Image from an ISO

Hello,

I was able to boot 8.60 fine like this:

LABEL 8.60
MENU LABEL HP Firmware Maintenance 8.60
KERNEL linux/firmware/8.60/x32/vmlinuz
APPEND initrd=linux/firmware/8.60/x32/initrd.img debug media=network rw root=/dev/ram0 ramdisk_size=640000 acpi=off init=/bin/init loglevel=5 ide=nodma ide=noraid pnpbios=off splash=0 showopts iso1=nfs://boot.mycompany.tld/export/FW860.2009_0803.38.iso iso1mnt=/mnt/bootdevice


Now I downloaded 8.70 and tried to do it the same way as with 8.60

LABEL 8.70
MENU LABEL HP Firmware Maintenance 8.70
KERNEL linux/firmware/8.70/x32/vmlinuz
APPEND initrd=linux/firmware/8.70/x32/initrd.img debug media=network rw root=/dev/ram0 ramdisk_size=640000 acpi=off init=/bin/init loglevel=5 ide=nodma ide=noraid pnpbios=off splash=0 showopts iso1=nfs://boot.mycompany.tld/export/FW870.2010_0121.61.iso iso1mnt=/mnt/bootdevice

But just after it tries the to start
X windows the server kind of crashes and powers off. These a some messages I get before the crash:


INIT: version 2.86 booting done
Loading drivers...done.
Starting udevd done
Starting RPC portmap daemon done
acpid: no ACPI support in kernel skipped
'acpid start' exits with status 5
ls: /mnt/boot/usb/sdgconfig: No such file or directory
ls: /mnt/boot/usb/sdgconfig: No such file or directory
ls: /mnt/boot/usb/sdgconfig: No such file or directory
/etc/init.d/boot.d/S26boot.hostname: line 38: [: : integer expression expected
/etc/init.d/hp-ilo: line 138: /opt/hp/hp-ilo/check_install_kernel.sh: No such file or directory
/etc/init.d/hp-ilo: line 85: rc_failed: command not found
'boot.health start' exits with status 1
Starting hp-ilo: /etc/init.d/boot.d/S36boot.hp-ilo: line 138: /opt/hp/hp-ilo/check_install_kernel.sh: No such file or directory
/etc/init.d/boot.d/S36boot.hp-ilo: line 85: rc_failed: command not found

Check installed kernel failed
'boot.hp-ilo start' exits with status 1
chmod: cannot access `/root/compaq/hplink.sh': No such file or directory
cp: target `/var/www/html/cfg/' is not a directory: No such file or directory
kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
ls: /dev/cdrom: No such file or directory
Starting hpmouse helper process/etc/init.d/boot.d/S84hpmouse: line 52: rc_reset: command not found
/etc/init.d/boot.d/S84hpmouse: line 53: rc_status: command not found


Starting mouse support

X Window System Version 6.9.0
Release Date: 21 December 2005
X Protocol Version 11, Revision 0, Release 6.9
4096 MB Installed

ProLiant System BIOS - P64 (03/28/2009)
Copyright 1982, 2009 Hewlett-Packard Development Company, L.P.





Any suggestion hot to get Firmware 8.70
booted using PXE ?

TIA