October 27, 2020

How to configure E-Mail polling (pop3) in OTRS / Znuny?

You want to use OTRS to poll new tickets via POP3 from your mailserver. Why is it recommended to use POP3?
With POP3, OTRS will delete the e-mails once they are properly retrieved as tickets. So you have only E-Mails in the mailbox, which are not processed. The alternative is to use IMAP to retrive e-mails, but this will typcially keep the e-mails still on the server.

Okay now to the tasks you may have in mind:

  • Now you need to configure OTRS for the first time or you want to change the default behaviour?
  • You want to configure the interval of retrieval?
  • You want to configure the host, username and password?
  • You want to define the maximum e-mail size (MB) for retrieving new tickets?

Configure POP3 in OTRS

To get to the SysConfig go to
Admin > Section System Administration > SysConfig
(or use this URL part and append to your OTRS /index.pl?Action=Admin )
Now you can either search for ‘pop3’ and you will find the module ‘Core::PostMaster’

PostMasterReconnectMessage

This configuration defines how many e-mail will be fetched in one mailbox retrieval/connect. The default configuration of OTRS is to fetch E-Mails every 10 minutes. So if this value is too small you will never fetch all e-mails into tickets. So depending on your amount of e-mails you get in the period of 10 minutes, we recommend you to add the factor of 2 or 5 on the mean of the max amounts of e-mails for the retrieval. For example lets assume you have during the day a average of 10 e-mails, but in some circumstances you are getting for e.g. one marketing campaign about 200 e-mails in response in a timeframe of 1 hour. And this repeats in regular way e.g. monthly, or weekly or even daily.
If you would now define to fetch only 20 e-mails (the default of OTRS) in one fetch you would have no issues for the 10 e-mails receiving regularly. But for the case there you are getting 200 e-mails at once, it would take you at least 10 fetches (= 10x 10minutes = 100 minutes + the fetching of the regular e-mails) about 12 fetches (=120 minutes) and thus 2h of time to get all mails as tickets.
So the recommendation in this case would be to:
set your PostMasterReconnectMessage parameter to at least 2x 200 = 400 up to 5x 200 = 1000

PostMasterMaxEmailSize

This configuration defines the maximum E-Mail size (incl. the body and all attachments of the e-mail). The default of OTRS is fairly good with 16MB (16384KB). Due to encodings (Base64) the resulting maximum attachment size will be around 12MB of real payload size.
E.g. we have a max size of 50MB for the payload of e-mails, so we configured OTRS PostMasterMaxEmailSize to be 71680KB. Even in bad base64 encoding cases we ensure that 50MB of payload size will reach the ticket.

PostmasterDefaultQueue

This configuration tell the mail fetching service of OTRS (the Postmaster) in which queue by default the E-Mails shall be added as tickets. Here you can change the default behavior of OTRS where to place your new tickets directly after fetching by default, if you have no queues assigned for the given e-mail address.

Configure the Scheduler / Cron for fetching e-mails

See the article Configure Scheduler / Cron for mail fetching in OTRS

Do you need help with Znuny / OTRS?
We have lot of experiences with OTRS and Znuny and can help you with your issues. Get in touch with us and we will check if and how we can help you.

Leave a Comment

Your email address will not be published. Required fields are marked *

Do you need help with Znuny / OTRS?​

We have lot of experiences with OTRS and Znuny.
We can help you with your issues to solve them.

From giving you support up to implementing integrations to your existing systems.

Get in touch with us and we will check if and how we can help you.​

Get OTRS/Znuny/OTOBO Support
Our support experts prepare themself, by reviewing your business. Please Share your website URL
To get a quick and efficient clearance of your needs, our experts will call you.
We communicate in English.
Maybe we can communicate in your native language too. So please let us know your native written and spoken language.