Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I accidentally deleted all some binaries by rm -r f*, when my current directory was /usr/bin/ . So i couldn't install any files including findutils, since 'find' binary is the prerequisite for installations.

Can you help me , where to download or find the binary file for this?

My OS is Mint Olivia 15

share|improve this question
    
What OS/version/platform are you using? –  D_Bye Jun 12 '13 at 9:25
    
I am using linux mint olivia 15 –  corneliusfelix Jun 12 '13 at 9:32
    
Do you still have the installation media to hand? Does it have a rescue image? If not, you might be able to find what you need in the Ubuntu or Debian repos. I don't use Linux, so I don't know any more than that, sorry. –  D_Bye Jun 12 '13 at 10:04
    
solved it. thanks –  corneliusfelix Jun 12 '13 at 10:15
1  
If you solved it, please post an answer explaining what you did. –  terdon Jun 12 '13 at 17:40

2 Answers 2

up vote 3 down vote accepted

There are offline and online databases of packages that allow you to search for the package containing a file with a particular name. I don't think Mint implements this, but you can look it up for Ubuntu: online on the package search page, offline with apt-file.

You don't need find to perform most installations. If you find that the lack of find is blocking you, download the package and (re)install it manually with dpkg -i.

You'll need to reinstall all the packages with missing files. You can find the list of missing files and the corresponding packages by looking through the package lists in /var/lib/dpkg/info.

apt-get --reinstall install $(grep -l '^/usr/bin/f' /var/lib/dpkg/info/*.list | sed -e 's~.*/~~' -e 's~\.list$~~')
share|improve this answer

Of course, you should use your fine backups that you have taken and use that to restore the missing files. You have these right? If you don't, this is something that you need take care of immediately.

Failing the use of backups, the best way to be sure things return correctly is a full reinstall.

Using other methods are generally hit-or-miss, are messy and involve probably a lot more time and you might have problems in the future updating your system as your packaging repositories will then be out of sync.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.