[rescue] Mail Server

Bill Bradford mrbill at mrbill.net
Tue Dec 21 09:57:48 CST 2004

On Tue, Dec 21, 2004 at 08:31:42AM -0600, Wes Will wrote:
> >Also, Bill, do you have a writeup of your postfix/amavis/clamAV 
> >installation, and maybe even a business case for it?
> I have that message archived from the original posting if you want it.  I
> found the description to be dead useful.  (Ping me off-list for forwarding.)

Here's my notes.  I'll be expanding these out a bit later.  Of course, use
the latest versions of everything (perl, clamav, etc) as this was written 
six months ago.

Solaris 9, "Developer" install
enable UFS logging in /etc/vfstab
disable all stuff in /etc/rc3.d and rc2.d that you don't use (dtlogin, etc).
ln -s /usr/sfw /usr/local

sunfreeware packages:
gnu make
gnu tar
gnu cc
gnu iconv
gnu cc
gnu awk
gnu m4
gnu autoconf
gnu automake
gnu coreutils
gnu findutils
gnu grep
gnu wget

rename Sun tar,make,awk,cc to sun.whatever, make symlinks at locations of
        "factory" programs to point to GNU stuff in /usr/local/bin/

>From source:
install ncftp
install BerkeleyDB 4.1.25 (configure --prefix=/usr/local)
install perl 5.8.4
        run cpan
        install Bundle::CPAN
        install Bundle::LWP
        install Bundle::libnet
        install Net::DNS and prerequisites
        install Inline::C and prerequisites
        Install BerkeleyDB
        install DB_File
        install Archive::Zip
        install Convert::TNEF and prereqs
        install Convert::UUlib (will have to download from CPAN by hand)
        (possibly already installed) install Mime::Base64
        (possibly already installed) install Mime::Parser
        (possibly already installed) install Mail::Internet
        install Net::Server
        (possibly already installed) install Net::SMTP
        (possibly already installed) install Digest::MD5
        (possibly already installed) install IO::Stringy
        (possibly already installed) install Time::HiRes
        install Unix::Syslog (tests will fail, install by hand)
        install MIME::tools 6.2x (have to download / install by hand)

# export ABI=32
install GNU MP from source (package doesn't work for some reason)

add users and groups:
groupadd clamav
useradd -g clamav clamav
groupadd amavisd
useradd -g amavisd amavisd
groupadd postdrop
useradd postfix
add clamav and amavisd to clamav group in /etc/group
add amavisd and clamav to amavisd group in /etc/group
add postfix to postdrop group in /etc/group

more stuff from source:
install ClamAV 0.74 (configure --sysconfdir=/etc)
        install Perl module Mail::ClamAV via CPAN
install Postfix 2.1.4 (export LD_LIBRARY_PATH=;gmake;gmake install)
cd /etc/postfix; mv postfix old.postfix
cd /etc; scp -r root at MACHINE.com:/etc/postfix .
install amavisd-new-20040701, copy amavisd to /usr/local/sbin/amavisd mode 750
ln -s /usr/local/sbin/amavisd /usr/bin/amavisd
install SpamAssassin 3.0-pre2
install VIM 6.3 (configure --disable-gpm --disable-nls --without-x)
install GD lib v2.0.27 (configure --disable-shared)
install rrdtool (latest) (gmake install; gmake site-perl-install)
ln -s /usr/local/rrdtool-1.0.48 /usr/local/rrdtool
install mrtg (latest)
ln -s /usr/local/mrtg-2 /usr/local/mrtg
install Apache 2 (configure --enable-rewrite --enable-so --prefix=wherever)
mkdir /www/vsites/
scp -r root at MACHINE.com:/usr/local/mailgraph .
install BIND 9.2.4rc6 or newer (configure --disable-ipv6 --disable-linux-caps)
cd /var
scp -r root at MACHINE.com:/var/named .
cd /disk
mkdir amavis
mkdir clamav
chown -R amavisd:amavisd amavis clamav
cd /etc/
rm clamav.conf
rm freshclam.conf
scp root at MACHINE.com:/etc/amavisd.conf .
scp root at MACHINE.com:/etc/clamav.conf .
scp root at MACHINE.com:/etc/freshclam.conf .
edit amavisd.conf, change $MYHOME to /disk/amavis
touch /var/log/clam-update.log
chown amavisd:amavisd /var/log/clam-update.log
cd /usr/local/share
chown -R amavisd:amavisd clamav
run "freshclam" to test updating
add "/usr/local/bin/freshclam -d" to startup scripts


bill bradford
austin texas

More information about the rescue mailing list