Integrating QMail, Vpopmail, Courier-IMAP, Web Admin, and MySQL Database
on Redhat Linux 8.0 using SRC RPM's

By: Mark Patrick (Patrick Computer Services)
EMail: mark@patrickservices.com
WebSite: http://www.patrickservices.com
Creation Date: April 1st, 2003
Last Updated: April 7th, 2003

First of all, special thanks to Miguel Beccari's project at 
http://qmailtoaster.clikka.com/ for making QMail installation 
MUCH easier for us all!  The following instructions are specific 
to RedHat Linux 8.0....

Make Sure RedHat 8.0 was setup fresh, in Server Mode, with PHP 4, 
Apache 2, and Development tools Included!

#############################################################
# How To Setup QMail,Vpopmail,CourierIMAP,web admin,webmail,
#     SMTP-auth on a server with a new install of Redhat 8.0
#     using SRC RPM's from http://qmailtoaster.clikka.com/
#############################################################
# Mark Patrick, Patrick Computer Services, March-April, 2003
#############################################################

wget ftp://mirror.sit.wisc.edu/mirrors/mysql/Downloads/MySQL-4.0/MySQL-server-4.0.12-0.i386.rpm
wget ftp://mirror.sit.wisc.edu/mirrors/mysql/Downloads/MySQL-4.0/MySQL-client-4.0.12-0.i386.rpm
wget ftp://mirror.sit.wisc.edu/mirrors/mysql/Downloads/MySQL-4.0/MySQL-devel-4.0.12-0.i386.rpm
wget ftp://mirror.sit.wisc.edu/mirrors/mysql/Downloads/MySQL-4.0/MySQL-shared-4.0.12-0.i386.rpm
wget http://qmailtoaster.clikka.com/download/stable/vqadmin-toaster-2.3.4-1.0.5.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/vpopmail-toaster-5.3.8-1.0.5.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/ucspi-tcp-toaster-0.88-1.0.5.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/qmailmrtg-toaster-3.4-1.0.5.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/qmailadmin-toaster-1.0.6-1.0.5.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/qmail-toaster-1.03-1.0.6.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/maildrop-toaster-1.4.0-1.0.3.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/horde-toaster-2.1-1.0.4.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/ezmlm-toaster-0.53.324-1.0.5.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/daemontools-toaster-0.76-1.0.3.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/courier-imap-toaster-1.7.0-1.0.2.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/control-panel-toaster-0.5-1.0.1.src.rpm
wget http://qmailtoaster.clikka.com/download/stable/autorespond-toaster-2.0.2-1.0.3.src.rpm

#############################################################
# Setup Proper Hostname!
#############################################################
# NOTE: Must return FQDN before starting! 
#       Setup /etc/hosts & /etc/sysconfig/network files and 
#       reboot system if it does not!
#############################################################
hostname -f      

#############################################################
# Uninstall Sendmail, If Installed
#############################################################
rpm -qa | grep sendmail
rpm -ev --nodeps sendmail*

#############################################################
# Uninstall Postfix & Related, If Installed
#############################################################
rpm -qa | grep postfix
rpm -ev fetchmail-5.9.0-16 
rpm -ev mutt-1.4-4
rpm -ev postfix-1.1.11-5

#############################################################
# Install & Start MySQL, If Not Installed
#############################################################
rpm -qa | grep mysql
rpm -ivh MySQL-server-4.0.12-0.i386.rpm
rpm -ivh MySQL-client-4.0.12-0.i386.rpm
rpm -ivh MySQL-devel-4.0.12-0.i386.rpm
rpm -ivh MySQL-shared-4.0.12-0.i386.rpm
/etc/rc.d/init.d/mysql start
ntsysv (set mysql to start on boot)

#############################################################
# Build and Install Major Pieces In Recommended Order
#############################################################
rpmbuild --rebuild --with rht80 daemontools-toaster-0.76-1.0.3.src.rpm
rpmbuild --rebuild --with rht80 ucspi-tcp-toaster-0.88-1.0.5.src.rpm
rpmbuild --rebuild --with rht80 qmail-toaster-1.03-1.0.6.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/daemontools-toaster-0.76-1.0.3.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/daemontools-toaster-doc-0.76-1.0.3.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/ucspi-tcp-toaster-0.88-1.0.5.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/ucspi-tcp-toaster-doc-0.88-1.0.5.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/qmail-toaster-1.03-1.0.6.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/qmail-toaster-doc-1.03-1.0.6.i386.rpm

#############################################################
# Create VPOPMAIL DB & User In MySQL
#############################################################
# NOTE: The username/password specified here must match those 
#       set in /var/qmail/control/sql
#############################################################
mysql -u root -p
CREATE DATABASE vpopmail;
GRANT ALL PRIVILEGES ON vpopmail.* TO vpopmail@localhost IDENTIFIED BY 'vpoppasswd';
quit
mysqladmin -u root -p reload 
mysqladmin -u root -p refresh 

#############################################################
# Build and Install VPopMail & QMail-POP3d In Order
#############################################################
rpmbuild --rebuild --with rht80 vpopmail-toaster-5.3.8-1.0.5.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/vpopmail-toaster-5.3.8-1.0.5.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/vpopmail-toaster-doc-5.3.8-1.0.5.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/qmail-pop3d-toaster-1.03-1.0.6.i386.rpm
ln -s /etc/rc.d/init.d/qmail /usr/bin/qmailctl

#############################################################
# Build and Install Courier IMAP
#############################################################
rpmbuild --rebuild --with rht80 courier-imap-toaster-1.7.0-1.0.2.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/courier-imap-toaster-1.7.0-1.0.2.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/courier-imap-toaster-doc-1.7.0-1.0.2.i386.rpm

#############################################################
# Build and Install AutoRespond
#############################################################
rpmbuild --rebuild --with rht80 autorespond-toaster-2.0.2-1.0.3.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/autorespond-toaster-2.0.2-1.0.3.i386.rpm

#############################################################
# Install MRTG From Redhat distro
#############################################################
# NOTE: May Need To Install The Following Before MRTG:
# rpm -ivh ftp://ftp.rpmfind.net/linux/redhat/8.0/en/os/i386/RedHat/RPMS/gd-devel-1.8.4-9.i386.rpm
# rpm -ivh ftp://ftp.rpmfind.net/linux/redhat/8.0/en/os/i386/RedHat/RPMS/freetype-devel-2.1.2-7.i386.rpm
# rpm -ivh ftp://ftp.rpmfind.net/linux/redhat/8.0/en/os/i386/RedHat/RPMS/libjpeg-devel-6b-21.i386.rpm
# rpm -ivh ftp://ftp.rpmfind.net/linux/redhat/8.0/en/os/i386/RedHat/RPMS/libpng-devel-1.2.2-6.i386.rpm
#############################################################
rpm -ivh ftp://ftp.rpmfind.net/linux/redhat/8.0/en/os/i386/RedHat/RPMS/mrtg-2.9.17-8.i386.rpm

#############################################################
# Build and Install MailDrop
#############################################################
rpmbuild --rebuild --with rht80 maildrop-toaster-1.4.0-1.0.3.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/maildrop-toaster-1.4.0-1.0.3.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/maildrop-toaster-devel-1.4.0-1.0.3.i386.rpm

#############################################################
# Build and Install Control Panel
#############################################################
# NOTE: May Need To Install The Following Before Control Panel:
# rpm -ivh ftp://rpmfind.net/linux/redhat/8.0/en/os/i386/RedHat/RPMS/httpd-devel-2.0.40-8.i386.rpm
# rpm -ivh ftp://rpmfind.net/linux/redhat/updates/8.0/en/os/i386/php-devel-4.2.2-8.0.7.i386.rpm
#############################################################
rpmbuild --rebuild --with rht80 control-panel-toaster-0.5-1.0.1.src.rpm
rpm -ivh /usr/src/redhat/RPMS/noarch/control-panel-toaster-0.5-1.0.1.noarch.rpm
rpm -ivh /usr/src/redhat/RPMS/noarch/send-emails-toaster-0.5-1.0.1.noarch.rpm

#############################################################
# Build and Install EZ Mail List Manager (EZMLM)
#############################################################
rpmbuild --rebuild --with rht80 ezmlm-toaster-0.53.324-1.0.5.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/ezmlm-toaster-0.53.324-1.0.5.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/ezmlm-toaster-doc-0.53.324-1.0.5.i386.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/ezmlm-cgi-toaster-0.53.324-1.0.5.i386.rpm

#############################################################
# Build and Install QMail Admin
#############################################################
rpmbuild --rebuild --with rht80 qmailadmin-toaster-1.0.6-1.0.5.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/qmailadmin-toaster-1.0.6-1.0.5.i386.rpm

#############################################################
# Build and Install QMail MRTG
#############################################################
rpmbuild --rebuild --with rht80 qmailmrtg-toaster-3.4-1.0.5.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/qmailmrtg-toaster-3.4-1.0.5.i386.rpm

#############################################################
# Build and Install VQAdmin
#############################################################
rpmbuild --rebuild --with rht80 vqadmin-toaster-2.3.4-1.0.5.src.rpm
rpm -ivh /usr/src/redhat/RPMS/i386/vqadmin-toaster-2.3.4-1.0.5.i386.rpm

#############################################################
# Build and Install Horde Webmail
#############################################################
rpmbuild --rebuild --with rht80 horde-toaster-2.1-1.0.4.src.rpm
rpm -ivh /usr/src/redhat/RPMS/noarch/horde-toaster-2.1-1.0.4.noarch.rpm

#############################################################
# Post Setup Steps and Various Settings
#############################################################
1. Setup /etc/httpd/conf/httpd.conf
   |--------------------------------------------
   | Set The following:
   |-- ServerName webmail.yourdomain.com
   |-- DirectoryIndex index.html index.php index.html.var
   |--------------------------------------------

2. Setup /etc/php.ini
   |--------------------------------------------
   | Set The following:
   |-- short_open_tag = On
   |-- register_globals = On
   |--------------------------------------------

3. Customize Horde, If Desired
   |--------------------------------------------
   | For Horde 2.1 and its components, configure 
   | the settings in /horde/config/html.php and 
   | in /horde/componentname/config/html.php. The 
   | settings for various colors, fonts, and 
   | styles are found within, with explanatory 
   | comments and variable names.
   |--------------------------------------------

4. apachectl restart

5. Install an AntiVirus!  I prefer Clam AntiVirus at 
   http://clamav.elektrapro.com/. For instructions, 
   see: http://clamav.elektrapro.com/doc/html/node8.html.  
   Setup automatic virus definition updating at 
   http://clamav.elektrapro.com/doc/html/node11.html.

   Basically, the steps to install Clam Antivirus are:
   
   groupadd clamav
   useradd -g clamav -s /bin/false -c "Clam AntiVirus" clamav
   wget http://clamav.elektrapro.com/stable/clamav-0.54.tar.gz
   tar zxpvf clamav-x.yz.tar.gz
   cd clamav-x.yz
   ./configure; make
   su -c "make install"

   The steps to enable automatic updating are:
   
   touch /var/log/clam-update.log
   chmod 644 /var/log/clam-update.log
   chown clamav /var/log/clam-update.log
   freshclam -d -c 2 -l /var/log/clam-update.log
   
   Lastly, schedule the updates by adding them to cron: 
   crontab -e 
   and add this line:
   0 8	* * *	/usr/local/bin/freshclam --quiet -l /var/log/clam-update.log

6. Point your browser to: 
    
   http://webmail.yourdomain.com/admin-toaster/
   
   to administer your new webmail server.  The default 
   login is admin/toaster.  Change the password once you
   are logged in.


Home ] [ Software ] [ Forum ] [ Redhat Linux Guides ]
Feedback ] [ Contact Information ]

File, qmail_toaster_rpms.dat, not found!
You are the th visitor since April 1st, 2003