Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

When we install a package in Ubuntu using apt-get install, where can we find the .deb files ?

I installed Python using this method but I did not find its .deb file in /var/cache/apt/archive/.

share|improve this question
1  
Are you sure you installed it? Python should be included by default and only packages you installed manually will be in /var/cache/apt/archive/. –  terdon Apr 2 at 16:21
    
Yes, it is included by default, but I installed an other version of it –  begueradj Apr 3 at 7:23

1 Answer 1

up vote 4 down vote accepted

By default, apt stores the .deb files in /var/cache/apt/archives. If you can't find them here, you or someone else or something else(a software like Ubuntu tweak) may have run a clean-up command like sudo apt-get clean to clear up the .deb files. However, you can manually search all .deb files in your system by doing the following(may require superuser privileges):

sudo updatedb

This will update locate's database to search for newly created/removed files, this may take a while depending upon the difference in time when the last time updatedb was run(it is usually run as a cron job daily) and then

locate *.deb

which will search your / folder recursively for all files ending with .deb.

share|improve this answer
    
Thank you Jobin. Yes, I performed the clean several times, indeed before I searched for the .deb file –  begueradj Apr 3 at 7:25

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.