Bug#1073998: linux: Purging linux-image- doesn't clean up modules.weakdep file

2024-06-22 Thread Salvatore Bonaccorso
On Sat, Jun 22, 2024 at 12:13:26PM +0200, Diederik de Haas wrote:
> Version: 6.9.2-1~exp1
> 
> On Saturday, 22 June 2024 10:52:53 CEST Salvatore Bonaccorso wrote:
> > Are you sure about the found version 6.9.2-1~exp1? With the
> > https://salsa.debian.org/kernel-team/linux/-/commit/19656787a6b4dcb29ea999a9
> > 1cb9eb5e7994d77f merge this is actually fixed for 6.9.2-1~exp1.
> 
> Wow, do I feel stupid now :-O
> You're absolutely right, purging 6.9.2-1~exp1 does succeed.
> 
> I could reproduce it when removing *my* 6.9.2 kernel (on arm64) ... but that 
> build/kernel did not have that commit. (In my poor defense)

Diederik, thanks for your quick confirmation and updating the bug
metadata.

Regards,
Salvatore



Bug#1073998: linux: Purging linux-image- doesn't clean up modules.weakdep file

2024-06-22 Thread Salvatore Bonaccorso
Control: tags -1 + moreinfo

Hi Diederik,

On Fri, Jun 21, 2024 at 01:47:59PM +0200, Diederik de Haas wrote:
> Control: found -1 6.6.15-1
> 
> On Friday, 21 June 2024 13:41:38 CEST Christoph Berg wrote:
> > I just had the same problem on linux-image-6.6.15-amd64.
> 
> Updating found version accordingly.
> 
> > > It seems to me that at least with purging that file should be removed
> > > and subsequently the ``/lib/modules/`` dir.
> > 
> > TBH, I'd even argue plain "remove" should remove the debris from the
> > modules directory, it's not like there's anything of value in the
> > modules.* files left behind.
> 
> I didn't have that many kernels installed, so I only verified it with 1 and 
> for 
> that I used 'purge'. But I'm inclined to agree that remove should remove that 
> file too.

Are you sure about the found version 6.9.2-1~exp1? With the
https://salsa.debian.org/kernel-team/linux/-/commit/19656787a6b4dcb29ea999a91cb9eb5e7994d77f
merge this is actually fixed for 6.9.2-1~exp1.

Regards,
Salvatore



Bug#1073998: linux: Purging linux-image- doesn't clean up modules.weakdep file

2024-06-21 Thread Diederik de Haas
Control: found -1 6.6.15-1

On Friday, 21 June 2024 13:41:38 CEST Christoph Berg wrote:
> I just had the same problem on linux-image-6.6.15-amd64.

Updating found version accordingly.

> > It seems to me that at least with purging that file should be removed
> > and subsequently the ``/lib/modules/`` dir.
> 
> TBH, I'd even argue plain "remove" should remove the debris from the
> modules directory, it's not like there's anything of value in the
> modules.* files left behind.

I didn't have that many kernels installed, so I only verified it with 1 and for 
that I used 'purge'. But I'm inclined to agree that remove should remove that 
file too.

signature.asc
Description: This is a digitally signed message part.


Bug#1073998: linux: Purging linux-image- doesn't clean up modules.weakdep file

2024-06-21 Thread Christoph Berg
Re: Diederik de Haas
> When removing or 'even' purging a linux-image- package, it
> reports the following issue:
> 
> rmdir: failed to remove '/lib/modules/': Directory not empty
> 
> The reason for that is that there's still a ``modules.weakdep`` file.

I just had the same problem on linux-image-6.6.15-amd64.

> It seems to me that at least with purging that file should be removed
> and subsequently the ``/lib/modules/`` dir.

TBH, I'd even argue plain "remove" should remove the debris from the
modules directory, it's not like there's anything of value in the
modules.* files left behind.

Kernels are the only package that I'm actually purging, if "remove"
wouldn't leave /lib/modules/*/ behind, I wouldn't have to do that.

Christoph



Bug#1073998: linux: Purging linux-image- doesn't clean up modules.weakdep file

2024-06-21 Thread Diederik de Haas
Source: linux
Version: 6.9.2-1
Severity: minor

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

When removing or 'even' purging a linux-image- package, it
reports the following issue:

rmdir: failed to remove '/lib/modules/': Directory not empty

The reason for that is that there's still a ``modules.weakdep`` file.
It seems to me that at least with purging that file should be removed
and subsequently the ``/lib/modules/`` dir.

FWIW: I do not have any DKMS package which could also result in the
inability to remove the modules dir.

- -- System Information:
Debian Release: trixie/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing'), (101, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 6.9-amd64 (SMP w/16 CPU threads; PREEMPT)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

-BEGIN PGP SIGNATURE-

iHUEARYIAB0WIQT1sUPBYsyGmi4usy/XblvOeH7bbgUCZnVlCwAKCRDXblvOeH7b
bvdqAPwOCZQoQ5xXUbW+FkytY5Ovj5xoPizPFOWdFTvtaXro0QD/RhTTHvmL4cZ4
GfAOEDPN4Rv+vnze+lNZt+xCrTSa4AY=
=QCxl
-END PGP SIGNATURE-