Installing Mail Master™

Section 1 Initial Installation

Step 1: Confirm/Install Prerequisites

  • Hardware Requirements
    Pentium 133+ w/ 64 Mb. RAM (minimum) and 50 MB free disk space.
    For recommended hardware systems by # users Click Here
  • Operating System
    RedHat Linux 7.2/7.3 are our certified platforms. Any version of Linux with a 2.2 or greater kernel should work.



    Group quotas must be enabled on the partition containing /var. How to set up quotas.
     
  • System Software Requirements

Step 2: Install RPMs
Install the RPMs supplied (You should already have all prerequisites above installed).
Order/RPM Description
1. arc Compression Library
2. lha Compression Library
3. unarj Compression Library
4. unrar Compression Library
5. unzip Compression Library
6. Mysql Mysql Database
7. Mysql-client Mysql Database Client
8. Mysql-shared Mysql Database Shared Libraries
9. Mysql-devel Mysql Database Devel
10. Spamassassin      Anti-SPAM Program
11. clamscan Anti-Virus Program
12. amavis Program that integrates Sendmail with clamscan
13. tantalus (optional) Program that stops mail spammers from guessing email addresses
14. mailmanager *Lone Star Internet's Mail Master™
Note: *Freshclam Daemon

  • Freshclam will start and install itself in the startup scripts.
  • Freshclam keeps the virus definition database current.

Step 3: Run Install Script
Once mailmanager rpm is installed, you will need to run "installscript.pl" located in /var/www/html

  • This script will step you through the installation process of downloading the required perl modules and will setup the MySQL database. Note: If this program exits abnormally, it can be safely rerun.
  • The Perl modules installed are:
  • Module Description
    Bundle::CPAN    Basic PERL Modules to fetch other PERL Modules
       File::Spec Cross Platform File Access
       Digest::MD5 MD5 Hashes for validity of PERL Modules
       Compress::Zlib Uncompress gz files
       Archive::Tar Uncompress Tar Files
       Bundle::libnet Basic NET libraries
          Data::Dumper For Debugging Data in PERL
          Net::Telnet Basic Telnet Capabilities (not used but is included in the bundle)
          Net::Cmd Network Command Class
       Term::ReadKey Terminal Line Input Library
       Term::ReadLine::Perl Terminal Line Input Library
       CPAN::WAIT Allows CPAN to connect to a WAIT server
       CPAN Module to Fetch Other PERL Modules
    Archive::Zip Ability to Unzip files
    CGI::Application Handles Multiple steps in CGI Applications
    Convert::TNEF PERL Module to read TNEF Files (mail attachments)
    Convert::UUlib PERL Module to uncompress Mail Attachments
    DBD::mysql Mysql Drivers for DBI
    DBI Database Interface in PERL
    GD Library Interface to make graphic files
    GD::Graph Makes Graphs and pie charts
    GD::Text::Align Aligns text in graphs and pie charts
    HTML::Template An HTML Template library used by the userlogin/admin section
    MIME::Parser Parsers Mail to look for attachments
    LWP::Simple Ability to fetch web pages
    String::Random Ability to create random salts to encrypt passwords
    Crypt::PasswdMD5 Ability to create UNIX crypt passwords
    Unix::Syslog Ability to write to the UNIX Syslog daemon
  • During this step, the program will ask you to install the default users inside mysql.
    • Currently the software requires two databases (an additional 1 database is optional), "horde" and "mailadmin". Each database needs a specific user created ("horde" and "mailadmin" respectively).
    • The Optional Database is for Tantalus called tantalus in mysql.
  • The install script will run MySQL and requires you to enter a MySQL username and password that has table create and grant privileges (e.g. root).
    • The database setup will then be completed.
      Note: If you need to "recover" the base admin user account (i.e., you forgot the password), you may rerun ./installscript.pl db. This will reset the admin user's privileges and his password.
    • The install script will add one line to root's crontab that executes periodically to perform modifications to setup files per changes made using the administrative tool.

 

Section 2 Configuration/Additional Info

Apache Configuration

  • You must enable execution of files ending in .cgi for the following directories:
    /var/www/html/linuxmailmanager/admin
    /var/www/html/linuxmailmanager/userlogin
  • This line will be added to the end of /etc/httpd/conf/httpd.conf
    Include /usr/share/linuxmailmanager/conf/mailmanager.conf

Initial Admin User Setup

  • Default Sysop User
    The default sysop user created has the username and password of admin. Please change this.
    • Browse to http://<yourserver>
    • Select "admin login" from the top navigation
    • Login as admin w/password admin
    • Select "sysops"
    • Select "view" from the sub-menu
    • Select the + symbol under Actions for the "admin" user
    • Change the password field
    • Select "update"

Check System Settings

  • Select "setup" from the top navigation
  • Review all settings but especially: SMTP, POP. IMAP servers and the admin email address
  • If Tantalus is installed, the default settings are usually sufficient to stop normal spammers

Now create your first domainadmin user.

  • Select "admins" from the top navigation
  • Select "add" from the sub-menu
  • Complete the form
  • Select "update"

Now add your first domain.

  • Select "domains" from the top navigation
  • Select "add" from the sub-menu
  • Complete the form
  • Select "insert"
  • The domain is created. Sendmail will start accepting mail for that domain within 5 minutes (assuming the DNS MX records are pointed to mail.<newdomain>.com).

Now add your first user.

  • Select "domains" from the top navigation
  • Select "view" from the sub-menu
  • Select the domain name in the first column.
  • Select "Add User" in the far right column
  • Complete the form
  • Select "insert"

You now know the basics. If you need help, there is content sensitive help on each page. Good Luck and have fun.

The Crontab

  • The crontab is designed to be secure. Nothing a user enters from the web will be run as a system command. The cronjob's responsibilities include adding and removing users, domains, forwards, vacation messages, spam filters, reindexing the .htaccess file for the admin section, and recounting disk space usage.
  • The cronjob should run every 5 minutes. If an error occurs during a user add / delete, an error message will be sent to root's mail on that server.

Virus Messages

  • As an admin, you will receive messages stating that various e-mails contain viri. This simply states that the e-mail virus scanner is working and all is ok. All contained viri are kept in /var/virusmails in virus-YYYYMMDD-HHMMSS-PID format. (PID=Process ID)
  • You can safely delete any virus in /var/virusemails

SPAM messages.

  • As a user of this system, you will receive messages stating that a message is SPAM.
  • Each SPAM message will state why that message has been listed as SPAM in the email header.
  • To add new rules, enter the "user administration" section of the application and add rules.
  • The global system rules are kept in /usr/share/spamassassin/ and can be edited.
  • Individual user spam rules are kept in ~/.spamassassin/user_prefs

How Virtual Users work

  • When a user creates an account, the account is created with username_domain in /etc/passwd. (So email account username@userdomain.tld is user account username_userdomain.tld in Mail Master™.)
  • All domain users are added to the same group (for quota purposes)
  • The real email addresses for the user accounts are located in /etc/mail/virtusertable

Other Notes

  • This program will not overwrite any additional lines in /etc/mail/virtusertable, ~/.forward, or /etc/mail/access (above the comment line). This means you can manually edit these files without the possiblities of your personal configuration being deleted.

Section 3: Backup

Back up the following, they will be needed upon installation in the event of a hardware failure.

  • mail: /var/spool/mail/*
  • /home/username_userdomain.tld/.spamassassin/user_prefs
  • /home/username_userdomain.tld/.vacation
  • /home/username_userdomain.tld/.forward
  • /etc/passwd
  • /etc/shadow
  • /etc/aliases
  • /etc/mail/virtusertable
  • /etc/mail/local-host-names
  • /var/lib/mysql/*

Section 4: Credits / License

This program was written by Lone Star Internet, Inc., a Texas Corporation 512-708-8006.
All parts written by Lone Star Internet are COMMERCIAL SOFTWARE.
Spamassassin, amavis, clamscan, perl, and mysql are all distributed under the GPL License.
Sendmail is under the Sendmail License.


 

Have any problems? First check the FAQ, then email us at support@linuxmailmanager.com or call us at (800) 538-0538.