<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://rt-wiki.bestpractical.com/index.php?action=history&amp;feed=atom&amp;title=SendmailTips</id>
	<title>SendmailTips - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://rt-wiki.bestpractical.com/index.php?action=history&amp;feed=atom&amp;title=SendmailTips"/>
	<link rel="alternate" type="text/html" href="https://rt-wiki.bestpractical.com/index.php?title=SendmailTips&amp;action=history"/>
	<updated>2026-08-21T21:55:14Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.1</generator>
	<entry>
		<id>https://rt-wiki.bestpractical.com/index.php?title=SendmailTips&amp;diff=3490&amp;oldid=prev</id>
		<title>Admin: 2 revisions imported</title>
		<link rel="alternate" type="text/html" href="https://rt-wiki.bestpractical.com/index.php?title=SendmailTips&amp;diff=3490&amp;oldid=prev"/>
		<updated>2016-04-06T20:37:40Z</updated>

		<summary type="html">&lt;p&gt;2 revisions imported&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== RT performance and sendmail config ==&lt;br /&gt;
&lt;br /&gt;
When RT needs to send an email message (notification, autoreply or error to RT owner) it runs the sendmail command, pipes the output to the program, and &amp;#039;&amp;#039;&amp;#039;waits for the sendmail process to exit&amp;#039;&amp;#039;&amp;#039;. This means that RT might delay on any actions that send emails (create ticket, comment or correspond...). The sendmail &amp;#039;&amp;#039;&amp;#039;Delivery Mode&amp;#039;&amp;#039;&amp;#039; option allows you to change this behaviour. This option has four values: i(nteractive), b(ackground), q(ueue), d(efer). The last two modes don&amp;#039;t send emails immediately, but put them in the sendmail queue, returning control to RT. You also need to configure how often the sendmail daemon scans the queue, this would define maximum time mails stay in the queue before processing. Ok, lets write it down to config files:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;# RT_SiteConfig.pm, *don&amp;#039;t forget* to copy defaults from RT_Config.pm&lt;br /&gt;
 Set( $SendmailArguments, &amp;quot;-ODeliveryMode=q ...other options...&amp;quot; );&lt;br /&gt;
 &lt;br /&gt;
 # sendmail daemon options, for example in gentoo located in /etc/conf.d/sendmail&lt;br /&gt;
 SENDMAIL_OPTS=&amp;quot;-q1m ...other options...&amp;quot; # value could be -q3m, -q30s or even -q1h23m9s&lt;br /&gt;
 &lt;br /&gt;
 &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
See also &amp;lt;code&amp;gt;man sendmail&amp;lt;/code&amp;gt;, options &amp;lt;code&amp;gt;-O*&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;-q*&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Configuring sendmail on !RedHat and Fedora ==&lt;br /&gt;
&lt;br /&gt;
This was done on RedHat 9 but should apply to previous versions as well as Fedora.&lt;br /&gt;
&lt;br /&gt;
By default Sendmail will not accept mail from outside of localhost so there are a number of things you need to change before it will deliver mail to RT.&lt;br /&gt;
&lt;br /&gt;
1) First You need to uncomment the local loopback line to look as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;# vi /etc/mail/sendmail.mc&lt;br /&gt;
 dnl DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA&amp;#039;)&lt;br /&gt;
 &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To finalize your changes run:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;# m4 /etc/mail/sendmail.mc &amp;amp;gt; /etc/mail/sendmail.cf&lt;br /&gt;
 &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
2) You also need to add your mail server to the access list to be able to relay mail to your rt server:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;# vi /etc/mail/access&lt;br /&gt;
 1.2.3.4	      RELAY&lt;br /&gt;
 &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You then need to rewrite the access DB:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;# makemap hash /etc/mail/access.db &amp;amp;lt; /etc/mail/access&lt;br /&gt;
 &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
3) Now add an entry for the rt server alias:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;# vi /etc/mail/local-host-names&lt;br /&gt;
 rt.mydomain.com&lt;br /&gt;
 &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
4) If smrsh is used (it is by default usually)&lt;br /&gt;
&lt;br /&gt;
 ln -s /opt/rt3/bin/rt-mailgate /etc/smrsh/rt-mailgate&lt;br /&gt;
&lt;br /&gt;
5) Finally restart Sendmail&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;nowiki&amp;gt;# service sendmail restart&lt;br /&gt;
 &amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
For a management-free method of adding new queues without having to touch sendmail&amp;#039;s configuration, look at [[SendmailWithoutQueueAliases]].&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>