Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.kernel > #85707

Bug#825423: supermin + sbuild + linux-image = broken chroot

Path csiph.com!news.samoylyk.net!gothmog.csi.it!bofh.it!news.nic.it!robomod
From Santiago Vila <sanvila@debian.org>
Newsgroups linux.debian.bugs.dist, linux.debian.kernel
Subject Bug#825423: supermin + sbuild + linux-image = broken chroot
Date Thu, 20 Feb 2025 12:10:01 +0100
Message-ID <KicBj-AWD-1@gated-at.bofh.it> (permalink)
References <rD9BM-26y-7@gated-at.bofh.it> <rDbtU-3dI-5@gated-at.bofh.it> <rGg42-72t-3@gated-at.bofh.it> <rGlQ5-2RU-7@gated-at.bofh.it> <rGmj9-3hA-57@gated-at.bofh.it> <rGnoR-3Tt-9@gated-at.bofh.it> <KibYB-AtA-5@gated-at.bofh.it> <rD9BM-26y-7@gated-at.bofh.it> <KibYB-AtA-5@gated-at.bofh.it>
X-Original-To Salvatore Bonaccorso <carnil@debian.org>, Ben Hutchings <ben@decadent.org.uk>, 825423@bugs.debian.org
X-Mailbox-Line From debian-bugs-dist-request@lists.debian.org Thu Feb 20 11:03:09 2025
Old-Return-Path <debbugs@buxtehude.debian.org>
X-Spam-Flag NO
X-Spam-Score -3.999
Reply-To Santiago Vila <sanvila@debian.org>, 825423@bugs.debian.org
Resent-To debian-bugs-dist@lists.debian.org
Resent-Cc Debian Kernel Team <debian-kernel@lists.debian.org>
X-Debian-Pr-Message followup 825423
X-Debian-Pr-Package src:linux
X-Debian-Pr-Source linux
MIME-Version 1.0
User-Agent Mozilla Thunderbird
Content-Language en-US
Content-Type text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding 8bit
X-Debian-User sanvila
X-Crossassassin-Score 2
X-Debian-Message from BTS
X-Mailing-List <debian-bugs-dist@lists.debian.org> archive/latest/1888275
List-ID <debian-bugs-dist.lists.debian.org>
List-URL <https://lists.debian.org/debian-bugs-dist/>
Approved robomod@news.nic.it
Lines 66
Organization linux.* mail to news gateway
Sender robomod@news.nic.it
X-Original-Cc Santiago Vila <sanvila@unex.es>, Aurelien Jarno <aurelien@aurel32.net>, control@bugs.debian.org
X-Original-Date Thu, 20 Feb 2025 12:01:22 +0100
X-Original-Message-ID <f391ad0f-0086-4149-a1b0-bf935e4980a5@debian.org>
X-Original-References <20160526194849.GA29914@nuc> <1464299422.2762.34.camel@decadent.org.uk> <20160604091730.GA31220@aurel32.net> <1465054438.2847.140.camel@decadent.org.uk> <20160604155926.GA13266@cantor.unex.es> <1465060360.2847.150.camel@decadent.org.uk> <Z7cBvSVKPyvGOXVb@eldamar.lan> <20160526194849.GA29914@nuc> <Z7cBvSVKPyvGOXVb@eldamar.lan>
Xref csiph.com linux.debian.bugs.dist:1234197 linux.debian.kernel:85707

Cross-posted to 2 groups.

Show key headers only | View raw


reassign 825423 linux-base
found 825423 4.2
close 825423 4.3
thanks

El 20/2/25 a las 11:19, Salvatore Bonaccorso escribió:
> Hi,
> 
> On Sat, Jun 04, 2016 at 06:12:40PM +0100, Ben Hutchings wrote:
>> On Sat, 2016-06-04 at 17:59 +0200, Santiago Vila wrote:
>>> On Sat, Jun 04, 2016 at 04:33:58PM +0100, Ben Hutchings wrote:
>>>>> You can use the command ischroot from the debianutils package.
>>>>
>>>> Why would I want to add a dependency on that? [...]
>>>
>>> You really wouldn't, because debianutils is essential.
>>
>> Oh duh, thanks for pointing that out.
> 
> is this bug still present or can we close this old bug?

Seems fixed. I just tried this:

sbuild -d bookworm supermin

on a stable system still running 6.1.0-29
(upgraded to -31, but not rebooted yet).

The build process installed linux-image-6.1.0-29-amd64,
the package was built, and sbuild was able to remove
the kernel even if it had the same version as the
running kernel:

[...]
Removing linux-image-amd64 (6.1.123-1) ...
Removing linux-image-6.1.0-29-amd64 (6.1.123-1) ...
W: Last kernel image has been removed, so removing the default symlinks
/etc/kernel/postrm.d/initramfs-tools:
update-initramfs: Deleting /boot/initrd.img-6.1.0-29-amd64
Removing initramfs-tools (0.142+deb12u1) ...
Removing initramfs-tools-core (0.142+deb12u1) ...


Apparently linux-check-removal is smarter now:

---------
If the currently running kernel matches VERSION, linux-check-removal
will normally prompt the user to confirm this potentially dangerous
action and will fail if the user chooses to abort.  However, if the
current environment is in a chroot or container, or if debconf
prompts are disabled, it will always succeed without prompting.
---------

I traced that to commit [4a695de] in linux-base, dated 2016-06-06
(which is just two days later than the last message from Ben
in this thread).

     Add linux-check-removal command for use by package prerm scripts
     
     Use the existing logic (roughly) and exactly the same debconf template
     and translations that are currently included in src:linux.

Therefore, I think this was fixed in linux-base 4.3.
Closing myself.

Thanks a lot!

Back to linux.debian.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Bug#825423: supermin + sbuild + linux-image = broken chroot Salvatore Bonaccorso <carnil@debian.org> - 2025-02-20 11:30 +0100
  Bug#825423: supermin + sbuild + linux-image = broken chroot Santiago Vila <sanvila@debian.org> - 2025-02-20 12:10 +0100
    Processed: Re: Bug#825423: supermin + sbuild + linux-image =  broken chroot "Debian Bug Tracking System" <owner@bugs.debian.org> - 2025-02-20 12:10 +0100
    Bug#825423: supermin + sbuild + linux-image = broken chroot Ben Hutchings <ben@decadent.org.uk> - 2025-02-20 23:30 +0100

csiph-web