dpkg-fsys-usrunmess is a tool to fix up filesystems that have been installed anew with recent installers with unfortunate defaults or migrated to the broken merged /usr via aliased directories layout, which is not supported by dpkg. See the dpkg FAQ.
The program will perform the following overall actions:
- Check whether the system needs to be switched, otherwise do nothing,
- Check for dpkg database consistency and otherwise abort.
- Get the list of files and alternatives that need to be restored.
- Create a shadow hierarchy under /.usrunmess, by creating the directories symlinks or hardlinking or copying the files as needed.
- Prompt for confirmation before proceeding, if requested on the command-line.
- Lock the dpkg database.
- Mark all packages as half-configured to force running maintainer scripts that might need to recreate files.
- Replace the aliased directories with the shadow ones, by creating a backup of the old symlinked directories and renaming the shadow ones over.
- Relabel MAC information for directories and symlinks if necessary.
- Reconfigure all packages.
- Remove backup symlinks.
- Remove old moved objects, but defer directory removal.
- Remove old deferred directories that are not referenced by dpkg-query.
- Remove shadow root directory.
Note: When running the program from some shells such as bash(1) or zsh(1), after executing it, you might need to request the shell to forget all remembered executable locations with for example
Warning: Note that this operation has the potential to render the system unusable or broken in case of a sudden crash or reboot, unexpected state of the system, or possible bugs in the script. Be prepared with recovery media and consider doing backups beforehand.
- -p, --prompt
Prompt at the time of no return, so that the debug output or the shadow hierarchy can be evaluated before proceeding.
- -n, --no-act
This option enables the dry-run mode, where no destructive action takes place, only the preparatory part.
- -?, --help
Show the usage message and exit.
Show the version and exit.
This setting defines whether to enable dry-run mode.