• Welcome to The Network People Support Forums. Please login or sign up.

Upgrading a very old toaster, some questions...

Started by DrkShdw, January 23, 2005, 06:45:53 PM

Previous topic - Next topic


Hi all,

I've been a toaster user for a long time.
One of my very first toasters used in a production environment was developed for a restaurant.  I have upgraded the base OS and it is currently FreeBSD 4.10.

The toaster itself was installed in October of 2002. (I believe that was before matt actually gave them version numbers.)

Anyway,  long story short..  I'd like to format the machine,  Load FreeBSD 5.3, and install the latest toaster.  Here are the questions:

#1)  Can I just dump the vpopmail database from the old toaster,  and restore it on the new one?  I understand that the recent vpopmail will create the directories as needed, upon delivering the first piece of mail to the account.

#2)  I'm assuming I can just tar up the /usr/local/vpopmail/domains directory,  to preserve mail that the clients have saved on the server.  Is this correct?

#3)  Is there an easy way to preserve the undelivered mail queue?
    3a) If there is no easy way to preserve the queue,  I can always assign that machine a temporary IP,  and leave it online until the queue has run itself out, or expired.  While this is an option,  it isn't optimal.  I'd rather leave it as a last resort.

I recently installed the latest toaster (4.03) on a fresh FreeBSD 5.3 machine,  and the installation was painless,  and nearly hands off..  until it came time for configuration.  The only problem I had was with clamav.   It was installed as user clamav,  but the qmailscanner directory was owned/writeable by user vpopmail.  This was easily fixed by changing the clamav user to vpopmail in /usr/local/etc/calmd.conf  and chown -R vpopmail /var/run/clamav/

Great job matt.  I can't wait for the day when the entire toaster is in the FreeBSD ports tree as /usr/ports/mail/qmail-toaster.  make install == a working toaster,   yes please!


Why do you want to format and then upgrade? There are two compelling reasons not to, and instead upgrade the system to 5.3 in place.

1. You don't know what you don't know. That's not meant as an insult, it's just that there are things you aren't considering, and probably wouldn't catch until after you've formatted the box and then would LOVE to get back. After you format the disk, any helpful history you had is gone.

2. Qmail queue. Maybe there's nothing in the queue worth worrying about, but maybe there is. Do you know how to tell? Do you know how to back up the queue? (HINT: that's a trick question).

If I were you, I'd do as follows:

1. upgrade the OS to 5.3 via cvsup & make buildworld
2. upgrade Perl to 5.8.5
3. upgrade all the installed software via portupgrade
4. Install Mail::Toaster v.latest


The choice to format vs. upgrade in place is basically just a personal preference.  for major updates, I personally prefer to format the machine, ensuring all binaries/libraries are fresh.

While everyone has their personal preferences (and I have no problems if you disagree with me on this) I very vividly remember doing a 3.x -> 4.x upgrade in place.  Had it not been for the dumps,  I would have found myself in a lawsuit, I'm sure.

Since then, major version changes get a format, no questions asked.

As for losing any history, or getting things back I may have overlooked..  I fully understand what you mean.  I used the term "format" to simplify my post.  The client has bought a new machine,  and would like it to replace the old mailserver. As such,  I would not only have my backups of the machine,  I would also have the entire disk in an untouched/unmodified state.  Sorry for any confusion this oversimplification may have caused.

Mail queue:  I *can* leave the old machine online with a different IP,  until the queue is empty or expires.  However,  I'd rather learn how to backup the queue.   I did a bit of research on this subject before posting on the forum,  and it seems as though qmail freaks out if you try to just cp the queue into a new qmail installation.  from the descriptions I've read,  it sounds as though qmail somehow keeps an internal stat on messages that are in the queue, or something to that effect.  I'll research this last part a bit more.

But ultimately,  the entire machine will be new.  new hardware, new os, new toaster..

BTW:  thanks for taking the time to reply.  When I posted,  I didn't expect matt himself to reply.


Well, building a new box along side an old one is MUCH better than the original format and install procedure.

And yes, doing a major version upgrade can also be frightful, but after you've done it once or twice on a test server and know what to watch out for (something the documentation is very good at warning you these days), it can be done fairly safely. I do it "over the wire" for clients all the time.

Anyhow, based on your current prognosis, I'd go about it this way:

1. Build the new server (install FreeBSD)
2. Install Mail::Toaster v.latest.
3. rsync -av ~vpopmail/domains new:/~vpopopmail
  rsync -av /var/qmail/control new:/var/qmail
  rsync -av /var/qmail/users   new:/var/qmail

That will leave you with all your user accounts and mailboxes in place. There's something I'm forgetting, but that's the quick overview.


matt wrote on Mon, 24 January 2005 23:00

There's something I'm forgetting, but that's the quick overview.

The part you are forgetting is the most important reason I posted here Smile   How to deal with the old queue^^

Some day,  I may get the motivation to take a testbox,   install 4.x on it,  and go through the upgrade to 5.x in place.  The docs do seem to be a bit better these days.  But,   we'll save that for some day when I have free time.  Yeah,  free time..  I miss those days.

Found a new link that somehow I overlooked.

http://qmail.3va.net/qmailfaq.html#queuedisk" target="_blank">http://qmail.3va.net/qmailfaq.html#queuedisk

According to this, you can't backup the qmail queue.  I'll just go with the original idea,  and leave the old machine a couple days after the new server is up.

Thanks again matt Wink