Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

Help! I'm trapped in a PDP 11/70!


computers / alt.os.linux.slackware / Re: Liveslak vs USBinstall and lost boot sector

SubjectAuthor
* Liveslak vs USBinstall and lost boot sectorroot
+* Re: Liveslak vs USBinstall and lost boot sectorMike Small
|`* Re: Liveslak vs USBinstall and lost boot sectorroot
| `- Re: Liveslak vs USBinstall and lost boot sectorRich
+* Re: Liveslak vs USBinstall and lost boot sectorHenrik Carlqvist
|`* Re: Liveslak vs USBinstall and lost boot sectorroot
| `- Re: Liveslak vs USBinstall and lost boot sectorHenrik Carlqvist
+* Re: Liveslak vs USBinstall and lost boot sectornoel
|`* Re: Liveslak vs USBinstall and lost boot sectorroot
| +- Re: Liveslak vs USBinstall and lost boot sectorroot
| `- Re: Liveslak vs USBinstall and lost boot sectorJim Diamond
`- Re: Liveslak vs USBinstall and lost boot sectorJoseph Rosevear

1
Liveslak vs USBinstall and lost boot sector

<tua9l7$v4nn$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1655&group=alt.os.linux.slackware#1655

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: NoEM...@home.org (root)
Newsgroups: alt.os.linux.slackware
Subject: Liveslak vs USBinstall and lost boot sector
Date: Wed, 8 Mar 2023 15:29:43 -0000 (UTC)
Organization: Linux Advocacy
Lines: 35
Message-ID: <tua9l7$v4nn$1@dont-email.me>
Injection-Date: Wed, 8 Mar 2023 15:29:43 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="05707b9062ff2cd6332b63982abe1cf3";
logging-data="1020663"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+2kkbRkQ3oLl+Hri+A50xGwJzF+B6Vau0="
User-Agent: slrn/1.0.2 (Linux)
Cancel-Lock: sha1:WVLgScKcIb1+7e+lV1w3/I4iqac=
Mail-Copies-To: nobody
 by: root - Wed, 8 Mar 2023 15:29 UTC

Over the years I could not count the number of times that one of
my machines which uses lilo has lost its boot sector. I use grub now
in my main machine, but I have a number of machines for which I
am responsible which still run lilo. Yesterday a friend's machine
lost its boot sector and I want to tell how I solved the problem
and ask if there was a better way.

The machine with the lost boot sector had been running 14.2
for several years. The owner who lives over 100 miles from
me brought the machine to me. I booted the machine with
a liveslak drive. The operational partition on the drive was
sda2. I followed these steps:

mkdir /sda2

cp /sda2/boot/vmlinuz /boot

mount /dev/sda2 /sda2
mount --bind /dev /sda2/dev
/dev/sda2/sbin/lilo -r /sda2
sync
umount /sda2

and the affected machine was able to boot.

This process could be simplified if liveslak
or an install usb could track slackpkg updates.
If, over time, slackpkg updates the kernel the
original install disk cannot be used to get
into the system. Similarly, the liveslak kernel
would not match the kernel on the affected system.

What would you have done apart from switching to grub?

Re: Liveslak vs USBinstall and lost boot sector

<jpkzg8nnrcn.fsf@panix5.panix.com>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1656&group=alt.os.linux.slackware#1656

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!panix!.POSTED.panix5.panix.com!not-for-mail
From: sma...@panix.com (Mike Small)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Wed, 08 Mar 2023 11:24:40 -0500
Organization: PANIX Public Access Internet and UNIX, NYC
Message-ID: <jpkzg8nnrcn.fsf@panix5.panix.com>
References: <tua9l7$v4nn$1@dont-email.me>
Mime-Version: 1.0
Content-Type: text/plain
Injection-Info: reader2.panix.com; posting-host="panix5.panix.com:166.84.1.5";
logging-data="18068"; mail-complaints-to="abuse@panix.com"
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (berkeley-unix)
Cancel-Lock: sha1:jSOvC7hNMxJDaM/Tl4tufu53xDg=
 by: Mike Small - Wed, 8 Mar 2023 16:24 UTC

root <NoEMail@home.org> writes:

> Over the years I could not count the number of times that one of
> my machines which uses lilo has lost its boot sector. I use grub now
....
> sda2. I followed these steps:
>
> mkdir /sda2
>
> cp /sda2/boot/vmlinuz /boot
>
> mount /dev/sda2 /sda2
> mount --bind /dev /sda2/dev
> /dev/sda2/sbin/lilo -r /sda2
> sync
> umount /sda2
>
>
> and the affected machine was able to boot.
....
>
> What would you have done apart from switching to grub?

Backing up the boot sector (mental note, back up my boot sectors) to a
filesystem -- I prefer / to make it easy to find -- each time it changes
would reduce your recovery to...

dd if=/boot.sector.backup of=/dev/sda bs=512 count=1

I would back it up only to a filesystem on the hard drive where it
exists. The usual considerations for backups motivating a separate drive
or off site copy don't apply. You want only the most recent (non-corrupt
-- a gotcha there?) bytes. If the drive goes, the root file system
corrupts or is wiped, or if your apartment burns down then the sector is
no longer useful.

Using grub the backup is slightly more complicated. Its first stage
lives where exactly? Somewhere between the MBR boot sector and the
first sector of the first partition? So dd out some number of the first
N sectors up to but not including the beginning of the first partition?
Or up to and including its PBR if you use and want to preserve that?
Off by one errors here could be really annoying.

One thing I've been doing is to make each operating system on my disk
boot from its PBR if possible. So Slackware 14.2 (I have 15.0 on
another machine with no multibooting and a GPT partition table) boots
with lilo from its PBR. Grub is set up from Debian using all the gunk
they have to detect everything and create boot entries, these being
bootable directly from the Grub installed in the MBR + early sectors.
My custom Grub configuration includes chain loaders to Slackware and
NetBSD's PBR bootloaders. I also have an inactive Grub configuration on
the Slackware partition that is, I hope, more or less up to date, in
case I erased Debian. The Slackware PBR would be bootable with a simple
fdisk /mbr and active flag if needed. Once into the Slackware area (via
lilo on the PBR) I could run grub-mkconfig to get the other things
booting again. So there's some redundancy but probably too much
complexity.

There's also grub-mkrescue.

- Mike Sm.

Re: Liveslak vs USBinstall and lost boot sector

<tuajnh$11cg9$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1657&group=alt.os.linux.slackware#1657

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: NoEM...@home.org (root)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Wed, 8 Mar 2023 18:21:38 -0000 (UTC)
Organization: Linux Advocacy
Lines: 55
Message-ID: <tuajnh$11cg9$1@dont-email.me>
References: <tua9l7$v4nn$1@dont-email.me> <jpkzg8nnrcn.fsf@panix5.panix.com>
Injection-Date: Wed, 8 Mar 2023 18:21:38 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="05707b9062ff2cd6332b63982abe1cf3";
logging-data="1094153"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX194G3MwYBauL8q2XoiLh6FjLo20vDA6KXU="
User-Agent: slrn/1.0.2 (Linux)
Cancel-Lock: sha1:GVmYzGQGyUr4SDxFWto7VKxbIbk=
 by: root - Wed, 8 Mar 2023 18:21 UTC

Mike Small <smallm@panix.com> wrote:
> root <NoEMail@home.org> writes:
>
> Backing up the boot sector (mental note, back up my boot sectors) to a
> filesystem -- I prefer / to make it easy to find -- each time it changes
> would reduce your recovery to...
>
> dd if=/boot.sector.backup of=/dev/sda bs=512 count=1
>
> I would back it up only to a filesystem on the hard drive where it
> exists. The usual considerations for backups motivating a separate drive
> or off site copy don't apply. You want only the most recent (non-corrupt
> -- a gotcha there?) bytes. If the drive goes, the root file system
> corrupts or is wiped, or if your apartment burns down then the sector is
> no longer useful.

I can't be sure to make such a backup when I am doing something that
involves the boot sector indirectly. Moreover, I would still have to
use Liveslak or something else to mount the drive and perform
the dd restoration.

>
> Using grub the backup is slightly more complicated. Its first stage
> lives where exactly? Somewhere between the MBR boot sector and the
> first sector of the first partition? So dd out some number of the first
> N sectors up to but not including the beginning of the first partition?
> Or up to and including its PBR if you use and want to preserve that?
> Off by one errors here could be really annoying.

When I lose the grub boot sector I fall back to a fixed set of
commands which I keep on a file card under my monitor (which I
can't seem to find now so I can't reveal the commands).
>
> One thing I've been doing is to make each operating system on my disk
> boot from its PBR if possible. So Slackware 14.2 (I have 15.0 on
> another machine with no multibooting and a GPT partition table) boots
> with lilo from its PBR. Grub is set up from Debian using all the gunk
> they have to detect everything and create boot entries, these being
> bootable directly from the Grub installed in the MBR + early sectors.
> My custom Grub configuration includes chain loaders to Slackware and
> NetBSD's PBR bootloaders. I also have an inactive Grub configuration on
> the Slackware partition that is, I hope, more or less up to date, in
> case I erased Debian. The Slackware PBR would be bootable with a simple
> fdisk /mbr and active flag if needed. Once into the Slackware area (via
> lilo on the PBR) I could run grub-mkconfig to get the other things
> booting again. So there's some redundancy but probably too much
> complexity.

I don't understand most of the previous paragraph.
>
> There's also grub-mkrescue.
>
> - Mike Sm.

Thanks for responding Mike.

Re: Liveslak vs USBinstall and lost boot sector

<tuan61$121sh$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1659&group=alt.os.linux.slackware#1659

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: ric...@example.invalid (Rich)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Wed, 8 Mar 2023 19:20:33 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 32
Message-ID: <tuan61$121sh$1@dont-email.me>
References: <tua9l7$v4nn$1@dont-email.me> <jpkzg8nnrcn.fsf@panix5.panix.com> <tuajnh$11cg9$1@dont-email.me>
Injection-Date: Wed, 8 Mar 2023 19:20:33 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="6a769493ae2001540881470f1c0e6205";
logging-data="1116049"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19XYJzcTVBpBwO+mSetW+8z"
User-Agent: tin/2.0.1-20111224 ("Achenvoir") (UNIX) (Linux/3.10.17 (x86_64))
Cancel-Lock: sha1:uJ3uSUHpV64fhSBeUa28kkB/Sbk=
 by: Rich - Wed, 8 Mar 2023 19:20 UTC

root <NoEMail@home.org> wrote:
> Mike Small <smallm@panix.com> wrote:
>> root <NoEMail@home.org> writes:
>>
>> Backing up the boot sector (mental note, back up my boot sectors) to
>> a filesystem -- I prefer / to make it easy to find -- each time it
>> changes would reduce your recovery to...
>>
>> dd if=/boot.sector.backup of=/dev/sda bs=512 count=1
>>
>> I would back it up only to a filesystem on the hard drive where it
>> exists. The usual considerations for backups motivating a separate
>> drive or off site copy don't apply. You want only the most recent
>> (non-corrupt -- a gotcha there?) bytes. If the drive goes, the root
>> file system corrupts or is wiped, or if your apartment burns down
>> then the sector is no longer useful.
>
> I can't be sure to make such a backup when I am doing something that
> involves the boot sector indirectly.

But you can, if you want, setup a cron job to periodically do the dd
copy of the boot sector to a file every X units of time. You can even
choose to store the last Y copies (date/time stamped) or all copies
ever made (again, date/time stamped). Then you don't have to
'remember' to make the backup, it just happens for you automatically.

> Moreover, I would still have to use Liveslak or something else to
> mount the drive and perform the dd restoration.

True. But you have to do that to recover from a lost boot sector
anyway, so no different there.

Re: Liveslak vs USBinstall and lost boot sector

<tuatcn$12vp9$3@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1663&group=alt.os.linux.slackware#1663

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: Henrik.C...@deadspam.com (Henrik Carlqvist)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Wed, 8 Mar 2023 21:06:31 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 63
Message-ID: <tuatcn$12vp9$3@dont-email.me>
References: <tua9l7$v4nn$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Wed, 8 Mar 2023 21:06:31 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="41246fbb4f387cbc2d548f1213b9b09e";
logging-data="1146665"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18uVDyY5zfOjT1HkTiUhNM6"
User-Agent: Pan/0.139 (Sexual Chocolate; GIT bf56508
git://git.gnome.org/pan2)
Cancel-Lock: sha1:po4NLtzGCMkiZksP3fWqSJ5UPg8=
 by: Henrik Carlqvist - Wed, 8 Mar 2023 21:06 UTC

On Wed, 08 Mar 2023 15:29:43 +0000, root wrote:

> Over the years I could not count the number of times that one of my
> machines which uses lilo has lost its boot sector.

Even if the boot sector is OK, the position it points to where the kernel
should be might no longer be valid.

> The machine with the lost boot sector had been running 14.2 for several
> years. The owner who lives over 100 miles from me brought the machine to
> me. I booted the machine with a liveslak drive. The operational
> partition on the drive was sda2. I followed these steps:
>
> mkdir /sda2
>
> cp /sda2/boot/vmlinuz /boot
>
> mount /dev/sda2 /sda2
> mount --bind /dev /sda2/dev
> /dev/sda2/sbin/lilo -r /sda2
> sync
> umount /sda2
>
>
> and the affected machine was able to boot.

I guess that you did mount /sda2 before copying its kernel to /boot?
However, I don't see any need to copy the kernel. Simply do:

mkdir /sda2
mount /dev/sda2 /sda2
/dev/sda2/sbin/lilo -r /sda2

> This process could be simplified if liveslak or an install usb could
> track slackpkg updates.
> If, over time, slackpkg updates the kernel the original install disk
> cannot be used to get into the system. Similarly, the liveslak kernel
> would not match the kernel on the affected system.

It does not matter if you choose some rescue media like syslinux, knoppix
or the Slackware installation media with a completely different kernel.
Lilo does not care if the running kernel differs from the kernel lilo is
supposed to boot. You can even write lilo configuration files which allow
you to choose between many different kernels.
> What would you have done apart from switching to grub?

Your choice of bootloader does not matter. The important thing that
matters is the text in the changelog when a new kernel package is
released by Slackware:

-8<--------------------------------------------
Be sure to upgrade your initrd after upgrading the kernel packages.
If you use lilo to boot your machine, be sure lilo.conf points to the
correct kernel and initrd and run lilo as root to update the bootloader.
If you use elilo to boot your machine, you should run eliloconfig to copy
the kernel and initrd to the EFI System Partition.
-8<--------------------------------------------

You will need to update your bootloader, you can do it the easy way or
you can do it the hard way with some friend using a rescue media.

regards Henrik

Re: Liveslak vs USBinstall and lost boot sector

<6409968c@news.ausics.net>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1666&group=alt.os.linux.slackware#1666

  copy link   Newsgroups: alt.os.linux.slackware
From: deletet...@invalid.lan (noel)
Subject: Re: Liveslak vs USBinstall and lost boot sector
Newsgroups: alt.os.linux.slackware
References: <tua9l7$v4nn$1@dont-email.me>
X-No-Archive: Yes
User-Agent: Pan/0.141 (Tarzan's Death; 168b179 git.gnome.org/pan2)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
NNTP-Posting-Host: news.ausics.net
Message-ID: <6409968c@news.ausics.net>
Date: 9 Mar 2023 18:19:24 +1000
Organization: Ausics - https://www.ausics.net
Lines: 19
X-Complaints: abuse@ausics.net
Path: i2pn2.org!rocksolid2!news.neodome.net!csiph.com!news.bbs.nz!news.ausics.net!not-for-mail
 by: noel - Thu, 9 Mar 2023 08:19 UTC

On Wed, 08 Mar 2023 15:29:43 +0000, root wrote:

> Over the years I could not count the number of times that one of my
> machines which uses lilo has lost its boot sector. I use grub now in my

Strange, never had a lilo boot failure (that wasnt caused by operator
error in nearly 30 years)

I only use lilo, 99% of that is and has been slackware (we did have some
redhat (not rhel or clone, not fedora or clone, but the original) back in
the 90's because some software only supported it and they refused to give
out source, I'm sure they had a a floor load of laywers actively
protecting their crappy trademark software LOL, over all that/this time
thats thousands of servers, from a top 3 national ISP, to fair-sized web
hosting company

Dunno what you're doing to poor lilo.

Re: Liveslak vs USBinstall and lost boot sector

<tueo5e$1slfi$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1668&group=alt.os.linux.slackware#1668

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: NoEM...@home.org (root)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Fri, 10 Mar 2023 08:01:50 -0000 (UTC)
Organization: Linux Advocacy
Lines: 58
Message-ID: <tueo5e$1slfi$1@dont-email.me>
References: <tua9l7$v4nn$1@dont-email.me> <tuatcn$12vp9$3@dont-email.me>
Injection-Date: Fri, 10 Mar 2023 08:01:50 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="e94bfaa5ade73f62c357b7a91cc7e7b9";
logging-data="1988082"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX187ysCE7QIWIHc4ms4v5mNWGcPqJgHndEk="
User-Agent: slrn/1.0.2 (Linux)
Cancel-Lock: sha1:yKsG0dZrF7YlbCmx6kkQGIJxIhk=
 by: root - Fri, 10 Mar 2023 08:01 UTC

Henrik Carlqvist <Henrik.Carlqvist@deadspam.com> wrote:
> On Wed, 08 Mar 2023 15:29:43 +0000, root wrote:
>
>
> I guess that you did mount /sda2 before copying its kernel to /boot?
> However, I don't see any need to copy the kernel. Simply do:

You are correct, I mounted sda2 earlier. I posted the procedure
from memory.

I copied the kernel from sda2 because lilo expected that kernel
to be in the boot directory and I wasn't sure that it wanted
it in the boot directory of sda2 or of the liveslak drive.

>
> mkdir /sda2
> mount /dev/sda2 /sda2
> /dev/sda2/sbin/lilo -r /sda2
>
>
> It does not matter if you choose some rescue media like syslinux, knoppix
> or the Slackware installation media with a completely different kernel.
> Lilo does not care if the running kernel differs from the kernel lilo is
> supposed to boot. You can even write lilo configuration files which allow
> you to choose between many different kernels.

I have seen many times that Lilo fails if it can't find the kernel
mentioned in lilo.conf, or if a partition is called for that it
can't find.

>
>> What would you have done apart from switching to grub?
>
> Your choice of bootloader does not matter. The important thing that
> matters is the text in the changelog when a new kernel package is
> released by Slackware:
>
> -8<--------------------------------------------
> Be sure to upgrade your initrd after upgrading the kernel packages.
> If you use lilo to boot your machine, be sure lilo.conf points to the
> correct kernel and initrd and run lilo as root to update the bootloader.
> If you use elilo to boot your machine, you should run eliloconfig to copy
> the kernel and initrd to the EFI System Partition.
> -8<--------------------------------------------

I do the mkinitrd when I change the kernel being used by lilo. In this
case lilo on sda2 was using a custom kernel I built and it had
not been changed.

>
> You will need to update your bootloader, you can do it the easy way or
> you can do it the hard way with some friend using a rescue media.
>
> regards Henrik

As usual, thanks much for responding Henrik.

Re: Liveslak vs USBinstall and lost boot sector

<tueoec$1slfi$2@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1669&group=alt.os.linux.slackware#1669

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: NoEM...@home.org (root)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Fri, 10 Mar 2023 08:06:36 -0000 (UTC)
Organization: Linux Advocacy
Lines: 21
Message-ID: <tueoec$1slfi$2@dont-email.me>
References: <tua9l7$v4nn$1@dont-email.me> <6409968c@news.ausics.net>
Injection-Date: Fri, 10 Mar 2023 08:06:36 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="e94bfaa5ade73f62c357b7a91cc7e7b9";
logging-data="1988082"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18bJZ1ZeE3+n8igo9J7DyS5ALVNzg+Rpb8="
User-Agent: slrn/1.0.2 (Linux)
Cancel-Lock: sha1://mI1M4Esd3oO2/Hafv0WRj/TKk=
 by: root - Fri, 10 Mar 2023 08:06 UTC

noel <deletethis@invalid.lan> wrote:
> On Wed, 08 Mar 2023 15:29:43 +0000, root wrote:
>
>> Over the years I could not count the number of times that one of my
>> machines which uses lilo has lost its boot sector. I use grub now in my
>
>
> Strange, never had a lilo boot failure (that wasnt caused by operator
> error in nearly 30 years)

I'll confess. I'm certain almost always my incorrect use of lilo,
as it was in this case.

I have, however, had the boot sector wiped when an ssd was the
boot drive and some program I was developing crashed. Lilo
was not the cause of the boot sector damage in those cases.

>
> Dunno what you're doing to poor lilo.

I pretty much use grub on most of the machines I use now.

Re: Liveslak vs USBinstall and lost boot sector

<tug6ad$248ll$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1670&group=alt.os.linux.slackware#1670

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: NoEM...@home.org (root)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Fri, 10 Mar 2023 21:09:33 -0000 (UTC)
Organization: Linux Advocacy
Lines: 20
Message-ID: <tug6ad$248ll$1@dont-email.me>
References: <tua9l7$v4nn$1@dont-email.me> <6409968c@news.ausics.net>
<tueoec$1slfi$2@dont-email.me>
Injection-Date: Fri, 10 Mar 2023 21:09:33 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="e94bfaa5ade73f62c357b7a91cc7e7b9";
logging-data="2237109"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+7dMNcY4gLXtvLe7zkFHWGMQRGGYh5xvE="
User-Agent: slrn/1.0.2 (Linux)
Cancel-Lock: sha1:enLBnOxZaxuE9crcPTdO2FhzBLI=
 by: root - Fri, 10 Mar 2023 21:09 UTC

root <NoEMail@home.org> wrote:
> noel <deletethis@invalid.lan> wrote:
>> On Wed, 08 Mar 2023 15:29:43 +0000, root wrote:
>>
>>> Over the years I could not count the number of times that one of my
>>> machines which uses lilo has lost its boot sector. I use grub now in my
>>
>>
>> Strange, never had a lilo boot failure (that wasnt caused by operator
>> error in nearly 30 years)
>
> I'll confess. I'm certain almost always my incorrect use of lilo,
> as it was in this case.
>

It's easy enough for me to backup the boot sector without relying
on my memory:

I put the dd command in rc.local so the boot sector is backed up
after a successful boot. Thanks for the suggestion.

Re: Liveslak vs USBinstall and lost boot sector

<tuhl3j$2el40$2@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1674&group=alt.os.linux.slackware#1674

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: Henrik.C...@deadspam.com (Henrik Carlqvist)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Sat, 11 Mar 2023 10:28:03 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 43
Message-ID: <tuhl3j$2el40$2@dont-email.me>
References: <tua9l7$v4nn$1@dont-email.me> <tuatcn$12vp9$3@dont-email.me>
<tueo5e$1slfi$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 11 Mar 2023 10:28:03 -0000 (UTC)
Injection-Info: reader01.eternal-september.org; posting-host="f310a3c5e5e5d1b31f6016322c124c05";
logging-data="2577536"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18AtX5kpiFv/VYDCHzv9Sb9"
User-Agent: Pan/0.139 (Sexual Chocolate; GIT bf56508
git://git.gnome.org/pan2)
Cancel-Lock: sha1:tjvAW1qPZbMmsWtGeEwVy+VrRF8=
 by: Henrik Carlqvist - Sat, 11 Mar 2023 10:28 UTC

On Fri, 10 Mar 2023 08:01:50 +0000, root wrote:

> Henrik Carlqvist <Henrik.Carlqvist@deadspam.com> wrote:
>> /sbin/lilo -r /sda2

> I have seen many times that Lilo fails if it can't find the kernel
> mentioned in lilo.conf, or if a partition is called for that it can't
> find.

Yes, that can happen if your /boot directory lives on another partition
than the / directory. I so, you will need to mount also the /boot
partition correctly below the directory you point out with the -r option.

In short lilo needs the file /etc/lilo.conf and any file that
configuration file points to. Usually all files pointed to by lilo.conf
resides below /boot.

So if you from your live media mount your root partition at /sda2 and you
have /boot on a separate partition you will also need to mount that
partition below /sda2/boot. When called with "lilo -r /sda2" lilo
initially expects to find:

/sda2/etc/lilo.conf

Once that file has been parsed lilo will probably expect to find kernels
and stuff below

/sda2/boot

> I do the mkinitrd when I change the kernel being used by lilo. In this
> case lilo on sda2 was using a custom kernel I built and it had not been
> changed.

Lilo is not supposed to break unless the MBR has been tampered with in
some way or the files pointed to by lilo has been removed or moved to
other blocks on the disk. Lilo in the MBR does not parse file systems, it
remembers the position on disk that the kernel resides on. Doing things
like "mv /boot/vmlinuz /tmp; mv /tmp/vmlinuz /boot" might from a users
point of view on the /boot file system look as if nothing has changed but
will most likely break lilo as the kernel might have moved to another
block on the disk.

regards Henrik

Re: Liveslak vs USBinstall and lost boot sector

<tuk4cr$30fnh$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1680&group=alt.os.linux.slackware#1680

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: Mai...@JoesLife.org (Joseph Rosevear)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Sun, 12 Mar 2023 09:01:15 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 35
Message-ID: <tuk4cr$30fnh$1@dont-email.me>
References: <tua9l7$v4nn$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sun, 12 Mar 2023 09:01:15 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="1d048e9977791d9b655b93785b027695";
logging-data="3161841"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/oF+Qytp8nF2lA6ZfY8HyCQXjy8XdmgeQ="
User-Agent: Pan/0.149 (Bellevue; 4c157ba git@gitlab.gnome.org:GNOME/pan.git)
Cancel-Lock: sha1:8/X1Hq7dRbkIcDIQOgMdMmVwjss=
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAQAAAD9CzEMAAAAB3RJTUUH5wISBRox
oH115AAA ABV0RVh0U29mdHdhcmUAWFBhaW50ID
MuMS40FRQqnAAAB39JREFUWI
_Vl2NuOG1d2BuBv7zrw oFZ3W5IlWbYnA2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Qi
wFRqkt
yJOtOaFUs7TYtXY9o5W6mksZ6k4dFSstBg4/uyUt1TRSr1mMB7XebFoJJVRe5Py
+So K406qYuYythbq63Udr7xWngwhh62W5Ls9RJ
qB/N+l0XJUnYwWhRQZFmcqHk
_nWml0NjY2J42c PNweJ/N3RqPKNKUn4dwYtRpZp
ym7Z+GuaQ5vjWpJ59qbkzbO/
_y+GfZG1g8r7UtSxzOSlwUEq 8A4FJvXUqx+dG3X
eeu299mTeA1bNOJp3nnd6q1K
_VSm8h6B00Gke5JJl6qvbexqhxcGMsK+H8 mkfSP
N+yYGuvKSv81BuTrh5clCfm+
_KPy8cqNUS9oT39yeJCmqZ+Do2RwKNyf78Fob+fRCVHz
7+M87HeyXrLSGh1ODzg
_9PEnebP5XJj7wszHYaaxLrLPCIt77N3m1EtQ2Jfv3muPPafved3L5
5yJ5fKrYv Yz4P1Ypm+8jxpaGAAAAAElFTkSuQmCC
 by: Joseph Rosevear - Sun, 12 Mar 2023 09:01 UTC

On Wed, 8 Mar 2023 15:29:43 -0000 (UTC), root wrote:

> Over the years I could not count the number of times that one of my
> machines which uses lilo has lost its boot sector. I use grub now in my
> main machine, but I have a number of machines for which I am responsible
> which still run lilo. Yesterday a friend's machine lost its boot sector
> and I want to tell how I solved the problem and ask if there was a
> better way.

> [snip]

I haven't used lilo in years. I'm wondering if yours is a lilo issue.
Yes, Grub took a little getting used to, and it has an overhead of
complexity which sours it a little. Yet it works well, and is a powerful
tool.

I can't say that I have ever "lost a boot sector". I have occasionally
been unable to boot--maybe once or twice it happened by accidentally
damaging the boot sector. Usually, however, any trouble that I had came
from the normal processes of installing and upgrading. To deal with this
I studied. I ran tests, searched the Internet for tips, and kept notes,
some of which go back sixteen years. I manage alright now, but I'm still
not confident when it comes to fixing booting problems.

Generally, my problem solving involves the use of chroot, mkinitrd and
mkinitrd_command_generator.sh. And, of course, it involves reading my
notes.

There is one more bit of wisdom I would like to pass along. Perhaps you
have Slackware on a bootable flashdrive? I couldn't manage without such
flashdrives (I have several). They are life savers when I have booting
trouble, and (true confession) my daily system *is* a bootable Slackware
flashdrive.

-Joe

Re: Liveslak vs USBinstall and lost boot sector

<slrnu0vfjp.pq4.JimDiamond@x360.localdomain>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=1696&group=alt.os.linux.slackware#1696

  copy link   Newsgroups: alt.os.linux.slackware
Path: i2pn2.org!i2pn.org!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail
From: JimDiam...@ns.sympatico.ca (Jim Diamond)
Newsgroups: alt.os.linux.slackware
Subject: Re: Liveslak vs USBinstall and lost boot sector
Date: Mon, 13 Mar 2023 21:23:21 -0300
Organization: A noiseless patient Spider
Lines: 18
Message-ID: <slrnu0vfjp.pq4.JimDiamond@x360.localdomain>
References: <tua9l7$v4nn$1@dont-email.me> <6409968c@news.ausics.net>
<tueoec$1slfi$2@dont-email.me>
Injection-Info: dont-email.me; posting-host="1d2e2a34b9bcd378d52435b832e9b0b5";
logging-data="1313"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/jtahQkh+zBOcoTb1cGr7V"
User-Agent: slrn/1.0.3 (Linux)
Cancel-Lock: sha1:waq/R7l2GLaabFiOYjiJJ+dBlwI=
 by: Jim Diamond - Tue, 14 Mar 2023 00:23 UTC

On 2023-03-10 at 04:06 AST, root <NoEMail@home.org> wrote:
> noel <deletethis@invalid.lan> wrote:
>> On Wed, 08 Mar 2023 15:29:43 +0000, root wrote:
>>
>>> Over the years I could not count the number of times that one of my
>>> machines which uses lilo has lost its boot sector. I use grub now in my
>>
>>
>> Strange, never had a lilo boot failure (that wasnt caused by operator
>> error in nearly 30 years)
>
> I'll confess. I'm certain almost always my incorrect use of lilo,
> as it was in this case.
>
> I have, however, had the boot sector wiped when an ssd was the
> boot drive and some program I was developing crashed.

Logged in as root at the time, by any chance?

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor