Problem booting kernel from USB pen drive
Submitted by iang on Wed, 12/30/2009 - 20:07.
Hi,
I f*cked the partition table order on my netbook and now I get GRUB error 17. I want to use RR to fix this. Problem is I only have a Windows XP box in an Interet cafe to use.
I installed RR 9.10 r1 on a USB pen drive using USB-Installer-for-Ubuntu-v0.2 and it seemed to work well. But when I try to boot from the isolinux screeen (typing 'live' or just pressing return) I get an error "Could not find ramdisk image /casper/initrd.lz".
The file is /casper/initrd.gz so I edited the syslinux.cfg and it seems to work now.
Thanks for making such a neat little thing!!
Ciao
Ian

Hi Ian. Thanks for reporting
Hi Ian.
Thanks for reporting the problem - it's not my fault!
I downloaded that third-party application.
http://www.pendrivelinux.com/create-a-ubuntu-9-10-live-usb-in-windows/
Although the initrd in both the official iso image and the rescue-remix are in lz format, that installer copies them as gz. It also changes the text in the syslinux configuration file ("text.cfg") to look for the file named "initrd.gz"
(Original line from the iso image:
append file=/cdrom/preseed/ubuntu.seed boot=casper initrd=/casper/initrd.lz quiet splash --)
I don't know why it does that. It should leave both things alone. Anyway, that's why that third party application doesn't work. The remix doesn't use a text.cfg, just syslinux.cfg.
I am reporting the bug through the contact form at pendrivelinux.com and linking this threat.
Thanks again.
Andrew
Hello, Let me clarify,
Hello,
Let me clarify, USB-Installer-for-Ubuntu.exe was to be used to put Ubuntu 9.10 Desktop ISO on USB (as is stated in the tutorial). Not Ubuntu Rescue Remix or any other Ubuntu derivative.
Just as Linux Mint would use a different Installer. The tutorial is specific and the tool was used for installation outside of it's purpose.
The reason it changed the name of initrd.lz to .gz is to prevent breaking when the user performs an update, as a new initrd created after updating uses a .gz extension, not .lz when Ubuntu updates are performed.
I could make a third party USB installer specifically for Ubuntu Rescue
Remix if you want?
Hi Lance. Thanks for your
Hi Lance.
Thanks for your awesome tool. Thanks also for your quick response.
Yes, the USB-installer for Ubuntu is not made for a variant of Ubuntu and therefore this is not a true bug. But since a user reported the issue, I thought I should look into it.
I would love to include a tool such as this on the next release. My goal would be to make the next version of URR's iso image compatible with your Windows USB installer since the iso currently works with the Ubuntu one. If you are willing to make a custom Windows USB installer for the 9.10 version of Ubuntu-Rescue-Remix, I would certainly promote that on this site. But as I said, I wouldn't want to have to have a separate installer for future releases if I can avoid it. I am willing to work to ensure this functionality.
As for the actual incompatibility, I can't wrap my head around how the updated initrd gets out of the live system and onto the casper folder? How does the mkinitrd script edit the contents of the live USB drive? It can't do that? A new initrd will be created when a new kernel is installed within the live system (persistent data), but that will remain in the persistent data /boot directory. The user will continue to boot the kernel and initrd that was put on the USB stick during the install unless they change it "by hand".
Also, is this issue due to the initramfs scripts being outdated? Will Ubuntu 10.04 use initramfs-tools that will create .lz instead of .gz? If that's the case, then this problem will disappear on it's own...
Cheers!
Hi Andrew, Currently, at
Hi Andrew,
Currently, at least with Ubuntu 9.10, a new compresses initrd file is indeed created and copied to casper/ as initrd.gz when a kernel update is made. I have not studied the full magic behind this (probably utilizes a little Grub2 magic), but can verify it does work and a reboot into the new kernel from USB does as well. I should also state that I am not affiliated with Ubuntu or Canonical ltd in any way, and have no direct connection with the Ubuntu team of programmers. As such, I have no idea what changes 10.04 will bring.
As for a dedicated USB Installer for URR, I have created a specific installer (after our discussion to eliminate any confusion) and will post this tomorrow morning on pendrivelinux.com for you. It might be a really neat option to include the USB installer with your ISO build. This way, anyone could install URR to USB from Windows using the installer that is packaged with the ISO.
Feel free to let me know your thoughts and we can try to help make it happen.
Thanks for letting me explain,
Lance
Hi Lance. I'm trying to
Hi Lance.
I'm trying to reproduce what you described, but I can't seem to get it to work.
I booted an Ubuntu 9.10 disk and used the Ubuntu live cd USB creator to make a USB system with persistent data. I booted the USB and performed a kernel update. The kernel and initrd on the USB filesystem are unchanged after rebooting.
See here:
The new initrd was created on 2009-12-31 07:36
The old one was created on 2009-12-31 07:22
The old kernel is still the one that is in the casper folder on the USB drive.
And the kernel that was booted was the old one.
ubuntu@ubuntu:~$ ls -sh1tla /cdrom/casper
total 678M
3.8M -rwxr-xr-x 1 root root 3.8M 2009-12-31 07:22 vmlinuz
4.0K drwxr-xr-x 2 root root 4.0K 2009-12-31 07:22 .
5.5M -rwxr-xr-x 1 root root 5.5M 2009-12-31 07:22 initrd.lz
668M -rwxr-xr-x 1 root root 668M 2009-12-31 07:21 filesystem.squashfs
40K -rwxr-xr-x 1 root root 37K 2009-12-31 07:19 filesystem.manifest
36K -rwxr-xr-x 1 root root 35K 2009-12-31 07:19 filesystem.manifest-desktop
4.0K drwxr-xr-x 10 root root 4.0K 1970-01-01 00:00 ..
ubuntu@ubuntu:~$ ls -sh1tla /boot/
total 17M
4.0K drwxr-xr-x 33 ubuntu ubuntu 4.0K 2009-12-31 07:42 ..
4.0K drwxr-xr-x 4 root root 4.0K 2009-12-31 07:36 .
8.1M -rw-r--r-- 1 root root 8.1M 2009-12-31 07:36 initrd.img-2.6.31-16-generic
4.0K drwxr-xr-x 2 root root 4.0K 2009-12-31 07:29 grub
4.0K -rw-r--r-- 1 root root 1.2K 2009-12-08 08:05 vmcoreinfo-2.6.31-16-generic
620K -rw-r--r-- 1 root root 615K 2009-12-08 08:03 abi-2.6.31-16-generic
116K -rw-r--r-- 1 root root 109K 2009-12-08 08:03 config-2.6.31-16-generic
1.6M -rw-r--r-- 1 root root 1.6M 2009-12-08 08:03 System.map-2.6.31-16-generic
3.8M -rw-r--r-- 1 root root 3.8M 2009-12-08 08:03 vmlinuz-2.6.31-16-generic
126K -rw-r--r-- 1 root root 126K 2009-10-23 16:11 memtest86+.bin
1.5K -rw-r--r-- 1 root root 1.2K 2009-10-16 18:06 vmcoreinfo-2.6.31-14-generic
615K -rw-r--r-- 1 root root 615K 2009-10-16 18:03 abi-2.6.31-14-generic
109K -rw-r--r-- 1 root root 109K 2009-10-16 18:03 config-2.6.31-14-generic
1.6M -rw-r--r-- 1 root root 1.6M 2009-10-16 18:03 System.map-2.6.31-14-generic
ubuntu@ubuntu:~$ uname -a
Linux ubuntu 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:04:26 UTC 2009 i686 GNU/Linux
ubuntu@ubuntu:~$
I'll reboot again to see if that changes anything...
EDIT... No change. A kernel update from 2.6.31-14 to 2.6.31-16 doesn't really update the kernel that is booted on a live USB system with persistent data.
Hi Andrew, I should have
Hi Andrew,
I should have clarified that I was referring to performing updates via update manager "System > Administration > Update Manager" that affect the kernel version and trigger a rebuild of initrd!
If you currently perform the existing "Ubuntu 9.10" updates using "Update Manager" from a fresh USB install. A new "initrd.gz" is written to the casper/ folder.
Note that I am referring to updating "Ubuntu 9.10", not "Ubuntu Rescue Remix"
Here you go:
ubuntu@ubuntu:/cdrom/casper$ ls -sh1tla
total 680M
8.1M -rwxr-xr-x 1 root root 8.1M 2009-12-31 16:00 initrd.gz
3.8M -rwxr-xr-x 1 root root 3.8M 2009-12-31 16:00 vmlinuz
4.0K drwxr-xr-x 2 root root 4.0K 2009-10-28 15:14 .
668M -rwxr-xr-x 1 root root 668M 2009-10-28 15:13 filesystem.squashfs
40K -rwxr-xr-x 1 root root 37K 2009-10-28 15:09 filesystem.manifest
36K -rwxr-xr-x 1 root root 35K 2009-10-28 15:06 filesystem.manifest-desktop
4.0K drwxr-xr-x 10 root root 4.0K 1970-01-01 00:00 ..
ubuntu@ubuntu:/cdrom/casper$ uname -a
Linux ubuntu 2.6.31-16-generic #53-Ubuntu SMP Tue Dec 8 04:01:29 UTC 2009 i686 GNU/Linux
ubuntu@ubuntu:/cdrom/casper$
P.S. Andrew, are you receiving my email replies to your Ubuntu email address?
Hi Lance. Yes, I am using
Hi Lance.
Yes, I am using the Desktop version and not the Rescue Remix.
So I will reproduce this and track down where the update-manager/AddRemove software bug is. This is a real mess since two different things can happen by installing the exact same packages two different ways!
It should not create a .gz in the casper folder. If this problem is not already fixed in 10.04 (Lucid), I will file a bug if appropriate. I would really like there to be one Windows USB installer that works for both the Desktop iso as well as the rescue-remix iso.
I will keep you posted...
Also, your emails were being sent to my junk folder.... I just got them!
Regards,
Andrew
Ian and Andrew, As promised,
Ian and Andrew,
As promised, here is the Pendrivelinux tutorial containing a USB Installer for Ubuntu Rescue Remix 9.10
Specifically created for use with your current "ubuntu-rescue-remix-9-1-0-revision1.iso".
http://www.pendrivelinux.com/install-ubuntu-rescue-remix-to-a-flash-drive/
Let me know if you encounter any problems or would like to see any changes made.
Thanks,
Lance