Hi, all:
When I run mailacountfetch on the project, it always get stuck, because the SLA request the fetchmail to fetch email every minute. In the official tutorial. It should be more stable to get mail with fetchmail+postfix+procmail. I have tried some other ways get emails.
You can find the .fetchmailrc file in the otrs root directory and fill in the host username, password, and others.
Run the fetchmail -a command as a otrs user to receive the mail from helpdesk@domain.com.cn to the /opt/otrs/Maildir/new folder, the file format is .info
Then, we run cat /opt/otrs/Maildir/new/xxxx.info | ./otrs.Console.pl Maint::PostMaster::Read, to push this email to a OTRS ticket.
But I ran into a more difficult problem:
1. How does fetchmail forward mail to otrs' mailbox?
2. How to configure the .fetchmailrc file?
3. How to make it forward automatically?
4. How to configure the .prcmailrc file in conjunction with fetchmail?
Fetchmail+procmail+postfix problem (Solved)
Moderator: crythias
Fetchmail+procmail+postfix problem (Solved)
Last edited by tune6688 on 12 Aug 2021, 05:36, edited 1 time in total.
-
- Administrator
- Posts: 4002
- Joined: 18 Dec 2007, 12:23
- Znuny Version: Znuny and Znuny LTS
- Real Name: Roy Kaldung
- Company: Znuny
- Contact:
Re: Problem for fetchmail+postfix+procmail
Hi,
It's been already describe here: viewtopic.php?f=53&t=42619&p=172597
TLDR;
- Configure your Postfix on the OTRS server to accept e-mails for otrs@FQDN (don't ask what FQDN means) by SMTP. Secure this service.
- Prepare your .procmailrc, usually a copy of .procmailrc.dist is sufficient, checkm permissions afterwards or run otrs.SetPermission.pl.To understand how it works: https://linux.die.net/man/5/procmailrc
- Configure to forward emails for each required e-mail address to otrs@FQDN
If you unsure how to do this or not able ask your Linux server administrator, this is a basic task. Or hire a professional.
- Roy
It's been already describe here: viewtopic.php?f=53&t=42619&p=172597
TLDR;
- Configure your Postfix on the OTRS server to accept e-mails for otrs@FQDN (don't ask what FQDN means) by SMTP. Secure this service.
- Prepare your .procmailrc, usually a copy of .procmailrc.dist is sufficient, checkm permissions afterwards or run otrs.SetPermission.pl.To understand how it works: https://linux.die.net/man/5/procmailrc
- Configure to forward emails for each required e-mail address to otrs@FQDN
If you unsure how to do this or not able ask your Linux server administrator, this is a basic task. Or hire a professional.
- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Fetchmail+procmail+postfix problem (Solved)
Hello, everyone, we found that, using the OTRS AdminMailAccount to get mail and covert to ticket, the mails always stuck and can not get more mails. And many posts in the forum have mentioned this problem but can not fix it.
So we turn to Fetchmail+procmail+postfix, which is said to have 3 times better performance records, but this is difficult for us because there is no technical foundation, but at last, we have made it.
Note: This must be run under centos7. Because the postfix version in centos8 is much higher.
1、 yum –y install postfix fetchmail procmail
2、 Cancel # and modify mailbox_command = /usr/bin/procmail in /etc/postfix/main.cf
3、 Change the mail setting in opt/otrs/.feitchmailrc.
4、 Rename opt/otrs/procmailrc.dist to be. Procmailrc, as descripted in official document.
5、 Change the owner of feitchmailrc and . Procmailrc to be otrs:apache
6、 Change the authorized right of .feitchmailrc and . Procmailrc to be 700
7、 su otrs
8、 cd /opt/otrs and run fechmail –a
And then, you will see the new email in the ticket and find this log in the system management-communication log file.
Thanks again for your help and recorded it for someone who needs it.
So we turn to Fetchmail+procmail+postfix, which is said to have 3 times better performance records, but this is difficult for us because there is no technical foundation, but at last, we have made it.
Note: This must be run under centos7. Because the postfix version in centos8 is much higher.
1、 yum –y install postfix fetchmail procmail
2、 Cancel # and modify mailbox_command = /usr/bin/procmail in /etc/postfix/main.cf
3、 Change the mail setting in opt/otrs/.feitchmailrc.
4、 Rename opt/otrs/procmailrc.dist to be. Procmailrc, as descripted in official document.
5、 Change the owner of feitchmailrc and . Procmailrc to be otrs:apache
6、 Change the authorized right of .feitchmailrc and . Procmailrc to be 700
7、 su otrs
8、 cd /opt/otrs and run fechmail –a
And then, you will see the new email in the ticket and find this log in the system management-communication log file.
Thanks again for your help and recorded it for someone who needs it.