Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Messages w/ Attachments Intermittent!

Status
Not open for further replies.

MickUK

IS-IT--Management
Dec 17, 2008
2
0
0
GB
Hi guys,

I've searched and searched and just can't figure this one out, it's driving me nuts!

To give you a general overview our sendmail box is relaying some messages to our host (mail.financial.ltd.uk) with attachments but not others. Size of the file doesn't seem to matter, some small ones get stuck, other larger ones are OK.

here is a snapshot sendmail working on a 2MB zero filled example from my thunderbird client:

Running /var/spool/mqueue/mBHGrvXh015456 (sequence 1 of 1)
<mickwalton@gmail.com>... Connecting to mail.financial.ltd.uk. via relay...
220 ESMTP Exim Wed, 17 Dec 2008 16:57:43 +0000
>>> EHLO financial.ltd.uk
250-mail18.extendcp.co.uk Hello host217-41-0-101.in-addr.btopenworld.com [217.41.0.101]
250-SIZE 52428800
250-PIPELINING
250-AUTH PLAIN LOGIN CRAM-MD5
250 HELP
>>> AUTH LOGIN
334 VXNlcm5hbWU6
>>> YWxsQGZpbmFuY2lhbC5sdGQudWs=
334 UGFzc3dvcmQ6
>>> aHVudHplcm8=
235 Authentication succeeded
>>> MAIL From:<michael@financial.ltd.uk> SIZE=2842964
250 OK
>>> RCPT To:<mickwalton@gmail.com>
>>> DATA
250 Accepted
354 Enter message, ending with "." on a line by itself
>>> .
250 OK id=1LCziR-0003jU-Vf
<mickwalton@gmail.com>... Sent (OK id=1LCziR-0003jU-Vf)
Closing connection to mail.financial.ltd.uk.
>>> QUIT
221 mail18.extendcp.co.uk closing connection

here is another test message with binary attachment that fails from the same client:

Running /var/spool/mqueue/mBHGfRjA013240 (sequence 1 of 1)
<mickwalton@gmail.com>... Connecting to mail.financial.ltd.uk. via relay...
220 ESMTP Exim Wed, 17 Dec 2008 17:07:07 +0000
>>> EHLO financial.ltd.uk
250-mail18.extendcp.co.uk Hello host217-41-0-101.in-addr.btopenworld.com [217.41.0.101]
250-SIZE 52428800
250-PIPELINING
250-AUTH PLAIN LOGIN CRAM-MD5
250 HELP
>>> AUTH LOGIN
334 VXNlcm5hbWU6
>>> YWxsQGZpbmFuY2lhbC5sdGQudWs=
334 UGFzc3dvcmQ6
>>> aHVudHplcm8=
235 Authentication succeeded
>>> MAIL From:<michael@financial.ltd.uk> SIZE=2179061
250 OK
>>> RCPT To:<mickwalton@gmail.com>
>>> DATA
250 Accepted
354 Enter message, ending with "." on a line by itself


timeout writing message to mail.financial.ltd.uk.: Connection timed out with mail.financial.ltd.uk.
<mickwalton@gmail.com>... Deferred
Closing connection to mail.financial.ltd.uk.



At first I though this was an client issue to do with encoding but after much testing I can't find a pattern here. I have tried all sorts of file types with no obvious pattern occuring.

I also discovered that some users have similar symptons with their MTU being set too high. I have changed my MTU using sysctl as follows:

net.ipv4.tcp_low_latency = 0
net.ipv4.tcp_frto = 0
net.ipv4.tcp_tw_reuse = 0
net.ipv4.icmp_ratemask = 6168
net.ipv4.icmp_ratelimit = 100
net.ipv4.tcp_adv_win_scale = 2
net.ipv4.tcp_app_win = 31
net.ipv4.tcp_rmem = 4096 87380 174760
net.ipv4.tcp_wmem = 4096 87380 174760
net.ipv4.tcp_mem = 4096 87380 174760
net.ipv4.tcp_dsack = 1
net.ipv4.tcp_ecn = 0
net.ipv4.tcp_reordering = 3
net.ipv4.tcp_fack = 1
net.ipv4.tcp_orphan_retries = 0
net.ipv4.inet_peer_gc_maxtime = 120
net.ipv4.inet_peer_gc_mintime = 10
net.ipv4.inet_peer_maxttl = 600
net.ipv4.inet_peer_minttl = 120
net.ipv4.inet_peer_threshold = 65664
net.ipv4.igmp_max_msf = 10
net.ipv4.igmp_max_memberships = 20
net.ipv4.route.secret_interval = 600
net.ipv4.route.min_adv_mss = 256
net.ipv4.route.min_pmtu = 552
net.ipv4.route.mtu_expires = 600
net.ipv4.route.gc_elasticity = 8
net.ipv4.route.error_burst = 500
net.ipv4.route.error_cost = 100
net.ipv4.route.redirect_silence = 2048
net.ipv4.route.redirect_number = 9
net.ipv4.route.redirect_load = 2
net.ipv4.route.gc_interval = 60
net.ipv4.route.gc_timeout = 300
net.ipv4.route.gc_min_interval = 0
net.ipv4.route.max_size = 131072
net.ipv4.route.gc_thresh = 8192
net.ipv4.route.max_delay = 10
net.ipv4.route.min_delay = 2
error: "Invalid argument" reading key "net.ipv4.route.flush"
net.ipv4.icmp_ignore_bogus_error_responses = 0
net.ipv4.icmp_echo_ignore_broadcasts = 0
net.ipv4.icmp_echo_ignore_all = 0
net.ipv4.ip_local_port_range = 32768 61000
net.ipv4.tcp_max_syn_backlog = 1024
net.ipv4.tcp_rfc1337 = 0
net.ipv4.tcp_stdurg = 0
net.ipv4.tcp_abort_on_overflow = 0
net.ipv4.tcp_tw_recycle = 0
net.ipv4.tcp_fin_timeout = 60
net.ipv4.tcp_retries2 = 15
net.ipv4.tcp_retries1 = 3
net.ipv4.tcp_keepalive_intvl = 75
net.ipv4.tcp_keepalive_probes = 9
net.ipv4.tcp_keepalive_time = 7200
net.ipv4.ipfrag_time = 30
net.ipv4.ip_dynaddr = 1
net.ipv4.ipfrag_low_thresh = 196608
net.ipv4.ipfrag_high_thresh = 262144
net.ipv4.tcp_max_tw_buckets = 180000
net.ipv4.tcp_max_orphans = 16384
net.ipv4.tcp_synack_retries = 5
net.ipv4.tcp_syn_retries = 5
net.ipv4.ip_nonlocal_bind = 0
net.ipv4.ip_no_pmtu_disc = 1
net.ipv4.ip_autoconfig = 0
net.ipv4.ip_default_ttl = 64
net.ipv4.ip_forward = 1
net.ipv4.tcp_retrans_collapse = 1
net.ipv4.tcp_sack = 1
net.ipv4.tcp_window_scaling = 1
net.ipv4.tcp_timestamps = 1
net.core.somaxconn = 256
net.core.hot_list_length = 128
net.core.optmem_max = 10240
net.core.message_burst = 50
net.core.message_cost = 5
net.core.mod_cong = 290
net.core.lo_cong = 100
net.core.no_cong = 20
net.core.no_cong_thresh = 10
net.core.netdev_max_backlog = 300
net.core.dev_weight = 64
net.core.rmem_default = 65535
net.core.wmem_default = 65535
net.core.rmem_max = 65535
net.core.wmem_max = 65535

Which didn't have any effect...

Anyone come across this problem before or could possibly point me in the right direction?

here is the output from sendmail with my basic setup info:

Version 8.13.0
Compiled with: DNSMAP LOG MATCHGECOS MILTER MIME7TO8 MIME8TO7
NAMED_BIND NETINET NETUNIX NEWDB PIPELINING SASLv2 SCANF
STARTTLS USERDB XDEBUG
OS Defines: HASFCHOWN HASFCHMOD HASGETDTABLESIZE HASINITGROUPS
HASLSTAT HASNICE HASRANDOM HASRRESVPORT HASSETREGID HASSETREUID
HASSETRLIMIT HASSETSID HASSETVBUF HASURANDOMDEV HASSTRERROR
HASUNAME HASUNSETENV HASWAITPID IDENTPROTO REQUIRES_DIR_FSYNC
USE_DOUBLE_FORK USE_SIGLONGJMP
Kernel symbols: /boot/vmlinux
Conf file: /etc/mail/submit.cf (default for MSP)
Conf file: /etc/mail/sendmail.cf (default for MTA)
Pid file: /var/run/sendmail.pid (default)
Canonical name: z1gemfin.financialltd.lan
UUCP nodename: z1gemfin
a.k.a.: z1gemfin
a.k.a.: [192.168.43.1]
Conf file: /etc/mail/submit.cf (selected)
Pid file: /var/spool/clientmqueue/sm-client.pid (selected)

============ SYSTEM IDENTITY (after readcf) ============
(short domain name) $w = z1gemfin
(canonical domain name) $j = z1gemfin.financialltd.lan
(subdomain name) $m = financialltd.lan
(node name) $k = z1gemfin
========================================================

Sorry to be a pain, I didn't set this box up and it seems 'over-configured' to me compared to my normal sendmail setup but hey..

If you need any other debugging info or logs I'd be glad to post it and very grateful for any advice from the sendmail gods!

thanks in advance!
 
ADDITIONAL:

This appears to be a networking issue as we tried directly delivering the mail (no relay) which made no difference.

We also tried sending mail directly to a different SMTP server bypassing ours and had the same issue.

I'm assuming this is to do with MTU or similar? Wondering why this issue hadn't reared it's head earlier though?

any ideas?
 
Have you found a solution to this problem? I'm having very similar problems in my workplace. The closest thing I can narrow it down to, is that only certain types of attachments are blocked, and not every attachment of that type. It seems that some html formatted auto-generated reports from one of our servers are being consistently deferred, and other messages with Word 2007 attachments. If the users sending the Word documents save to another format, they will relay without any problems.

I'm running sendmail 8.13.8 on Red Hat EL 5.

Chris
 
is it possible that disk space or quota is an issue?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top