Linux From ScratchThis Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm trying to add LFS to two other grub installs on my /menu.list, but
can't get grub to find /boot/lfskernel-2.6.27.4.
Code:
grub> root (hd0,3)
Filesystem type is ext2fs, partition type 0x83
grub> kernel /boot/lfskernel-2.6.27.4
Error 15: File not found
grub> find (hd0,3)/boot/lfskernel-2.6.27.4
Error 15: File not found
I'm trying to avoid overwriting my current MBR, and had no luck with
"setup (hd0,3)"
So,
does it appear immediatly after you hit the tab button?
yes
Quote:
The boot directory you are using is the same used for booting other linux distro?
Could you please give the following commands and post the result?
When you are in front of the Grub prompt:
grub>
If you installed a /boot partition:
Code:
find /grub/stage1
If you did not do a /boot partition:
Code:
find /boot/grub/stage1
A separate partition was created for LFS/ with it's own boot directory.
The partition is recognized (e.g., grub > root (hda0,3), but the boot partition is not. This appears to be the issue.
Code:
grub> find /boot/grub/stage1
(hd0,0)
I would like to add LFS to my current /boot/grub/menu.lst with:
Code:
# Linux bootable partition config begins
title TinyCoreLinux on hda3 (tce=hda3)
kernel (hd0,2)/tinycore/bzimage quiet restore=hda3/tc_backup nolocal tce=hda3/tcZ max_loop=55
initrd (hd0,2)/tinycore/tinycore.gz
# Linux bootable partition config ends
#Linux bootable partition config begins
title LFS 6.4
root (hd0,3)
kernel (hd0,3}/boot/lfskernel-2.6.27.4 root=/dev/hda4
right...that was just a typo. I transferred everything out of /boot
into another folder /lfs, and had more success....at least it found the file. It also booted bzImage, copied from the /arch/boot directory. This presents a new bag of problems, however, in that it doesn't accept 'root=/dev/hda4', resulting in kernel panic
bzImage can replace the lfskernal file, with same result. I didn't try initrd since that seems to be used for opening packaged directory files (eg lfs.gz).
Code:
# GRUB configuration file '/boot/grub/menu.lst'.
# generated by 'grubconfig'. Tue Jun 17 00:30:55 2008
#
# Start GRUB global section
#timeout 30
color light-gray/blue black/light-gray
# End GRUB global section
# Linux bootable partition config begins
title Puppy Linux 400 frugal
rootnoverify (hd0,0)
kernel /puppy400/vmlinuz pmedia=idehd psubdir=puppy400
initrd /puppy400/initrd.gz
# Linux bootable partition config ends
# Linux bootable partition config begins
title TinyCoreLinux on hda3 (tce=hda3)
kernel (hd0,2)/tinycore/bzimage quiet restore=hda3/tc_backup nolocal tce=hda3/t
initrd (hd0,2)/tinycore/tinycore.gz
# Linux bootable partition config ends
#Linux bootable partition config begins
title LFS 6.4
root (hd0,3)
kernel (hd0,3)/lfs/lfs/lfskernel-2.6.27.4 root=/dev/hda4
# Linux bootable partition config ends
- menu.lst [Readonly] 1/36 2%
I had a kernel panic like yours when some months ago I used a kernel where the ext2 file system hadn't been compiled into the kernel image (it was compiled as a module, that's a case when you have to use a initial ramdisk file i.e. initrd.gz ).
I still don't understand why the system doesn't like your "boot" directory as it does with the "lfs" dir: do they have the same permission set (the same chmod)?
There's probably no need to install another grub if using a previous installation, and there was some confusion with having two boot directories. Also, it seems necessary to configure the kernel with ext2/ext3 support for devices to be recognized. Since I already have a correctly configured kernel (same version) on puppy, I decided to simply use that one. Presently, it gets stuck with error "Unable to mount root fs on unknown block (0,13)."
I've screwed around with an initrd file, booting from other partitions, etc., etc., but so far I've yet to uncover all the mysteries of grub.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.