0

I have a Fedora workstation, when upgrade the system some software for example LibreOffice do not delete its old symbol link in /usr/bin and when I update other software, there are a lot of warnings due to that. And in other situations, there are also this kind of problems. Is there a efficient console application to scan and automatically delete all these links whose target doesn't exist?

Open source is better. Thank you!!!

0

1 Answer 1

1

FSlint will do this for you, at least in its GUI. It also has command-line variants:

/usr/share/fslint/fslint/findbl /usr/bin

but that doesn’t appear to have an option to delete the broken links.

However, you don’t even need a specific tool for this, your system already has a tool which is capable of deleting broken symlinks: find. See How can I find broken symlinks for details; you can take a find command given there and add -delete to it to delete the links (after checking the output...):

find /usr/bin -xtype l -delete

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .