[SOLVED] Replace current OS-Files with original ones (Debian 9)
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.
Replace current OS-Files with original ones (Debian 9)
Hi,
I am currently running Debian 9 and i think i screwed up...
Long ago I added ParrotSec Package Mirrors to my sources.list file. Shortly after the original Debian kernel was replaced by a laggy ParrotSec kernel. But that's not the problem... I "downgraded" my kernel to latest version of the plain Debian kernel, but since then I've got dependency problems over and over. I tried to fix it by doing this:
apt-get autoclean
apt-get update && apt-get upgrade
apt-get -f install
dpkg --configure -a
apt-get -f install
apt-get -u dist-upgrade
It didn't solve my problem. Now I am thinking about reinstalling Debian but I want to keep all my files, installed packages, and configs. Is there a possibility to keep them, when reinstalling?
Thanks for your help.
you could always backup your $HOME, plus a list of all installed packages.
but you cannot keep the packages themeselves.
also, the backed-up home likely won't "just work" when you mount it to become the new home. i wouldn't even try it, just collect the important configurations.
Nice link ondoho - if I'd followed that, I'd never have learnt anything ...
Never been a Debian user, but back in the day I used Ubuntu for a while. I successfully used a separate /home partition with different release levels. Generally I would create a new partition and install the new version there, using the current /home and creating same user(s) with same uid/gid. Reinstall necessary packages and off I'd go. Everything "just worked" as expected, including simply booting back to the previous release in need.
All this was is response to continued failure of the upgrade-in-place tool. Things have probably gotten better these days, but I have used the same philosophy successfully on Fedora.
So hopefully should work ok for the OP - after backups of course. Note the use of a separate /home partition - set that up first. A good deal less work if it goes ok. Probably not the "Debian way" though ...
Nice link ondoho - if I'd followed that, I'd never have learnt anything ...
Never been a Debian user
well that sort of explains why it is useless to you, no?
seriously, i added that because i hoped it
explains why adding parrotsec sources is only a good idea if you know what and why you are doing this, and why this is generally very difficult to undo
conatins some help on how to deal with breakage
it seems a bit thin on 2. though...
Quote:
I successfully used a separate /home partition with different release levels. Generally I would create a new partition and install the new version there, using the current /home and creating same user(s) with same uid/gid. Reinstall necessary packages and off I'd go. Everything "just worked" as expected, including simply booting back to the previous release in need.
without the smallest manual adjustments? i find that hard to believe, even 10 years ago.
desktop environments have gotten much more complicated these days.
even an advanced user cannot always tell if something in the gui doesn't work because of system files, or because of user configuration, so for the unconcerned average user a system is just as broken, if they try to use their old /home on a new install.
this is likely to happen, i've experienced it once or twice myself and seen it many more times on various forum threads.
Quote:
All this was is response to continued failure of the upgrade-in-place tool. Things have probably gotten better these days
i recently did a dist-upgrade on my debian server, no problems at all.
can't speak for ubuntu though.
Quote:
Note the use of a separate /home partition - set that up first. A good deal less work if it goes ok. Probably not the "Debian way" though ...
Hy. Do you try doing a backup? When i install a new SO or version, i did a full backup:
tar -czv /mnt/NewPartitionOS > "OS Linux,Debian version,date-with Kurumin.tgz"
Then, i can reinstall it from an auxiliar Linux (tiny version or liveCD like Kurumin o Knoppix).
Have a nice day.
Hi again! I forget mention to include in tgz name the type of code text (unicode,latin,utf,etc). When you reinstall (tar -xzvf arch.tgz) it extract file names with codes of the linux, but if you use a different distribution (or version) it can be different (in my case, old versions use latin1, newer use utf8).
I hope this was a good comment for you.
Have a nice day.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.