Is it possible to store security update files for later reinstallation?
DebianThis forum is for the discussion of Debian Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Is it possible to store security update files for later reinstallation?
If people need to reinstall debian, they also need to upgrade all those security updates after the reinstallation. However, this kind of job is really daunting for dialup users. I recently intended to reinstall sarge r0a and found that I need to upgrade (download) about 220 MB during apt-get upgrade! For a dialup user like me, it's really impossible. So I consider buying a new sarge r2 dvd set which came out recently (April?), those security updates will be minimized.
In case of any disaster happened in the future and need to reinstall the whole debian linux, is there a way to store (or back up) those downloaded security updates during apt-get upgrade or after those upgrade processes before any disaster occurs?
If that's possible, where can I find those updates and how to apply them to the newly reinstalled system?
yup, i keep updates all in a seperate directory, and if my system ever borks i can re-install and in go in that update directory and just type in upgradepkg *tgz and all upgrades are done in one command...
your command to upgrade packages will depend on your distribution...
Thank you for your response Okie! I guess it is possible to do this, but.. Is there any debian users knows that in what directory can I find those downloaded updates in debian? and how to apply to the newly reinstalled system?
Debian's apt has a cache directory that stores those update packages after install, but one word about apt, if you use apt-get clean it will delete them all, so you need to save them somewhere outside your operating system's directory, maybe burn them to CDR or copy them over to a seperate disk partition before clearing them out of apt's cache directory
A way to reinstall all security updates without downloading them from the net
Thank you again Okie. I found the directory where all updates stored inside: /var/cache/apt/archives
If people ever need to reinstall the whole debian system using dial-up, the following steps will help to reinstall all security updates without downloading them from the net:
1. In a newly installed debian system, everytime when doing a security update, back up those downloaded updates in /var/cache/apt/archives to a secure place, such as a cd or another disk.
2. If any disaster occurs in the future, just reinstall the whole debian system.
3. Immediately after reinstallation, copy those backup security updates back into /var/cache/apt/archives
4. Run apt-get update && apt-get upgrade (or aptitude or synaptic) to reinstall those security updates without ever downloading them from the net again.
I did an experiment on my machine and it worked well!
If that's what you are looking to do you may be interested in how you can store and reload your package selections for Debian..
On the source machine do dpkg --get-selections >selections.txt
copy that selections.txt file to the destination machine it contains a list of the status of all packages installed on your machine.
On destination machine: (make sure sources.list is the same)
apt-get update
dpkg --set-selections <selections.txt
apt-get upgrade
Very usefull if you want to setup several machines hte same way.. or restore a machine that has crashed by reloading it ..
My original question was to back up downloaded security updates themselves for later reinstallation in case any disaster happens in the future, not just the list of the status of all packages installed on my machine. I think this is just good for distributing to multiple machines. It's helpful but not really relevant. But, thank you farslayer anyway!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.