Corrupt Debian installation in official images

#1

Hi there,

I have just noticed that the Debian installation in the official images is broken.

This is the output of debsums (only an extract, there are too many missing files):

root@osmc:~# debsums |& grep -v "OK$"
# ... output stripped ...
/usr/share/kodi/addons/skin.osmc/16x9/Font.xml                            FAILED
/usr/share/kodi/addons/skin.estuary/xml/Font.xml                          FAILED
/lib/modules/3.14.29-150-osmc/modules.alias.bin                           FAILED
/lib/modules/3.14.29-150-osmc/modules.dep.bin                             FAILED
/lib/modules/3.14.29-150-osmc/modules.symbols                             FAILED
/lib/modules/3.14.29-150-osmc/modules.symbols.bin                         FAILED
/lib/modules/3.14.29-150-osmc/modules.alias                               FAILED
/lib/modules/3.14.29-150-osmc/modules.dep                                 FAILED
debsums: missing file /usr/share/man/man1/wget.1.gz (from wget package)
debsums: missing file /usr/share/man/man5/wpa_supplicant.conf.5.gz (from wpasupplicant package)
debsums: missing file /usr/share/man/man8/wpa_action.8.gz (from wpasupplicant package)
debsums: missing file /usr/share/man/man8/wpa_background.8.gz (from wpasupplicant package)
debsums: missing file /usr/share/man/man8/wpa_cli.8.gz (from wpasupplicant package)
debsums: missing file /usr/share/man/man8/wpa_passphrase.8.gz (from wpasupplicant package)
debsums: missing file /usr/share/man/man8/wpa_supplicant.8.gz (from wpasupplicant package)
debsums: missing file /usr/share/man/man7/xkeyboard-config.7.gz (from xkb-data package)
debsums: missing file /usr/share/man/man1/lzmainfo.1.gz (from xz-utils package)
debsums: missing file /usr/share/man/man1/xz.1.gz (from xz-utils package)
debsums: missing file /usr/share/man/man1/xzdiff.1.gz (from xz-utils package)
debsums: missing file /usr/share/man/man1/xzgrep.1.gz (from xz-utils package)
debsums: missing file /usr/share/man/man1/xzless.1.gz (from xz-utils package)
debsums: missing file /usr/share/man/man1/xzmore.1.gz (from xz-utils package)

This is what you usually only see on horribly broken systems where either the filesystem or the flash is damaged. So I decided to reflashed the latest image (OSMC_TGT_vero3_20190623.img) to my Vero 4K+ in order to fix that.

Sadly, directly after installation/flashing the checksums of the same files were corrupt as before flashing. The missing files were also still missing. So it’s not just me or my particular unit - there is something wrong with the official images. Unfortunately this took me some quite time to figure out…

Anyway, it would be good if you could fix these issues with the next release/image, so people can check the consistency of their installation again. I find that rather important for a device with flash storage, which might get powered off quite often without a clean shutdown.

#2

man pages are intentionally stripped.

I don’t think the images are corrupted or we’d have had some reports of problems.

Are you saying that the image results in a non bootable system?

#3

Hi,

no, the system is bootable. The issue is just that the state of the dpkg database does not match the state of the filesystem.

It’s usually good Debian practice to check the consistency of the installation with debsums, which currently fails on OSMC. If you have any sort of problem, debsums is usually the first thing you look at.

#4

The modules and font files would be changed on first boot. We don’t want them as conffiles though, so this is expected from depmod and changing the Font XML on skin changes.

I can probably tidy those two up; but the man page warnings would persist.

#5

Hi Sam,

do the man pages really take up so much space that it’s worth breaking the package database in such a way? On my desktop Debian system they are roughly 60 MB. And it’s not just the man pages which are missing, there is more:

root@osmc:~# debsums |& grep -v "OK$"|grep -v "usr/share/man"
/usr/share/kodi/addons/script.module.osmcsetting.networkdebsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/README (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/addon.xml (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/changelog.txt (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/default.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/__init__.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/language/English/strings.po (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/lib/CompLogger.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/lib/OSMC_REparser.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/lib/__init__.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/lib/config_editor.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/osmc/FO_Icon.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/osmc/FO_Icon_Widget.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/osmc/FX_Icon.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/osmc/FX_Icon_Widget.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/osmc/OSMCSetting.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/osmc/__init__.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pi/resources/settings.xml (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/README (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/addon.xml (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/changelog.txt (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/default.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/__init__.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/language/English/strings.po (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/lib/CompLogger.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/lib/OSMC_OCparser.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/lib/__init__.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/lib/cpu_info.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/lib/gui.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/lib/pimodels.xml (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/osmc/FO_Icon.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/osmc/FO_Icon_Widget.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/osmc/FX_Icon.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/osmc/FX_Icon_Widget.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/osmc/OSMCSetting.py (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/settings.xml (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/1080i/new_gui.xml (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/1080i/new_gui_720.xml (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/ArrowDownFO.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/ArrowDownNF.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/ArrowUpFO.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/ArrowUpNF.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/Curve.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/RadioOff.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/RadioOn.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/TextShade.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/background.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/logo.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/single_pixel.png (from mediacenter-addon-osmc package)
debsums: missing file /usr/share/kodi/addons/script.module.osmcsetting.pioverclock/resources/skins/Default/media/white.png (from mediacenter-addon-osmc package)
K
/usr/share/kodi/addons/skin.estuary/xml/Font.xml                          FAILED
/lib/modules/3.14.29-150-osmc/modules.alias.bin                           FAILED
/lib/modules/3.14.29-150-osmc/modules.dep.bin                             FAILED
/lib/modules/3.14.29-150-osmc/modules.symbols                             FAILED
/lib/modules/3.14.29-150-osmc/modules.symbols.bin                         FAILED
/lib/modules/3.14.29-150-osmc/modules.alias                               FAILED
/lib/modules/3.14.29-150-osmc/modules.dep                                 FAILED
/lib/modules/3.14.29-152-osmc/modules.alias.bin                           FAILED
/lib/modules/3.14.29-152-osmc/modules.dep.bin                             FAILED
/lib/modules/3.14.29-152-osmc/modules.symbols                             FAILED
/lib/modules/3.14.29-152-osmc/modules.symbols.bin                         FAILED
/lib/modules/3.14.29-152-osmc/modules.alias                               FAILED
/lib/modules/3.14.29-152-osmc/modules.dep                                 FAILED

So right now it sounds like this is intended and nothing too critical. It’s just that people who are familiar with Debian and Linux in general might find this very confusing, as removing/replacing files behind the package manager’s back is usually considered a really bad thing.

The missing files in “script.module.osmcsetting.pi*” are probably just packaging issues as it looks like you have one package (mediacenter-addon-osmc) for all platforms. Splitting these addons across platform-specific packages (such as mediacenter-addon-osmc-pi) could easily solve this.

Maybe you can put this on your agenda for the Debian Buster upgrade. A consistent Debian base system would really be a good starting point :slight_smile:

With a consistent Debian base people could more easily check for rootfs corruptions with debsums.

#6

I’m happy for a PR to improve this but for now it’s quite low on the list.

The manual pages are not included because 60MB is a lot, particularly on a NOOBS system where we fight for space with other distributions.

The addon already removes the Pi addons, but does so in the postinst.