Quantcast

SME Server (E-Smith) Mail Forwarding, Lists, Etc.

Get the WebProNews Newsletter:


[ Business]

The Mitel Networks SME Server (formerly E-Smith)is a friendly web server and e-mail gateway. The original E-Smith is now called Mitel SME Server V5. There is also a hardware/software bundle referred to as the Mitel 6000 Managed Application Server. Here we cover forwarding email to another mail account and mailing lists.

Every user account created can be forwarded to another account (you also have the choice of forwarding a copy to another account). You normally would do this using the administrative web panel, but behind the scenes, this is accomplished with the .qmail file in the user’s directory. Here’s what a user’s .qmail file looks like without forwarding:

#------------------------------------------------------------
# DO NOT MODIFY THIS FILE! It is updated automatically by the
# e-smith server and gateway software. Instead, modify the source
# template in the /etc/e-smith/templates directory. For more
# information, see http://www.e-smith.org.
# 
# copyright (C) 1999-2001 e-smith, inc.
#------------------------------------------------------------
./Maildir/


#------------------------------------------------------------
# TEMPLATE END

That just tells Qmail to deliver this user’s mail into the Maildir hierarchy (which
contains new, cur, and tmp subdirectories). If a forwarding address is added
through the SME Server web panels, the file might look like this:

#------------------------------------------------------------
# DO NOT MODIFY THIS FILE! It is updated automatically by the
# e-smith server and gateway software. Instead, modify the source
# template in the /etc/e-smith/templates directory. For more
# information, see http://www.e-smith.org.
# 
# copyright (C) 1999-2001 e-smith, inc.
#------------------------------------------------------------
&tony@aplawrence.com
./Maildir/


#------------------------------------------------------------
# TEMPLATE END

A forwarding address has been added. If we had told it not to deliver locally, then the “./Maildir/” line would have been removed.

What if you wanted to forward to two or more addresses? Typically that would be a mail list, althought there might be situations where an individual would want multiple forwarding. You could manually add multiple lines to .qmail, but although that would work, the SME Server web panels would overwrite your changes. It is possible to add Perl code to /etc/e-smith/events/user-modify or /etc/e-smith/templates-user-custom/.qmail to control the contents of .qmail. For example, the “vacation” add-on does exactly that. That would be a possible way to handle a mail list, though it could be a little clumsy.

If the list is small, you can do this entirely through the SME Web Manager. Simply create a locked account for each user you wish to be on the list, and forward that account to the actual email address of each person. I suggest creating the names with a common component to make it easier. For example, if I were on your mail list, you’d create an account for me such as “listtonyl” and would forward that to “tony@aplawrence.com”. Another accoount might be “listjimb” and would be forwarded to whatever jimb’s real email address is. You’d then create a group with the actual mail list name and put “listtonyl”, “listjimb” and everyone else you want in that group. Mail to that group would end up going to each of those addresses.

Qmail has another feature that can make such lists a little easier. Every user can create “dash” files in their home directory. The file name is “.qmail-something”. Put the email addresses you want in this file, one per line. You don’t need the leading “& for this. For example, I might create “.qmail-mylist”. Mail sent to “tony-mylist@aplawrence.com” would then go to whoever was listed in that file. The format is a little clumsy, but nothing stops you from creating another system level account caled “tonylist” and having that forward (using the web manager) to “tony-mylist”. That lets me send mail to “tonylist” instead.

You could also just create ~alias/.qmail-tonylist but the problem with that is that use of the web manager for aliases will update this area itself and wipe out your list. You could, with effort, modify the related code to prevent this, but it doesn’t seem to be wortn the effort to me.

Finally, you can install a real mailing list manager. Ezmlm is a popular choice, and there is a contributed RPM at http://www.e-smith.org/contrib/rpm-index/. Using a real list manager lets you do such things as restricting who can send mail to the list, makes it easy to add and subtract members, etc. I’d really recommend this if your list needs are at all complex.

Please read this disclaimer
Copyright and reprint info

A.P. Lawrence provides SCO Unix and Linux consulting services http://www.pcunix.com

SME Server (E-Smith) Mail Forwarding, Lists, Etc.
Comments Off
Top Rated White Papers and Resources

Comments are closed.

  • Join for Access to Our Exclusive Web Tools
  • Sidebar Top
  • Sidebar Middle
  • Sign Up For The Free Newsletter
  • Sidebar Bottom