squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - Printable Version +- iPXE discussion forum (https://forum.ipxe.org) +-- Forum: iPXE user forums (/forumdisplay.php?fid=1) +--- Forum: General (/forumdisplay.php?fid=2) +--- Thread: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root (/showthread.php?tid=11132) |
squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - vigo332 - 2018-04-10 17:13 Hi, I am trying to chainload booting rhel server 7.4 from http to kickstart install the OS for my Lenovo thinkstation. I have the ipxe chainloaded correctly, the initrd and kernel are downloaded from my http server. However, the squashfs is not downloaded. I think ipxe used curl to download this. The install failed at the dracut-initqueue where it spit out the error of /dev/root is not located. The following script is chainloaded. #!ipxe echo Setting up the network interfaces ifopen echo Setting eth0 on MAC address ${eth0/mac} set net0/ip 192.168.56.130 set net0/netmask 255.255.255.0 set net0/gateway 192.168.56.254 ifstat echo Printing the routing table route echo Downloading image and kernel for chainloading from http://192.168.56.13/ftp/tree/isolinux initrd http://192.168.56.13/ftp/tree/isolinux/initrd.img kernel http://192.168.56.13/ftp/tree/isolinux/vmlinuz initrd=initrd.img inst.ks=http://192.168.56.13/ftp/ks_files/192.168.56.130.ks.cfg inst.repo=http://192.168.56.13/ftp/tree ro root=live:http://192.168.56.13/ftp/tree/LiveOS/squashfs.img rd.AUTO=1 rd_NO_LUKS LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 crashkernel=auto KEYBOARDTYPE=pc KEYTABLE=us rd.shell boot Note that I have my VirtualBox vm works without any problem using same script except for different ip and http server. Any suggestions are greatly appreciated. RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - NiKiZe - 2018-04-10 17:33 (2018-04-10 17:13)vigo332 Wrote: Hi, Note that nothing in that script downloads the squashfs in iPXE space, instead it is the rhel init script that does that with the special options that you have on the command line. double check that you have the correct urls, and also double check the http servers logs, especially error_log which shows any 404 issues or similar. RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - mcb30 - 2018-04-10 17:55 (2018-04-10 17:13)vigo332 Wrote: echo Setting eth0 on MAC address ${eth0/mac} If you are using a static IP address for iPXE, then you will also need to instruct the kernel/initrd to use a static IP address. By default, the RHEL initrd will attempt to use DHCP. I would recommend that you get DHCP working, so that you do not need to use a static IP address. Michael RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - vigo332 - 2018-04-10 17:59 Hi, NiKize, Thanks for replying. I checked the url and it was correct. I mounted the iso so from the relative url the squashfs is also correct. There was no error in the httpd log. in the access log, there are only the following three lines. 192.168.56.130 - - [09/Apr/2018:18:34:16 -0500] "GET /ftp/ipxe/lkrn/bootscript.ipxe HTTP/1.1" 200 755 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.130 - - [09/Apr/2018:18:34:16 -0500] "GET /ftp/tree/isolinux/initrd.img HTTP/1.1" 200 49763300 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.130 - - [09/Apr/2018:18:34:16 -0500] "GET /ftp/tree/isolinux/vmlinuz HTTP/1.1" 200 5875184 "-" "iPXE/1.0.0+ (8c17)" I also check the httpd log of the test vm. the squashfs.img was downloaded during the installation, please see the log of the vm. 192.168.56.155 - - [05/Apr/2018:17:27:22 -0500] "GET /ftp/ipxe/myscript.ipxe HTTP/1.1" 200 743 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.1 - - [05/Apr/2018:17:27:25 -0500] "GET /ftp/tree/isolinux/initrd.img HTTP/1.1" 200 49763300 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.1 - - [05/Apr/2018:17:27:26 -0500] "GET /ftp/tree/isolinux/vmlinuz HTTP/1.1" 200 5875184 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.1 - - [05/Apr/2018:17:28:40 -0500] "GET /ftp/tree/LiveOS/squashfs.img HTTP/1.1" 200 347414528 "-" "curl/7.29.0" 192.168.56.1 - - [05/Apr/2018:17:28:45 -0500] "GET /ftp/tmp/test-ks.cfg HTTP/1.1" 200 2003 "-" "curl/7.29.0" 192.168.56.155 - - [05/Apr/2018:17:29:04 -0500] "GET /ftp/tree/.treeinfo HTTP/1.1" 200 1900 "-" "urlgrabber/3.10" 192.168.56.155 - - [05/Apr/2018:17:29:04 -0500] "GET /ftp/tree/repodata/repomd.xml HTTP/1.1" 200 4184 "-" "Red Hat Enterprise Linux (anaconda)/7.4 yum/3.4.3" 192.168.56.155 - - [05/Apr/2018:17:29:04 -0500] "GET /ftp/tree/.treeinfo HTTP/1.1" 200 1900 "-" "urlgrabber/3.10" 192.168.56.155 - - [05/Apr/2018:17:29:04 -0500] "GET /ftp/tree/repodata/a5d74c9954ba24288d9b7e80c6124b7d7f57f760de81763c25022384078d290e-primary.xml.gz HTTP/1.1" 200 2011052 "-" "Red Hat Enterprise Linux (anaconda)/7.4 yum/3.4.3" 192.168.56.155 - - [05/Apr/2018:17:29:04 -0500] "GET /ftp/tree/repodata/9c36ffa7133f0a1d973e3f4a323fae9cdf9463d5a7eec37fbf3e3824ffd9c78c-comps-Server.x86_64.xml.gz HTTP/1.1" 200 140761 "-" "Red Hat Enterprise Linux (anaconda)/7.4 yum/3.4.3" 192.168.56.155 - - [05/Apr/2018:17:29:04 -0500] "GET /ftp/tree/repodata/35b2bd4d785b1be1a4aa6ac9a2c89903f20a6e4fc428af1fdac6e4df3bd75048-primary.sqlite.bz2 HTTP/1.1" 200 4212131 "-" "Red Hat Enterprise Linux (anaconda)/7.4 yum/3.4.3" 192.168.56.155 - - [05/Apr/2018:17:29:06 -0500] "GET /ftp/tree//repodata/repomd.xml HTTP/1.1" 200 4184 "-" "urlgrabber/3.10" 192.168.56.155 - - [05/Apr/2018:17:29:30 -0500] "GET /ftp/tree/Packages/libXext-1.3.3-3.el7.x86_64.rpm HTTP/1.1" 206 9316 "-" "urlgrabber/3.10 yum/3.4.3" 192.168.56.155 - - [05/Apr/2018:17:29:31 -0500] "GET /ftp/tree/Packages/perl-HTTP-Tiny-0.033-3.el7.noarch.rpm HTTP/1.1" 206 4652 "-" "urlgrabber/3.10 yum/3.4.3" 192.168.56.155 - - [05/Apr/2018:17:29:31 -0500] "GET /ftp/tree/Packages/yum-rhn-plugin-2.0.1-9.el7.noarch.rpm HTTP/1.1" 206 31396 "-" "urlgrabber/3.10 yum/3.4.3" 192.168.56.155 - - [05/Apr/2018:17:29:31 -0500] "GET /ftp/tree/Packages/libXrender-0.9.10-1.el7.x86_64.rpm HTTP/1.1" 206 7896 "-" "urlgrabber/3.10 yum/3.4.3" 192.168.56.155 - - [05/Apr/2018:17:29:31 -0500] "GET /ftp/tree/Packages/perl-devel-5.16.3-292.el7.x86_64.rpm HTTP/1.1" 206 52200 "-" "urlgrabber/3.10 yum/3.4.3" Hi, Michael, Thanks for the note. Unfortunately, I have to use static IP. But it works on the VMs. My test vm is pulling everything from the other vm using static ip. Are there any more work to do with the real workstation than the vm? RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - vigo332 - 2018-04-10 20:01 Some more information In dracut emergency shell, in the dracut-state.sh, the root is set livenet and the address is correct. But the squashfs.img was not downloaded from the httpd log, not to say the kickstart file and the repo packages. Thanks RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - mcb30 - 2018-04-10 20:22 (2018-04-10 17:59)vigo332 Wrote: My test vm is pulling everything from the other vm using static ip. No it isn't. Since you are not providing any static IP information to the booted kernel+initrd, it cannot be using a static IP address. Most probably your VM host is providing a DHCP service to the VMs; this will explain why it works for your VM but not for your real hardware. Most VM hosting services will do this automatically by default. Michael RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - vigo332 - 2018-04-10 20:41 Hmmm, each of my VMs has two interfaces. one is the NAT network dhcp the other is host-only network, static The http server serving the OS tree is 192.168.56.150. The efi of the installation vm is built with net0 dhcp and net1 192.168.56.155. It is chaining the ipxe script on net1 interface as from the log . 192.168.56.155 - - [05/Apr/2018:17:27:22 -0500] "GET /ftp/ipxe/myscript.ipxe HTTP/1.1" 200 743 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.1 - - [05/Apr/2018:17:27:25 -0500] "GET /ftp/tree/isolinux/initrd.img HTTP/1.1" 200 49763300 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.1 - - [05/Apr/2018:17:27:26 -0500] "GET /ftp/tree/isolinux/vmlinuz HTTP/1.1" 200 5875184 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.1 - - [05/Apr/2018:17:28:40 -0500] "GET /ftp/tree/LiveOS/squashfs.img HTTP/1.1" 200 347414528 "-" "curl/7.29.0" 192.168.56.1 - - [05/Apr/2018:17:28:45 -0500] "GET /ftp/tmp/test-ks.cfg HTTP/1.1" 200 2003 "-" "curl/7.29.0" 192.168.56.155 - - [05/Apr/2018:17:29:04 -0500] "GET /ftp/tree/.treeinfo HTTP/1.1" 200 1900 "-" "urlgrabber/3.10" I also noticed the strange thing the ipxe script was chained from vm ip 56.155. But the initrd vmlinuz squashfs and kickstart file were pulled from the virtualbox gateway! How to explain the .treeinfo was pull from the correct static ip? The hostonly network in the virtualbox is not running any dhcp . The chained ipxe script also sets the two network interface dhcp on net0 and static on net1. My real workstation only has one network interface active, 10G network, the net0 is set using static ip (dhcp is not possible). But you can see that the workstation is pulling the bootscript.ipxe, initrd.img and vmlinuz from a physical http server in the same network (56.13). 192.168.56.130 - - [09/Apr/2018:18:34:16 -0500] "GET /ftp/ipxe/lkrn/bootscript.ipxe HTTP/1.1" 200 755 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.130 - - [09/Apr/2018:18:34:16 -0500] "GET /ftp/tree/isolinux/initrd.img HTTP/1.1" 200 49763300 "-" "iPXE/1.0.0+ (8c17)" 192.168.56.130 - - [09/Apr/2018:18:34:16 -0500] "GET /ftp/tree/isolinux/vmlinuz HTTP/1.1" 200 5875184 "-" "iPXE/1.0.0+ (8c17)" Are you saying that when dracut tried to using the vmlinuz, another kernel argument should be specified like ip=192.168.56.130::192.168.56.254:255.255.255.0:localhost:enp0s3::8192 to set the new kernel's network? After this, the new kernel can then pull the squashfs and mount it? RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - mcb30 - 2018-04-10 20:50 You need to either set up DHCP to provide an address for the physical machine, or add kernel command line parameters to cause it to use a static IP address. Michael RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - vigo332 - 2018-04-10 21:19 Succeeded by using the following ipxe script. Need to specify the correct network interface name. #!ipxe echo Setting up the network interfaces ifopen echo Setting eth0 on MAC address ${eth0/mac} set net0/ip 192.168.56.130 set net0/netmask 255.255.255.0 set net0/gateway 192.168.56.254 ifstat echo Printing the routing table route echo Downloading image and kernel for chainloading from http://192.168.56.13/ftp/tree/isolinux initrd http://192.168.56.13/ftp/tree/isolinux/initrd.img kernel http://192.168.56.13/ftp/tree/isolinux/vmlinuz initrd=initrd.img inst.ks=http://192.168.56.13/ftp/ks_files/192.168.56.130.ks.cfg ip=192.168.56.130::192.168.56.254:255.255.255.0:biohpcwsc130:ens4f0:none:8192 inst.repo=http://192.168.56.13/ftp/tree ro root=live:http://192.168.56.13/ftp/tree/LiveOS/squashfs.img rd.AUTO=1 rd_NO_LUKS LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 crashkernel=auto KEYBOARDTYPE=pc KEYTABLE=us rd.shell boot Thanks Michael and NikiZe. You guys make my life easier. I now have another problem with it. For the VM, after the kickstart installation is finished. it boots to the new rhel7.4 kernel with no problem. But for the workstation, it is still using the old grub legacy chaining the ipxe script, not grub2 comes with the rhel7.4. It keeps installing the OS again and again. The vm uses the new grub2 and changed the default booting kernel. I tried to interrupt to boot the the older rhel6 kernel, but get the following error [!!!!!!] Failed to allocate manager object, freezing. THanks RE: squashfs cannot be downloaded when ipxe chainloading, dracut-initqueue fail find root - mcb30 - 2018-04-10 23:00 (2018-04-10 21:19)vigo332 Wrote: It keeps installing the OS again and again. You can add a line to your iPXE script to cause it to exit (instead of running the installer) unless a key is pressed. For example: Code: prompt --key 0x197e --timeout 2000 Press F12 to install RHEL... || exit For more details, see http://ipxe.org/cmd/prompt. Michael |