RT4.0.6. not receiving any emails or routing them via rt-mailgate

Hi all,

I’m having problems getting my RT config to work properly since I upgraded
to 4.0.6. (from 3.8.x).

I have successfully upgraded all of the core files and the database and the
webserver is working correctly -all are correct and present.

RT successfully sends emails out, but for some reason the rt-mailgate has
stopped working and any email being sent into the server (any of my
existing queues) produces this error:

Technical details of temporary failure:
The recipient server did not accept our requests to connect. Learn more at

[(21) mail.x http://mail.ussusupport.co.uk/xx.xx.xx. [13x.xxx.xx.xx]:25:
Connection timed out]

My logs don’t seem to track anything coming in, (syslog of RT, apache etc).
Trying to send a queue in from the command line of the RT server produces
this result:

cat /usr/bin/test | /opt/rt4/bin/rt-mailgate --debug --queue
rt-su-activities --url http://xxx.xxx/rt

/opt/rt4/bin/rt-mailgate: temp file is ‘/tmp/WOZb2ZyjA1/8ulux8kHGM’
/opt/rt4/bin/rt-mailgate: connecting to
http://xxx.xxx/rt/REST/1.0/NoAuth/mail-gateway

not ok - Could not load a valid user
/opt/rt4/bin/rt-mailgate: no message passed on STDIN

All was well before the upgrade, but I’m stumped after spending a
considerable amount of time looking at rt-mailgate and NoAuth in apache.

Thanks for taking a look!

Hesan

Anyone able to assist this at all?

Hesan Yousif
IT & Web Manager
University of Sussex Students’ Union

T: 01273 877356
M: 07738 995 035
E: H.D.Yousif@sussex.ac.uk
W: www.sussexstudent.com - www.twitter.com/ussu -
Redirecting...

We’d like to hear what you’ve got to say about the Students’ Union, send us
your comments, suggestions and questions - Students Decide — University of Sussex Students Union
[image: We’re an award-winning Students’ Union - Gold Green Impact, Best
Bar None Gold & Bronze, SUEI Bronze, Investing in Volunteers, NUS
Innovative Student Engagement, Investors in People]

University of Sussex Students’ Union - Company No. 07695765. Charity No.
1147242
University of Sussex Students’ Union Trading Ltd - Company No. 02146582

Anyone able to assist this at all?

Can we see your (sanitized) RT_SiteConfig.pm? How about the relevant
/etc/aliases entries?

Best,
–Glenn

Glenn E. Sieb
System Administrator
+1 201 809-4958

eFashionSolutions
80 Enterprise Avenue South
Secaucus, NJ 07094

Hi Glenn,

Thanks for getting back to me on this question. Of course, they are as
follows:

RT_SiteConfig.pm

This file was generated by running “update-rt-siteconfig-4”.

While local modifications will not be overwritten without permission,

it is recommended the they are instead placed in

/etc/request-tracker4/RT_SiteConfig.d

Note that modifications to the RT_SiteConfig.d directory won’t

take effect until the update command mentioned above is run again.

start /etc/request-tracker4/RT_SiteConfig.d/40-timezone

dynamically find out the current timezone

my $zone = “UTC”;
$zone=/bin/cat /etc/timezone
if -f “/etc/timezone”;
chomp $zone;
Set($Timezone, $zone);

end /etc/request-tracker4/RT_SiteConfig.d/40-timezone

start /etc/request-tracker4/RT_SiteConfig.d/50-debconf

THE BASICS:

Set($rtname, ‘rt.rtsu’);
Set($Organization, ‘rtsu’);

Set($CorrespondAddress , ‘rt@rtsu’);
Set($CommentAddress , ‘rt-comment@rtsu’);
Set($MaxAttachmentSize , 10000000);
Set($FriendlyFromLineFormat, “"%s" <%s>”);

THE WEBSERVER:

Set($WebPath , “/rt”);
Set($WebBaseURL , “http://rtsu”);

end /etc/request-tracker4/RT_SiteConfig.d/50-debconf

start /etc/request-tracker4/RT_SiteConfig.d/51-dbconfig-common

THE DATABASE:

generated by dbconfig-common

map from dbconfig-common database types to their names as known by RT

my %typemap = (
mysql => ‘mysql’,
);

Set($DatabaseType, $typemap{sqlite3} || “UNKNOWN”);

Set($DatabaseHost, ‘localhost’);
Set($DatabasePort, ‘’);

Set($DatabaseUser , ‘’);
Set($DatabasePassword , ‘’);

SQLite needs a special case, since $DatabaseName must be a full pathname

my $dbc_dbname = ‘rtdb’; if ( “sqlite3” eq “sqlite3” ) { Set
($DatabaseName, ‘/var/lib/dbconfig-common/sqlite3/request-tracker4’ . ‘/’ .
$dbc_dbname); } els$

end /etc/request-tracker4/RT_SiteConfig.d/51-dbconfig-common

1;

etc/aliases

See man 5 aliases for format

postmaster: root

rt-su-activities: “|/usr/bin/rt-mailgate --queue rt-su-activities --action
correspond --url http://rtsu/rt
rt-su-activities-comment: “|/usr/bin/rt-mailgate --queue rt-su-activities
–action comment --url http://rtsu/rt

rt-su-advice-centre: “|/usr/bin/rt-mailgate --queue rt-su-advice-centre
–action correspond --url http://rtsu/rt
rt-su-advice-centre-comment: “|/usr/bin/rt-mailgate --queue
rt-su-advice-centre --action comment --url http://rtsu/rt

rt-su-badger: “|/usr/bin/rt-mailgate --queue rt-su-badger --action
correspond --url http://rtsu/rt
rt-su-badger-comment: “|/usr/bin/rt-mailgate --queue rt-su-badger --action
comment --url http://rtsu/rt

rt-su-eastslope-bar: “|/usr/bin/rt-mailgate --queue rt-su-eastslope-bar
–action correspond --url http://rtsu/rt
rt-su-eastslope-bar-comment: “|/usr/bin/rt-mailgate --queue
rt-su-eastslope-bar --action comment --url http://rtsu/rt

rt-su-elected-officers: “|/usr/bin/rt-mailgate --queue
rt-su-elected-officers --action correspond --url http://rtsu/rt
rt-su-elected-officers-comment: “|/usr/bin/rt-mailgate --queue
rt-su-elected-officers --action comment --url http://rtsu/rt

rt-su-falmer-bar: “|/usr/bin/rt-mailgate --queue rt-su-falmer-bar --action
correspond --url http://rtsu/rt
rt-su-falmer-bar-comment: “|/usr/bin/rt-mailgate --queue rt-su-falmer-bar
–action comment --url http://rtsu/rt

rt-su-falmer-shop: “|/usr/bin/rt-mailgate --queue rt-su-falmer-shop
–action correspond --url http://rtsu/rt
rt-su-falmer-shop-comment: “|/usr/bin/rt-mailgate --queue rt-su-falmer-shop
–action comment --url http://rtsu/rt

rt-su-finance: “|/usr/bin/rt-mailgate --queue rt-su-finance --action
correspond --url http://rtsu/rt
rt-su-finance-comment: “|/usr/bin/rt-mailgate --queue rt-su-finance
–action comment --url http://rtsu/rt

rt-su-marketing: “|/usr/bin/rt-mailgate --queue rt-su-marketing --action
correspond --url http://rtsu/rt
rt-su-marketing-comment: “|/usr/bin/rt-mailgate --queue rt-su-marketing
–action comment --url http://rtsu/rt

rt-su-office-manager: “|/usr/bin/rt-mailgate --queue rt-su-office-manager
–action correspond --url http://rtsu/rt
rt-su-office-manager-comment: “|/usr/bin/rt-mailgate --queue
rt-su-office-manager --action comment --url http://rtsu/rt

rt-su-pulse: “|/usr/bin/rt-mailgate --queue rt-su-pulse --action correspond
–url http://rtsu/rt
rt-su-pulse-comment: “|/usr/bin/rt-mailgate --queue rt-su-pulse --action
comment --url http://rtsu/rt

rt-su-senior-managers: “|/usr/bin/rt-mailgate --queue rt-su-senior-managers
–action correspond --url http://rtsu/rt
rt-su-senior-managers-comment: “|/usr/bin/rt-mailgate --queue
rt-su-senior-managers --action comment --url http://rtsu/rt

rt-su-union-computers: “|/usr/bin/rt-mailgate --queue rt-su-union-computers
–action correspond --url http://rtsu/rt
rt-su-union-computers-comment: “|/usr/bin/rt-mailgate --queue
rt-su-union-computers --action comment --url http://rtsu/rt

rt-su-web: “|/usr/bin/rt-mailgate --queue rt-su-web --action correspond
–url http://rtsu/rt
rt-su-web-comment: “|/usr/bin/rt-mailgate --queue rt-su-web --action
comment --url http://rtsu/rt

rt-su-yorkstore-shop: “|/usr/bin/rt-mailgate --queue rt-su-yorkstore-shop
–action correspond --url http://rtsu/rt
rt-su-yorkstore-shop-comment: “|/usr/bin/rt-mailgate --queue
rt-su-yorkstore-shop --action comment --url http://rtsu/rt

rt-su-laptops: “|/usr/bin/rt-mailgate --queue rt-su-laptops --action
correspond --url http://rtsu/rt
rt-su-laptops-comment: “|/usr/bin/rt-mailgate --queue rt-su-laptops
–action comment --url http://rtsu/rt

rt-su-boxoffice: “|/usr/bin/rt-mailgate --queue rt-su-boxoffice --action
correspond --url http://rtsu/rt
rt-su-boxoffice-comment: “|/usr/bin/rt-mailgate --queue rt-su-boxoffice
–action comment --url http://rtsu/rt

rt-su-lettings: “|/usr/bin/rt-mailgate --queue rt-su-lettings --action
correspond --url http://rtsu/rt
rt-su-lettings-comment: “|/usr/bin/rt-mailgate --queue rt-su-lettings
–action comment --url http://rtsu/rt

I’ve got a feeling that the database settings doesn’t look right in
RT_SiteConfig.pm -but if the database was incorrect, surely my web
front-end wouldn’t function -but it does!

Thanks for the input.

HesanOn 23 July 2012 20:38, Glenn E. Sieb gsieb@efashionsolutions.com wrote:

On 07/23/2012 03:24 PM, Hesan Yousif wrote:

Anyone able to assist this at all?

Can we see your (sanitized) RT_SiteConfig.pm? How about the relevant
/etc/aliases entries?

Best,
–Glenn


Glenn E. Sieb
System Administrator
+1 201 809-4958

eFashionSolutions
80 Enterprise Avenue South
Secaucus, NJ 07094

Hesan Yousif
IT & Web Manager
University of Sussex Students’ Union

T: 01273 877356
M: 07738 995 035
E: H.D.Yousif@sussex.ac.uk
W: www.sussexstudent.com - www.twitter.com/ussu -
USSU - University of Sussex Students' Union | Brighton and Hove

We’d like to hear what you’ve got to say about the Students’ Union, send us
your comments, suggestions and questions - Students Decide — University of Sussex Students' Union

University of Sussex Students’ Union - Company No. 07695765. Charity No.
1147242
University of Sussex Students’ Union Trading Ltd - Company No. 02146582

Hesan Yousif
IT & Web Manager
University of Sussex Students’ Union

T: 01273 877356
M: 07738 995 035
E: H.D.Yousif@sussex.ac.uk
W: www.sussexstudent.com - www.twitter.com/ussu -
USSU - University of Sussex Students' Union | Brighton and Hove

We’d like to hear what you’ve got to say about the Students’ Union, send us
your comments, suggestions and questions - Students Decide — University of Sussex Students' Union
[image: We’re an award-winning Students’ Union - Gold Green Impact, Best
Bar None Gold & Bronze, SUEI Bronze, Investing in Volunteers, NUS
Innovative Student Engagement, Investors in People]

University of Sussex Students’ Union - Company No. 07695765. Charity No.
1147242
University of Sussex Students’ Union Trading Ltd - Company No. 02146582

Technical details of temporary failure:
The recipient server did not accept our requests to connect. Learn more
at Fix bounced or rejected emails - Gmail Help
[(21) mail.xxx.xx.xx.
[13x.xxx.xx.xx]:25: Connection timed out]

Your error is right there: “Connection timed out”. Google’s mail
servers couldn’t connect to your MX on port 25. That’s not an RT problem.

My logs don’t seem to track anything coming in, (syslog of RT, apache
etc). Trying to send a queue in from the command line of the RT server
produces this result:

cat /usr/bin/test | /opt/rt4/bin/rt-mailgate --debug --queue
rt-su-activities --url http://xxx.xxx/rt
/opt/rt4/bin/rt-mailgate: temp file is ‘/tmp/WOZb2ZyjA1/8ulux8kHGM’
/opt/rt4/bin/rt-mailgate: connecting to
http://xxx.xxx/rt/REST/1.0/NoAuth/mail-gateway
not ok - Could not load a valid user
/opt/rt4/bin/rt-mailgate: no message passed on STDIN

Er, you’re passing a binary (/usr/bin/test) into rt-mailgate. What do
you expect to happen?

“No message passed on STDIN” is correct… you didn’t pass a valid
email, just garbage.

Technical details of temporary failure:
The recipient server did not accept our requests to connect. Learn more
at Fix bounced or rejected emails - Gmail Help
[(21) mail.xxx.xx.xx.
[13x.xxx.xx.xx]:25: Connection timed out]

Your error is right there: “Connection timed out”. Google’s mail
servers couldn’t connect to your MX on port 25. That’s not an RT problem.

My logs don’t seem to track anything coming in, (syslog of RT, apache
etc). Trying to send a queue in from the command line of the RT server
produces this result:

cat /usr/bin/test | /opt/rt4/bin/rt-mailgate --debug --queue
rt-su-activities --url http://xxx.xxx/rt
/opt/rt4/bin/rt-mailgate: temp file is ‘/tmp/WOZb2ZyjA1/8ulux8kHGM’
/opt/rt4/bin/rt-mailgate: connecting to
http://xxx.xxx/rt/REST/1.0/NoAuth/mail-gateway
not ok - Could not load a valid user
/opt/rt4/bin/rt-mailgate: no message passed on STDIN

Er, you’re passing a binary (/usr/bin/test) into rt-mailgate. What do
you expect to happen?

“No message passed on STDIN” is correct… you didn’t pass a valid
email, just garbage.

Dude, no need to be harsh! I was trying to set a test into rt-mailgate -if
that was incorrect then apologies. Point is any mail sent into RT is not
being routed into a queue and mail is receiving a timed out mail delivery
failure.

Are you able to assist in a constructive manner please?

Hesan

Thomas,

Just saw your comment above, thanks for the input. Ill look at the MX
records.

HesanOn 24/07/2012 00:39, Thomas Sibley wrote:

On 07/22/2012 05:47 AM, Hesan Yousif wrote:

Technical details of temporary failure:
The recipient server did not accept our requests to connect. Learn more
at Fix bounced or rejected emails - Gmail Help
[(21) mail.xxx.xx.xx.
[13x.xxx.xx.xx]:25: Connection timed out]
Your error is right there: “Connection timed out”. Google’s mail
servers couldn’t connect to your MX on port 25. That’s not an RT problem.

My logs don’t seem to track anything coming in, (syslog of RT, apache
etc). Trying to send a queue in from the command line of the RT server
produces this result:

cat /usr/bin/test | /opt/rt4/bin/rt-mailgate --debug --queue
rt-su-activities --url http://xxx.xxx/rt
/opt/rt4/bin/rt-mailgate: temp file is ‘/tmp/WOZb2ZyjA1/8ulux8kHGM’
/opt/rt4/bin/rt-mailgate: connecting to
http://xxx.xxx/rt/REST/1.0/NoAuth/mail-gateway
not ok - Could not load a valid user
/opt/rt4/bin/rt-mailgate: no message passed on STDIN
Er, you’re passing a binary (/usr/bin/test) into rt-mailgate. What do
you expect to happen?

“No message passed on STDIN” is correct… you didn’t pass a valid
email, just garbage.

Hesan Yousif
IT & Web Manager
University of Sussex Students’ Union

T: 01273 877356
M: 07738 995 035
E: H.D.Yousif@sussex.ac.uk mailto:H.D.Yousif@sussex.ac.uk
W: www.sussexstudent.com http://www.sussexstudent.com -
www.twitter.com/ussu http://www.twitter.com/ussu -
USSU - University of Sussex Students' Union | Brighton and Hove http://www.facebook.com/thestudentsunion

We’d like to hear what you’ve got to say about the Students’ Union, send
us your comments, suggestions and questions -
Students Decide — University of Sussex Students' Union http://www.sussexstudent.com/feedback

We’re an award-winning Students’ Union - Gold Green Impact, Best Bar
None Gold & Bronze, SUEI Bronze, Investing in Volunteers, NUS Innovative
Student Engagement, Investors in People

University of Sussex Students’ Union - Company No. 07695765. Charity No.
1147242
University of Sussex Students’ Union Trading Ltd - Company No. 02146582