LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (https://www.linuxquestions.org/questions/debian-26/)
-   -   Can I do a rollback from testing to stable? (https://www.linuxquestions.org/questions/debian-26/can-i-do-a-rollback-from-testing-to-stable-130107/)

spamhog 12-30-2003 12:31 PM

Can I do a rollback from testing to stable?
 
I have a Knoppix desktop, and I would like to turn this machine into a home LAN fileserver.

I would like to roll back to stable the current install.
It a Knoppix 3.2, i.e. mostly testing, with a bit of unstable.
Well, ¨roll-back¨ is a big word, as it never was ¨stable¨ to start with.

Can it be done?

As you can guess, I can live with losing a few packages,
but I wonder if I going to get into a big mess.

Or, is it better to do a whole new install to woody stable?


TIA!

llamakc 12-30-2003 03:54 PM

I've done this from testing to stable, but it was back in Potato days. Provided GLIBC hasn't been moved up yet, you should be ok. I'd back up ANY data you need (DB dumps, websites, mail spools, home directories, media files) and give it a try. Worst case is you reinstall and still have all your backed up data. I usually archive /etc/ too.

spamhog 12-31-2003 05:44 AM

Thank you! I might give it a try.
To do so, I'd modify /etc/apt/apt.conf from APT::Default-Release "testing";
to APT::Default-Release "stable";
but is there more to it?

BR

SpamHog

llamakc 12-31-2003 07:11 AM

I've never modified that. You change the file /etc/apt/sources.list instances of "testing" to "stable". Then apt-get update && apt-get dist-upgrade. Of course, back up your data first.

Strike 12-31-2003 03:13 PM

dist-upgrading wouldn't work, as any currently installed package with a higher version than the ones in your sources.list has priority. Observe.

Code:


[ddipaolo@hundley ~]% apt-cache policy libc6
libc6:
  Installed: 2.3.2.ds1-10
  Candidate: 2.3.2.ds1-10
  Version Table:
 *** 2.3.2.ds1-10 0
        500 http://http.us.debian.org unstable/main Packages
        500 http://snapshot.debian.net unstable/main Packages
        100 /var/lib/dpkg/status

Note that '100' for the last one. That is the currently installed one. So, apt-get upgrading wouldn't upgrade this one as the installed version is equal to the candidate version (the one with the lowest number). Now when I change those to 'stable' and update ....

Code:

[ddipaolo@hundley ~]% apt-cache policy libc6
libc6:
  Installed: 2.3.2.ds1-10
  Candidate: 2.3.2.ds1-10
  Version Table:
 *** 2.3.2.ds1-10 0
        100 /var/lib/dpkg/status
    2.2.5-11.5 0
        500 http://http.us.debian.org stable/main Packages
        500 http://snapshot.debian.net stable/main Packages

See that the installed version is STILL the candidate version because it is a newer version and it's already installed. So unless you use /etc/apt/preferences to pin stable to have priority over currently installed packages, it won't work. But if you do use apt's pinning to do it, it can work.

So, in spite of all this discussion, my suggestion would still be to simply back up the necessary data and reinstall.

llamakc 12-31-2003 03:17 PM

Thanks for showing me apt-cache policy. I've pinned a few things recently (like ssh on my ppc boxes) back to stable but hadn't used or known about the policy option. Great stuff!


All times are GMT -5. The time now is 03:32 AM.