Subject: Re: formail problem - can't fork

From: Samuel Tardieu <[email-masked]>
Date: Thu, 22 Sep 1994 20:21:40 +0200

>>>>> "Kevin" == Kevin Pinto <[email-masked]> writes:

    Kevin> I'm using formail to forward a friend's mail folders to
    Kevin> him, at his new organization, like this:

    Kevin> for FILE in mail/* do formail -ds /usr/lib/sendmail
    Kevin> NewAddress@NewPlace < $FILE done

    Kevin> The shell script works fine, except that formail says that
    Kevin> it can't fork.  The man page says that this happens when
    Kevin> the machine runs out of processes.

    Kevin> This makes sense, except, what am I supposed to do?  I
    Kevin> can't change the number of processes on this machine, and I
    Kevin> can't change the size of his folders.  (They're all quite
    Kevin> large).  I'm not using the -n option, so I don't understand
    Kevin> why formail creates multiple sendmail processes in the
    Kevin> first place (I checked with ps).

    Kevin> I've already tried using a sleep 20, after the formail step
    Kevin> - no luck.

    Kevin> Any ideas?

Maybe sendmail would return faster if you only queue your mail. That
means that mail you send won't be sent immediatly, but will stay in
the queue until the next queue run (usually 30 minutes or 1 hour).

You should try the -odq option of sendmail.

  Sam
-- 
"La cervelle des petits enfants, ca doit avoir comme un petit gout de noisette"
                                                       Charles Baudelaire

---

From: Roman Czyborra <[email-masked]>
Date: Fri, 30 Sep 1994 09:38:44 +0100

> I'm using formail to forward a friend's mail folders to him, at his
> new organization.  The shell script works fine, except that formail
> says that it can't fork.

> for FILE in mail/*
> do formail -ds /usr/lib/sendmail NewAddress@NewPlace < $FILE
> done

I would send them en bloc so you don't need that many sendmail
processes and get an exact copy in the right order:

	tar cf - mail | gzip > mail.tar.gz
	mpack mail.tar.gz friend