LMDE 7 - Automatic kernel cleanup fails because installed kernel packages are marked as manually installed
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 49/100
Hướng nghiên cứu
Start by tracing the mintupdate-automation-autoremove service and the code that installs or marks kernel image and header packages during updates; the issue gives the apt-get autoremove --purge -y command and package marking checks as entry points. Reproduce on LMDE 7 by checking apt-mark showmanual and apt-mark showauto before and after a kernel update. Done means obsolete kernels become eligible for cleanup while the running kernel and a fallback remain installed.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Bug description
Obsolete kernel versions are not removed by LMDE 7's automatic kernel cleanup, despite automatic removal being enabled in Update Manager.
After investigating the weekly cleanup service, I found that it executes:
/usr/bin/apt-get autoremove --purge -y
However, all version-specific kernel image and header packages are marked as manually installed. As a result, APT does not consider them eligible for automatic removal.
Steps to reproduce
- Install LMDE 7
- Enable Automatic Maintenance.
- Update LMDE 7 through Update Manager over a course of weeks/months.
- Allow multiple kernel updates to accumulate.
- Check installed kernel package markings using:
apt-mark showmanual - Observe that version-specific kernel image and header packages are marked as manually installed.
- Check automatically installed packages using:
apt-mark showauto - Observe that no version-specific kernel image or header packages are listed.
- Allow the scheduled
mintupdate-automation-autoremoveservice to run.
Additional investigation
I previously encountered the same issue and manually marked older kernel packages as automatically installed using apt-mark auto.
This temporarily restored the expected cleanup behaviour:
- August 8: I marked the older
6.12.100and6.12.96kernel packages as automatic. The next autoremove successfully removed kernel6.12.96. - August 26: After installing kernel
6.12.105, I found that newly installed kernel packages were marked as manual again. The next autoremove removed kernel6.12.100as expected. - November 2: Automatic cleanup has ran several times since August, but no kernels were removed while new ones were still being installed.
This suggests that subsequent kernel updates are causing previously corrected package markings to revert to manual.
Current system state
- LMDE 7
- Debian kernel series 6.12
- Six installed kernel versions, from
6.12.101through6.12.115 - All version-specific kernel image and header packages are marked as manually installed.
apt-mark showautoreturns no version-specific kernel image or header packages.
The November 2. automatic cleanup log contains:
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Expected behaviour
Automatic kernel cleanup should remove obsolete kernel versions while retaining the currently running kernel and an appropriate fallback version.
Kernel updates should not cause obsolete kernel packages to become permanently ineligible for automatic removal.
Actual behaviour
Version-specific kernel packages are marked as manually installed, preventing APT's autoremove from removing them. The weekly Mint cleanup therefore runs successfully but removes no obsolete kernels.
The issue reappears after subsequent kernel updates, even after manually correcting the package markings.
Impact
Obsolete kernels accumulate over time and consume /boot space. On installations with a relatively small /boot partition, this eventually prevents further kernel updates due to insufficient free space. Like I have experienced several times now.
- Ngôn ngữ chính
- Python
- Star
- 428
- Fork
- 196
- Merge trung bình
- 16 giờ 9 phút
- Pull request đã merge (30 ngày)
- 1
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của linuxmint/mintupdate
-
Report failed upgrades with a non-zero exit status (mintupdate-cli, mint-refresh-cache, automatic upgrades)Có thể đã có người làm @Amadeus-22 đã nhận 14 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
linuxmint/mintupdate#1107 · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
BUG
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
linuxmint/mintupdate#1089 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
flatpak-update-worker busy-loops at ~46% CPU when parent mintUpdate process exitsCó thể đã có người làm @dualfroz đã nhận 9 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
linuxmint/mintupdate#1041 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
FEATURE REQUEST
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 65/100
linuxmint/mintupdate#910 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 65/100
linuxmint/mintupdate#903 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của linuxmint/mintupdate
Issue tương tự
-
00 - Bug component: numpy.linalg
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 72/100
521xueweihan/HelloGitHub#4543 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 83/100
emeryberger/CSrankings#15700 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Bug | 工作不正常 Triage | 待检查
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 77/100
OneDragon-Anything/ZenlessZoneZero-OneDragon#3084 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Task select patterns with uppercase letters never matchCó thể đã có người làm @manobhisriram đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 1 ngày