Mailinglist Archive: opensuse (621 mails)

< Previous Next >
Re: [opensuse] save installed packages for reinstall
* David C. Rankin <drankinatty@xxxxxxxxxxxxxxxxxx> [06-08-19 19:41]:
On 06/08/2019 05:48 PM, Patrick Shanahan wrote:
I am considering wiping my main system drive and reinstalling Tw clean but
would like to have the same packages on the new system. I will backup home
and replace the new home contents with the backedup data.

is this feasible?

how to save the currently installed pkgs for reinstall?

and yes, btrfs for entire system.

thoughts?

tks,


Save the list of current packages installed, e.g. open an xterm and:

$ rpm -qa --queryformat "%{name}\n" | sort > installed_pkgs.txt

You now have all the package names saved in installed_pkgs.txt. Then when you
load your new system, after your base install is done, you can simply open a
terminal and (optionally delete the cruft from installed_pkgs.txt), then

# zypper in --no-recommends $(awk -vORS=" " '{print}' installed_pkgs.txt)

The awk command substitution just converts the line separated names in
installed_pkgs.txt to space separated to feed to zypper.

Or, if you just want to make sure you have the set of rpms available so you
can rpm -U *.rpm, you can use zypper in --download-only to save the rpms
before you nuke your system.

tks
--
(paka)Patrick Shanahan Plainfield, Indiana, USA @ptilopteri
http://en.opensuse.org openSUSE Community Member facebook/ptilopteri
Registered Linux User #207535 @ http://linuxcounter.net
Photos: http://wahoo.no-ip.org/piwigo paka @ IRCnet freenode

--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: opensuse+owner@xxxxxxxxxxxx

< Previous Next >