LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   lilo -v hangs... (https://www.linuxquestions.org/questions/slackware-14/lilo-v-hangs-4175673995/)

however 04-26-2020 02:33 AM

lilo -v hangs...
 
good day everyone,

I have been upgrading my slackware -current box regularly and flawlessly.
Last night I left my box upgrading and when i woke up this morning i tried to call /sbin/lilo and it hangs on this message:

Quote:

bash-5.0# /sbin/lilo -v
LILO version 24.2 (released 22-November-2015)
* Copyright (C) 1992-1998 Werner Almesberger (until v20)
* Copyright (C) 1999-2007 John Coffman (until v22)
* Copyright (C) 2009-2015 Joachim Wiedorn (since v23)
This program comes with ABSOLUTELY NO WARRANTY. This is free software
distributed under the BSD License (3-clause). Details can be found in
the file COPYING, which is distributed with this software.

Warning: LBA32 addressing assumed
Reading boot sector from /dev/sda
and i cannot terminate the execution with "ctrl+c" or "ctrl+z". I have to close the console window.
This is my laptop and this is my "uname -a" and "/etc/lilo.conf" respectively:

Code:

bash-5.0# uname -a
Linux localhost.home 5.4.34 #1 SMP Tue Apr 21 14:55:26 CDT 2020 x86_64 Intel(R) Core(TM) i7-2720QM CPU @ 2.20GHz GenuineIntel GNU/Linux

Code:

# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
boot = /dev/sda

#compact        # faster, but won't work on all systems.

# Standard menu.
message = /boot/boot_message.txt

# Append any additional kernel parameters:
append=" "
#prompt
#timeout = 5
# Normal VGA console
vga = normal
# Ask for video mode at boot (time out to normal in 30s)
#vga = ask
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# ramdisk = 0    # paranoia setting
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
  root = /dev/sda1
  label = Slackware
  read-only  # Partitions should be mounted read-only for checking
# Linux bootable partition config ends

Now, I really do not know whether it is safe to turn the computer off and try to restart, as i am afraid (from past experience) that it won't boot up.

Could any kernel expert advise me on this? will slackware boot normally?

Thank you in advance

rkelsen 04-26-2020 03:26 AM

Quote:

Originally Posted by however (Post 6115966)
Last night I left my box upgrading and when i woke up this morning i tried to call /sbin/lilo

It won't help now, but check this out:

https://docs.slackware.com/howtos:sl...out_the_kernel

In particular, pay attention to the part in the yellow box.
Quote:

Originally Posted by however (Post 6115966)
and i cannot terminate the execution with "ctrl+c" or "ctrl+z". I have to close the console window.

Ok, that's bad... but should be repairable.

Tip: You can use LILO to make a menu for kernels to boot. I generally keep a stanza for old kernels in lilo.conf, so that the system will boot in the event that a new kernel doesn't work properly. This is shown in bold below.

Change your lilo.conf to look like this:

Code:

boot = /dev/sda
  bitmap = /boot/slack.bmp
  bmp-colors = 255,0,255,0,255,0
  bmp-table = 60,6,1,16
  bmp-timer = 65,27,0,255
lba32 # you need this... it's telling you.
prompt
timeout = 100
change-rules
  reset
vga = normal
image = /boot/vmlinuz-huge-5.4.35
  root = /dev/sda1
  label = Slackware
  read-only
image = /boot/vmlinuz-huge-5.4.34
  root = /dev/sda1
  label = old_kernel
  read-only

I'm sure I'll be shot down for saying this, but refer to the kernels directly... (i.e. not using symlinks).
Quote:

Originally Posted by however (Post 6115966)
Now, I really do not know whether it is safe to turn the computer off and try to restart, as i am afraid (from past experience) that it won't boot up.

In its current state, you might be correct. Please make the changes to your lilo.conf as shown. Note: When you run lilo, the -v switch is not necessary (it juts increases verbosity, but this is unnecessary since it reports problems anyway). So, after making your lilo.conf look like the above, please run (as root):
Code:

# lilo
And post the output here if it doesn't complete successfully.

however 04-26-2020 03:55 AM

Quote:

Originally Posted by rkelsen (Post 6115971)
So, after making your lilo.conf look like the above, please run (as root):
Code:

# lilo
And post the output here if it doesn't complete successfully.

Thnak you for the quick reply, however this puzzles me.

Would it make a difference at the next boot whether I have 1 label or 12 new&old kernel labels on lilo.conf, if I still can't run /sbin/lilo? Would I not have a kernel-panic message or a complete black screen at the next boot without even starting the bootloader?

If lilo would not run the first time why should it run after just adding a few lines to /etc/lilo.conf?
In fact, i tried anyway, and result: still hanging!

Code:

bash-5.0# lilo
Warning: LBA32 addressing assumed

still unable to end the process with ctrl+c or ctrl+z

Did I miss your point?

rkelsen 04-26-2020 04:28 AM

Quote:

Originally Posted by however (Post 6115978)
If lilo would not run the first time why should it run after just adding a few lines to /etc/lilo.conf?

Clearly not. Good luck. Remember, in a pinch you can use the installation medium to boot your system.

however 04-26-2020 06:20 AM

Quote:

Originally Posted by rkelsen (Post 6115988)
Clearly not. Good luck. Remember, in a pinch you can use the installation medium to boot your system.

Boot my system? or boot in to my system (boot installation media and then mount manually my partition accordingly)?

I tried to run the lilo setup running pkgtool from root console.
Lilo setup also hangs at
Quote:

Scanning for Linux Partitions
So, i suspected that something must have messed up my partitions layout; in fact when i run "kde Partition Manager" it won't read any partitions.

I really would like to know how this happened from 'slackpkg upgrade-all' but I am more interested to know if anyone has some hints on whether (and/or how) I will be able to reboot my box?

Thanks

however 04-26-2020 06:30 AM

UNREAL!
I solved the problem!
It seems that my external 2TB HHDD was causing conflicts.
I guessed it after running 'fdisk -l'; I noticed that it reads my internal HHD layout but hang again reading the external USB HHDD. Once I disconnected the USB hard drive lilo run beautifully.

rkelsen 04-26-2020 06:47 AM

Quote:

Originally Posted by however (Post 6116004)
Boot my system?

Yes, boot your system.

The instructions are on the screen which appears at the LILO prompt of the installer:

"Welcome to Slackware64 version 15.0 (Linux kernel 5.4.35)!

If you need to pass extra parameters to the kernel, enter them at the prompt
below after the name of the kernel to boot (e.g., huge.s).

In a pinch, you can boot your system from here with a command like:

boot: huge.s root=/dev/sda1 rdinit= ro


In the example above, /dev/sda1 is the / Linux partition."


Emphasis added.

Glad you fixed it.

bassmadrigal 04-27-2020 11:12 AM

@rkelsen, just an FYI, you don't *need* lba32, because lilo defaults to using it. The warning states that "LBA32 addressing assumed". Adding it does remove the warning, but that's about it.

rkelsen 04-27-2020 04:52 PM

lilo -v hangs...
 
Yeah, I know, but I hate being nagged. ;)


All times are GMT -5. The time now is 03:59 AM.