OSMC on Raspberry Pi 3 - apt-get not working

Hi,

i am using the OSMC installation on my Raspberry Pi 3 since nearly 1 year without any problem. Yesterday i have tried to upgrade my system to the latest release (mine was the still the update from December) but unfortunately i am not able to run any “apt-get” commands and get following error messages:

/usr/bin/apt-get-real: error while loading shared libraries: 12: cannot open shared object file: No such file or directory
/usr/bin/apt-get-real: error while loading shared libraries: /usr/bin/apt-get-real:

I have not found any similar problem report on the internet.

Do you have any clue how to get this solved? I do not want to re-install it since i made a lot of modification/installation (eg. nzbget, sonar, …).

Many thanks.
Markus

Well definitely not a good sign and most likely caused by a filesystem corruption and/or SD Card failure.
I suggest to start by doing a backup of what you still have and then see if you can fix the current situation.
After you have done the backup you can check how you libs are looking e.g. ls -lah /usr/lib/apt

Great, many thanks for the fast reply. I experienced some problems/hangs in the last week(s) so also this was my worry already.

Will do a full backup this afternoon and will check the libs you suggested and try to fix it. I will update once i have more.

Many thx.

I have now made a backup and checked the SD Card. Luckily i have not found any failures in the directory nor with the badblocks check.


osmc@raspi:/var$ sudo badblocks -v /dev/mmcblk0p9
Checking blocks 0 to 14217215
Checking for bad blocks (read-only test):
done
Pass completed, 0 bad blocks found. (0/0/0 errors)
osmc@raspi:/var$
osmc@raspi:/var$ sudo badblocks -v /dev/mmcblk0p7
Checking blocks 0 to 15847422
Checking for bad blocks (read-only test):
done
Pass completed, 0 bad blocks found. (0/0/0 errors)

Any idea how i can get apt-get working again? Where can i get the package to install it manually?

When i look into dmesg output i also can see some failures:

[ 29.543480] rfkill: version magic '4.4.27-5-osmc SMP pseemp4 moD_unload modversions ARMv7 ’ should be '4.4.27-5-osmc SMP preempt mod_unload modversions ARMv7 ’
[ 29.543489] rfkill: version magic '4.4.27-5-osmc SMP pseemp4 moD_unload modversions ARMv7 ’ should be '4.4.27-5-osmc SMP preempt mod_unload modversions ARMv7 ’

Many thanks.
Markus

My suggestion is to do a clean install and just recover .kodi etc directory from your backup

That doesn’t mean much as it is just a read test without writing to the SD card