[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

upgrading tips (was Re: Any pitfalls of upgrading to libc in "unstable"?)

On Sat, 7 Dec 1996, CoB SysAdmin wrote:

> What I need to know is, is there any magic order I need to do
> everything in? I know the last time I tried to futz with my libraries,
> my whole system *stopped* (because I "rm"ed the old libraries before
> copying in the new ones. I guess "cp" was linked to shared libs,
> because I never made it that far. cp complained that it couldn't link
> to the shared libs, etc. I had to eventually boot the install disks
> and replace the original shared libs.

you must have done that on a slackware system (or some other distribution
which doesn't have a neat packaging system like debian) 

with debian, the easiest and safest way to upgrade your libc & ldso is to
download the relevant packages and use dpkg or dselect to install them.
It's all done automatically and safely. 

> So, seeing as how this has to happen on a *live* web server, I'd like
> to get any tips in advance. For example:
> I'm going to update ldso at around the same time. Should one come before
> the other? (ie, install new ldso, then new libc, or vice-versa?).

shouldn't really matter.  If it does, then the libc & ldso packages are
created so that they depend on the correct version to be installed first.
As a completely hypothetical example, if ldso version 9.99 required libc5
version 5.5.55 then dpkg would not allow you to install that version of ldso
UNTIL the correct version of libc5 was installed.

The only "gotcha" is that certain packages may depend on other packages
which you haven't downloaded yet.  The best solution is to mirror the
distribution (see below).  Failing that, always check the requirements of
any package with "dpkg -I packagefilename.deb" before installing it. 
(note capital "-I" for Info, not lowercase "-i" for install)

once again, dpkg wont let you go wrong - if the dependancies arent
installed then it wont let you upgrade.

note: you can override dpkg's restrictions with the --force options. 
sometimes you need to.  Usually you don't, but it's nice to know you can
if you have to :-) 

Read the documentation.

> Hints, tricks, suggestions?

use dpkg & dselect to do all your upgrades. THESE TOOLS ARE THE MAIN
easy to upgrade individual packages or the entire distribution in an
automated, mostly painless, mostly safe way. It isn't 100% perfect
(nothing is) but it's certainly several orders of magnitude better than
doing it all by hand.

Best tip I can give you is: If you have the bandwidth and/or the
disk space (about 400mb for just the binaries, over 1gb if you want
everything including sources for stable & unstable, plus the kitchen
sink), then mirror either the stable or the unstable debian tree and
upgrade regularly from that. I find that I have more minor hassles
upgrading the longer I leave it between upgrades.

If you have a test system (i.e. one that you use but which nothing is
dependant on and customers/users aren't going to scream about if it goes
down) then use that to test upgrades. Upgrade it first. Find out what
might go wrong. If it works fine then it's safe to upgrade your live
system. Otherwise, submit a bug report, wait a few more days for fixes to
trickle into the mirror and try it again. 

I've been doing this with my debian systems for over a year and havent yet
run into any problem which couldn't be fixed in an hour or so.  Most
problems can be avoided entirely just by clearly thinking about and
planning what you are about to do...dpkg is a great tool but it's not a
substitute for making active use of your own brain. 

Finally, always leave yourself a way to back out to the way it was before
you started changing things. Sometimes this means making sure that you
have a copy of the .deb archive of the OLD version that you are about to
upgrade...if you have it on CD, no problem. 

        Use dpkg
        Leave yourself an out.


This message was delayed because the list mail delivery agent was down.

Reply to: