Our friends at C&C Software wrote a blog post recently about how to track an email message in MDaemon’s log files for troubleshooting purposes, and I wanted to share it with you. When troubleshooting a mail delivery issue, it helps to know what logs to look at and what information to search for in the logs. For example, if you’re looking for an inbound message, you can review the MDaemon-SMTP(in).log file. If you’re tracking a message as it passes through the queues, you can use the MDaemon-Routing.log file. You can also use Queue & Statistics Manager to pull up log transcripts for specific messages. Click here to view a tutorial video on Queue & Statistics Manager. Click here to read C&C’s post on tracking email messages in the logs.
In today’s business environment, business-critical processes rely heavily on networked applications to be productive. When a failure occurs, productivity is lost, and this often translates into lost revenue for the company. This is especially true of email. To address these issues, companies can implement a high availability/failover strategy. Some of our MDaemon users have asked for information on setting up failover for their email infrastructure, so we’ve put together a guide to help MDaemon administrators achieve this.
In the simplest terms, the way this works is this: You’ve got a primary server that is running MDaemon. You have a backup server that will take over as the mail server when a failure occurs on the primary server. No third-party tools or applications are required. With a bit of preparation, you can implement failover/redundancy between two MDaemon servers using software tools that are built into the Windows operating system.
The following is a complete list of requirements needed to implement this solution in a network environment:
- Two Windows 2008R2 Servers
- MDaemon 14.5 or later must be installed and configured on both servers with the MDaemon Windows service start-up option set to ‘Manual’
- The Windows Network Load Balancing Feature must be installed and configured on both servers.
- A third NLB ‘control server’ for making changes to the NLB configuration on the cluster nodes.
- A working Active Directory environment with a Windows Server 2003 or higher domain functional level.
- Microsoft’s Distributed File System Replication feature installed on both servers with the latest available DFSR updates and patches.
- For networks using Network Address Translation (NAT), a NAT rule to NAT outbound connections from both cluster hosts to the same public IP source address.
Other helpful guides can be found on our Literature page.
It is possible to create any number of schedules you wish. You can name each schedule and attach a schedule to a custom mail queue. You can also create as many custom mail queues as you want. Use the Content Filter to move messages into your custom queues based on any criteria you wish. For example, you can create a schedule called ‘Large Messages’, create a queue to store those messages, and then create a Content Filter rule using the ‘MOVE message to custom QUEUE’ action to move messages over a certain size into that queue. If you’d like mailing list messages delivered at certain times then create a schedule called (for example) ‘List Mail’, create a queue, and then use a Content Filter rule to move messages with an X-MDMailing-List header into the new queue.
4. Select whether the queue is for local or remote mail.
5. Click on “Add.”
6. Open the Security menu and click on “Content Filter.”
7. Click on “New Rule.”
8. Create your new Content Filter rule. The steps here will vary based on what criteria you’d like to use (some examples include Message is larger than XX, X-MDaemon-Deliver-To header contains firstname.lastname@example.org, Message has .zip attachment). For actions, be sure “… Move to custom queue” is one of them and when prompted, select your new queue.
9. Click “OK.”
10. Click “OK.”
11. Navigate to Setup | Event Scheduling.
12. Select Mail Schedule Options in the left-hand navigation menu.
13. Click on “New.”
14. Type in a name for the new custom schedule.
15. Click “OK.”
16. Configure the options for your custom queue as desired. Use these settings to deliver queued mail at regular intervals, or to deliver queued mail certain events have taken place, such as when a specified amount of time has elapsed or after a certain number of messages are queued.
17. Click on your new schedule in the left-hand navigation menu.
18. Configure times when the queue will be processed and other options as desired, then click “Add.”
19. Click “OK.”
And that’s it! You can get pretty creative with custom mail queues and scheduling.
Are you receiving the following message from MDaemon?
“The disk space on the drive(s) used by your MDaemon mail server has dropped below a preset threshold. SMTP, DomainPOP, and MultiPOP functions have been disabled. You must manually restart them once some space has been freed up.”
The hard drive which mdaemon.exe is located on is running out of space. Your MDaemon is configured to monitor the hard drive space and if you drop below a certain threshold, it sends an e-mail to your postmater account and disables TCP/IP services. The reason for this is to prevent running completely out of disk space.
The settings for this feature can be reached by clicking on Setup > Preferences > then clicking on Disk.
You may want to use a disk space utility such as i.Disk or WinDirStat to see what folders are consuming your disk space. These are the MDaemon folders most likely to be using all your disk space:
MDaemon/Users/ – This is where all of your users’ e-mail is stored. If this folder seems to be consuming a large amount of disk space, drill down two levels to where your individual user folders are and check to see if any of them are consuming a large amount of space.
MDaemon/Backup/ – MDaemon is configured to perform nightly backups of your configuration files and locates these here. Also, whenever you perform an upgrade of MDaemon a copy of your entire App folder along with your SpamAssassin folder is placed in a subfolder of this folder. MDaemon does not ever delete any of your backups so if not deleted by you they will keep accumulating.
MDaemon/Logs/ – MDaemon stores all of your log files in this folder. Depending on your MDaemon settings, it may compress your older logs into a .ZIP file and place that .ZIP file in the OldLogs subfolder of this folder. Again, MDaemon does not delete any of your old logs, so if not deleted by you they will keep accumulating.
MDaemon/Public Folders/ – This is where all of the data from your MDaemon public folders (contacts, calendars, tasks, mail, documents) is stored.
The above folders are the most likely culprits for the space being consumed, but if disk spaced is taken up in other directories, then I recommend using Windows Explorer or one of the previously mentioned utilities to identify the cause of the used disk space.
If it is old log files or old zipped backup files which are consuming your disk space, you can delete them or move them to a different drive or medium. If it is mail or information in the Users folder or Public Folders folder, you will need to find out what users are taking up the space and ask them to remove the mail.
You can move your MDaemon mailboxes to a different drive by following this knowledge base article.
You can move your MDaemon logs to a different drive by following this knowledge base article.
You can turn on old mail pruning (Setup > Domain Manager > Options > Account & Mail Pruning and Setup > Server Settings > Pruning) to have MDaemon remove mail that is older than a certain number of days.
To prevent users from accumulating too much e-mail in their mailboxes, you can activate usage quotas on a per-user basis. When editing a user account, click on Quotas in the left-hand navigation menu. You can set a maximum number of messages stored at once and/or a maximum amount of disk space each user is allowed to use.
Comments or questions? Share them with us in the Comments section below.
MDaemon’s pruning feature allows you to remove old data from the server and free up disk space. You may be familiar with the Public Folder Pruning settings under the Server Settings menu, or the Account & Mail Pruning settings under the Domain Manager, but did you know you can fine-tune your pruning settings using a Command prompt? The command line interface allows you to be very specific about what you want to prune. For example, you can prune (remove) messages that are a specified number of days old (say, 15 days) for a sub-folder of the inbox of a specific account, have those messages moved to a designated public folder, or just have the pruning information logged without actually deleting any data so that you can run this feature in test mode.
In the screenshot shown here, I’ve used the /n command to move messages from every user’s Inbox folder (/p=”Inbox.IMAP”) that are over 5 days old (/d=5) to a zipped archive folder in the Backup directory (\z=”c:\backup\archive”).
For a comprehensive lesson on using Account Pruning, including all of its commands and proper syntax, view the AccountPrune.txt file, located in the MDaemon/App directory. This file explains all of the command parameters & provides examples of each.
Please share your comments if you have any questions.