Ha, too slow Tomas! You can't keep up with the WPM on my new Thinkpad! But you got it more or less right. However the process is still relevant for grub and UEFI when performing the initial installation. Also there are several more chroots required for this particular situation. A single chroot by itself does not populate /dev, /sys, or /proc so for certain tasks you need to set up some special mounts within a mount and before it will actually work.
On Sat, Nov 24, 2018 at 5:56 PM Tomas K <[email protected]> wrote: > chroot command simply sets different root directory for a command - > thus that command: > a) sees different root directory > b) cannot access anything outside that directory (aka chroot jail) > > Example: > 1. Imagine you just mounted: > mount /dev/sda2 /mnt/hd > 2. Executing: > sudo chroot /mnt/hd /bin/bash > will execute bash from inside /mnt/hd (running /mnt/hd/bin/bash) > as if you would have booted from there > > What Ben, most likely, wants to guide you through is running lilo as if > booted from the disk mounted on /mnt/hd - thus updating the Lilo > config. > > I will not guess further because I forgot most things about Lilo long > time ago. The Linuxes I use boot using Grub for long time and/or boot > using UEFI directly these days. > > Hope it makes sense. > Tomas > > On Sat, 2018-11-24 at 17:26 -0800, Dick Steffens wrote: > > On 11/25/18 5:06 PM, Ben Koenig wrote: > > > Ah ok. I think I know what is happening. > > > > > > I'm assuming here that your filesystem on /dev/sda2 is functional > > > and has a > > > working install of Slackware. A quick description of the LILO > > > setup. > > > > > > lilo.conf sets up the configuration for the bootloader. However, > > > after > > > creating your config you have to run the lilo command to upload > > > your > > > kernel, initrd, and the bootloader itself to your MBR. > > > > > > Your file looks correct, however it still fails to find your root > > > filesystem. I'm hoping this is because lilo was run before you > > > finished > > > your config, which means all we need to do is run it again :-) > > > > > > To do this, you want to boot the live media again, and manually > > > mount sda2 > > > with the following command (as root): > > > mount /dev//sda2 /mnt/hd > > > > > > Now you can list the contents of /mnt/hd/ > > > /mnt/hd/ is a default folder in slackware that you can use for > > > recovery > > > jobs such as this. Temporary mounts here will not interrupt the > > > system. At > > > this point you should verify the existence of the init program with > > > the > > > following command: > > > > > > $ ls /mnt/hd/sbin/init > > > /sbin/init* > > > > > > The error you are getting is referring to that file. When the > > > kernel boots, > > > it mounts the rootfs as defined by lilo and then runs /sbin/init. > > > If init > > > does not exist, no init found. > > > I'm pretty sure you have /sbin/init, but it doesn't hurt to double > > > check. > > > Assuming it is still there then we need to do a quick chroot and > > > re-run > > > lilo. > > > > > > Go ahead and boot live, mount sda2 as described above and verify > > > that > > > /sbin/init exists. > > > > bash-4.4# mount /dev//sda2 /mnt/hd > > bash-4.4# ls /mnt/hd/sbin/init > > /mnt/hd/sbin/init > > > > Also confirmed that I see it with ls /mnt/hd/sbin. > > > The next step after that is a chroot and I need to go > > > look those commands up because I can never remember them off the > > > top of my > > > head. > > > We know why it doesn't want to boot, so all we need to do now is > > > fix it. :) > > > > I appreciate your help. I've heard of chroot, but never had it > > explained > > in a form I actually understood. > > > _______________________________________________ > PLUG mailing list > [email protected] > http://lists.pdxlinux.org/mailman/listinfo/plug > _______________________________________________ PLUG mailing list [email protected] http://lists.pdxlinux.org/mailman/listinfo/plug
