3

I get the following errors when running the apt-get upgrade:

apt-get upgrade error

  • dpkg: error processing package nfs-common (--remove)
  • cannot remove /sbin/umount.nfs4: Bad message
  • E: Sub-process /usr/bin/dpkg returned an error code (1)

When I run ls command in /sbin, I get the following errors:

ls in /sbin

  • ls: cannot access 'umount.nfs': Bad message
  • ls: cannot access 'mount.nfs4': Bad message
  • ls: cannot access 'umount.nfs4': Bad message
  • ls: cannot access 'start-statd': Bad message

When I run ls -l command in /sbin, it returns output like this:

l????????? ? ?    ?            ?            ? mount.nfs4

which is the same for the other mentioned files (umount.nfs, umount.nfs4 and start-statd).

What can I do to repair this? Ubuntu version: 20.04

Raffa
  • 32,237
Stefan
  • 41
  • 3
  • Run ls -l inside /sbin and add the lines specific to those files (chances you'll see some ????) and a few other files from the output ... There is a chance that (most probable cause first) your filesystem is corrupt and need checking and fixing or your disk is dying with too many bad blocks or your data link between the disk and the motherboard is damaged. – Raffa Mar 17 '24 at 18:14
  • Thank you @Raffa for your answer. Indeed I got some ??? after running ls -l and looks like the following: l????????? ? ? ? ? ? mount.nfs4, which is the same for the mentioned ones (umount.nfs, umount.nfs4 and start-statd). What should I do to fix it? – Stefan Mar 18 '24 at 11:55

1 Answers1

3

That might mean (most probable cause first):

  • Your filesystem is corrupt and needs checking and fixing.
  • Your disk is dying with too many bad blocks and needs urgent assessment that might call for immediate data backup and total disk replacement.
  • Your data link between the disk and the motherboard is damaged/loose at either ends or in the data cable itself and manual checking and fixing or replacing might be required.

That said, filesystem corruption and especially in inodes metadata is the most common cause for the symptoms you experience and the output you see in the ls -l command ... So, I would suggest you thoroughly focus on this first and foremost before considering the other two possibilities listed above.

However, make sure to backup your important personal data first before you attempt any fix.

Useful filesystem check related posts:

Raffa
  • 32,237