I have a web server that I set up to send all notifications that may be of use to debug/investigate server issues to my outlook.com account. I use this account as a backup in the case I lose access to the server completely, so I at least have some information that I can use to find out what the issue was and how to solve it.

I set up some rules to automatically sort messages into folders. The folder structure boils down to:

│ ├─cxs
│ ├─Excessive Usage
│ ├─Modified Files
│ ├─Service Monitoring
│ └─...
│ ├─ChkRoot
│ ├─RKHunter
│ └─Maldet
├─Cron Errors

This is a simplified view because it illustrates the problem well enough and I can't be bothered to type out the whole structure.

Some information that may be useful to know:

  1. All emails are sent from root@<servername>
  2. All emails are sent to either root@<servername> OR a generic log email address that's setup with forwarders. Mail to root also gets forwarded here.

The rules are executed in this order:

  1. Move all messages from root@<servername> to Server
  2. Move all messages of which the subject line contains LFD on <servername> to Server/LFD AND stop processing rules
  3. Move all messages of which the subject line contains CXS scan on <servername> to Server/LFD/cxs AND stop processing rules
  4. (repeat rule 3 for all other LFD subfolders
  5. Move all messages of which the subject line contains ChkRoot on <servername> to Scanners/ChkRoot
  6. (repeat rule 5 for all other scanners)
  7. Move all messages of which the subject line contains Anacron job on <servername> to Cron Errors

This used to work perfectly, where all notifications were first moved to the Server folder and then sorted into their specific folders. I set it up this way so that all notifications, even those for which I didn't set up specific rules, would at least be moved to the Server folder.

Unfortunately, a few weeks ago, the rules started showing some strange behaviors. I didn't modify the rules at all before this happened.

Now, when I receive some notifications (so far I've noticed it for all scanners, as well as those that should be moved to LFD), they are first moved to the Server folder, and then copied to their specific folder. This leaves me with all those notifications appearing in two folders. This is especially annoying because I usually check the Server folder to see if there's any messages that need their own folder and rule.

I have created a screenshot of the generic and specific rules:

Generic rule (applied to all messages) image

Specific rule (applied after generic rule) image

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.