<br /> Shockingly easy server upgrade – Debian Planet

Welcome to Debian Planet

News for Debian. Stuff that *really* matters


DP is sponsored by Xinit Systems.

Domains paid for and hosted by uklinux.net.

Buy your Debian merchandise at DebianShop.com.

These are important Debian sites one should not be without!

  • Official Debian site
  • Package search
  • Mailing list archives
  • Bug reports
  • Debian on CD
  • Debian Weekly News — excellent news source!
  • Unofficial APT sources

  • Developers’ Corner
  • Community
    Need help? You’re not alone on this planet.

  • Planet Debian
  • debianHELP
    (User support site)

  • Debian International
  • DebianForum.de

  • DebianForum.dk

  • EsDebian

  • DebianWorld

  • Debian-Fr

  • MaximumDebian

  • DebianItalia
  • DebianUsers

  • Debian-BR

  • DebianHOWTO

  • Russian Debian (Русский)
  • Debian-JP
  • Debian Suisse
  • Contribute
    Got that latest or greatest scoop? Perhaps you have some important news for the Debian community? Submit a news item!

    Or perhaps you’ve written a rather ground breaking insight into some aspect of Debian and you feel compelled to share it with others? Knock up a longer editorial article and send it to the editors.

    General feedback should be sent to staff@debianplanet.org

    The place to get help on a Debian problem (after reading docs) or to just chat and chill is #debian on irc.oftc.net.

    Many of the Debian Planet staff live there so pop by and say hello.

    Debian Planet also has its own channel on the same network called #debianplanet.

    Support Debian through Bytemark Hosting. At least £7 will be given for each new account


    Shockingly easy server upgrade
    Submitted by mmims on Tuesday, December 03, 2002 – 02:44
    DebianFor a couple of years, I’ve been running a Debian GNU/Linux server in-house. The system is small, a 233 MHz Pentium MMX with 128 MB RAM. Initially, it only ran Majordomo with a couple of very small e-mail lists. As new needs arose, I began adding additional services: Samba, mgetty for two incoming fax lines, CVS, Jabber, Bugzilla, etc.

    Eventually, with the increasing demands placed on the system, performance became a concern — an upgrade was in order.

    A Dell PowerEdge 1400SC with 1.4 GHz Pentium III, 512 MB RAM, and a 4 x 36 GB RAID array using a PERC 3/DCL controller was ordered to replace the old system.

    The new server was ordered via 2-day air shipping to arrive in time to potentially spoil my Thanksgiving weekend. It Wednesday, the day before the holiday. We typically take a 4 day weekend. It was clear I was expected to have the new server up and running by Monday morning to avoid any down-time. The company’s experience has typically been with Windows server upgrades. The last one took nearly two weeks before it was 100% complete (a hardware upgrade coupled with an Exchange Server 5.5 to Exchange Server 2000 upgrade).

    I found an excellent resource for Linux and Dell PowerEdge servers at Matt Domsch’s Linux page. In particular, the netinst image provided by Steve Mickeler was invaluable.

    What follows, is the step-by-step process I went through to upgrade the system. Perhaps my searching skills have failed me, but I have not found HOW-TO style documentation for this type of upgrade. The method I used may, therefore, not be optimal (or even correct). It was surprisingly simple, though — so easy, in fact, that I must have missed something. More experienced Debian admins may be able to point out the shortcomings. If this technique proves to be sufficient, perhaps it will benefit others.

    The upgrade process:

    Download the netinst image

    Download Steve Mickeler’s netinst image and create a bootable CD.
    Install a base Debian system

    Use the netinst CD to install a base Debian system on the PowerEdge server.
    Edit /etc/apt/sources.list

    Edit /etc/apt/sources.list to provide access to an appropriate archive (CD, FTP, or HTTP) to obtain the two additional Debian packages required to complete the upgrade.
    Install netcat and pax
    apt-get install netcat pax
    Create a directory

    Create a directory to contain the old server contents and make it the current directory. I used the name of the old server:

    mkdir /minneola; cd /minneola
    Prepare to receive

    Pick an arbitrary port to listen on and prepare to receive the contents of the old server:
    nc -l 2666 | pax -rvp e
    Prepare to send

    Prepare the old server to transfer data. First enter single user mode to stop services and prevent changes to the file system during the transfer:
    telinit 1
    Un-mount foreign devices

    umount any all nfs, smb, cdrom, and other devices that are not part of the file system you wish transferred.
    Transfer top-level directories

    Transfer selected top lever directories to the new system:
    cd /
    pax -wv bin etc home lib root sbin usr var | nc -w 3 2666
    In my case, this set of top level directories contained all of the data I needed. The new server had been configured with a static address in the private addressing range we use in-house. I relied on the new system’s existing mnt, boot, dev, and tmp directories and the cdrom and floppy mount points. My case was also simplified by the fact that I used a single, large partition on both the old an new systems.

    The transfer time depends upon the amount of data to transfer and the speed of your network connection. In my case, it took about 2.5 hours to complete the transfer. The -v option used on the pax command will provide enough output to help you gauge the progress.
    Reboot from CD

    Reboot the new system using the netinst CD. When booted, start a shell and mount the the appropriate hard disk volume. In my case, that was /dev/sda5. I used the existing /mnt directory as a mount point. Make the mounted directory current.
    mount /dev/sda5 /mnt
    cd /mnt
    Copy hardware specific files

    Copy the three files with hardware specific configuration from the root directory into the old server tree:
    cp /etc/modules minneola/etc/modules
    cp /etc/fstab minneola/fstab
    cp /etc/lilo.conf minneola/lilo.conf

    Move kernel modules

    Move the kernel modules to the old server tree:
    mv /lib/modules/2.4.19-ac4 minneola/lib/modules
    Replace top-level directories

    Replace the top-level directories with the old server copies and remove the empty directory that held the old server tree.
    for i in bin etc home lib root sbin usr var; do
    rm -fr $i
    mv minneola/$i .
    rmdir minneola

    Reboot the new server and you’re done!

    This procedure work well for me. I started the process at 7 PM and was
    completely finished by 10 PM preserving my 4-day, holiday weekend. All the services came up without a problem and everything seems to be running well. I wonder, however, if I’ve missed anything important. Are there other hardware specific files I should copy from the old server or edit on the new server other than the three listed above?

    I suspect I re-invented the wheel and documentation exists describing how to migrate from one system to another with dramatically different hardware. Where is that documentation?

    Comments are welcome.

    Category: HOWTOs

    Control panel

    Comment viewing options:

    Select your prefered way to display the comments and click ‘Update settings’ to activate your changes.

    Subject: updated dell netinst images
    Author: shmick77
    Date: Tuesday, 2002/12/03 – 14:55
    I have created a new dell specific netinst ISO.

    It can be found at http://neptune.ca/~steve/netinst/

    Its compiled against 2.4.20


    – Steve Mickeler

    [ return ]

    Search articles

    ·News (341)
    ·Features (5)
    ·Site News (14)
    ·HOWTOs (61)
    ·Tips (17)
    ·Opinion (26)
    ·Q & A (27)
    ·Sponsorship (1)
    ·Press Releases (2)

    Log in


    Remember me

    » Register
    » New password

    Debian Security Announcements
    DSA-713 junkbuster
    DSA-661 f2c
    DSA-712 geneweb
    DSA-711 info2www
    DSA-710 gtkhtml
    DSA-709 libexif
    DSA-708 php3
    DSA-707 mysql
    DSA-706 axel
    DSA-705 wu-ftpd

    Planet Debian
    Amaya Rodrigo: My glass cage
    Benjamin Drieu: Contribution accepted!
    Aigars Mahinovs: separate ‘Out of Debian’ blog?
    Aigars Mahinovs: The Deamon, the Gnu and the Penguin
    Benjamin Mako Hill: The Wrong Thong
    Benjamin Mako Hill: Benjamin Mako Hill
    Erich Schubert: Can bugzilla harm a project?
    Joey Hess: moving
    Steve Kemp: Buying Sarge Snapshots? (UK)
    Wouter Verhelst: Waffles

    Latest poll: Which release scheme should Debian follow?
    Continue this way (release when ready)
    Give up on releasing
    Split the release up
    Speed the release up
    Crank the workload up (see DebianWiki ReleaseProposals for details on these)

    Total votes: 372
    0 comments · older polls

    home · archives · news feeds · about · polls · search · sections · user account

    Powered by the amazing Drupal

    Debian Planet is not officially related to the Debian Project.
    Debian and the Debian logo are trademarks of Software in the Public Interest, Inc.