Tried to install a package after deleting some servers I no longer needed, and removing the deleted software package's users and groups. Went to fetch and install a new package, and got the following error.
user@localhost~$ sudo apt-get install any-package
... package installation output omitted for brevity ...
dpkg: unrecoverable fatal error, aborting:
syntax error: unknown user 'puppet' in statoverride file
E: Sub-process /usr/bin/dpkg returned an error code (2)
So /usr/bin/dpkg-statoverride has an option to remove a path, but the binary throws the same error when I try to run it out side of the whole apt-get install context.
So then I just added the user puppet, and i can download packages again, but I'm trying to remove any extraneous elements from my dev system, so as far as I'm concerned, this isn't a solution just because it works.
As far as I can tell, the statoverride tells the package manager to install certain stuff to a certain path, and messes with the setuid flag, so potentially, it could be opening up a bunch of security holes by installing programs co-owned by an unused user and group. Is there a reason dpkg-statoverride isn't updated with the rest of the system when a user is removed? And is there a way to circumvent this so that I don't have to :adduser -> install -> deluser: everytime I want to install a package?
You can try this:
Should remove the user from statoverride and give you access to install again