?
Solved

Sendmail running slow on fast box

Posted on 2005-03-18
8
Medium Priority
?
632 Views
Last Modified: 2013-12-17
This is really wierd... i'm building out a new sendmail box to act as another secondary mail server for our network and the box is running great except for some wierd speed issues with sendmail.

The box is not open to the web and routing traffic yet but i have it open to a few IPs that i'm sending test messags from.  The box has a load average of 0.00 since its not doing much and doesn't appear to have much network lag (i'm ssh'ed into it and i can type as fast as normal, no lag there).

Here is the issue though, whenever i telnet to it on port 25, it takes forever (like 15-20 seconds) to come back with the helo prompt.  after that, if i do the mail from: and rcpt to:, after each command it lags up and hangs, and then kicks to the next line.

typing in mailq for a little bit in the CLI caused some wierd lag too but it doesn't appear to be doing that anymore.

When i was setting up sendmail on this box, i stole the config files from another secondary box that should have similiar settings (access,mailertable,relay-domains,local-host-names,sendmail.mc,sendmailcf) and i modified the sendmail.mc file to change all of the names over from the server1 to server2 and did a make -C /etc/mail on it.  it looks like the config is ok, but something is going on.

at first i thought it would be DNS related (it might still be) because the resolv.conf file had a dead server in the first listing.  i changed it and put my primary dns in the first one and time warners dns in the second line. but i'm still seeing lag (i'm a windows junkie so i dont know, but is there an equivalent of ipconfig /flushdns for unix?  or is it even caching?)

thoughts?
0
Comment
Question by:onsite_tech
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
8 Comments
 
LVL 14

Expert Comment

by:kenfcamp
ID: 13578032
to flush your name server try rndc restart (or if that fails) named restart

check your firewalls and their logs, make sure nothing's getting in the way (perhaps the IP of the new server is being flagged)

Try connecting to localhost 25 rather than "somename 25" and see if it connects any faster
0
 
LVL 1

Author Comment

by:onsite_tech
ID: 13578461
ahhh, so resolv.conf is reloaded when i reload bind?  i thought that was just for the server side of DNS but cool.  i did that and it looks like its still a problem.

The firewalls are all happy though i did test it from localhost and the helo header comes up instantly (did it from both localhost and from the FQDN of the box while on that box), but from everyone else it still takes a while.  when i do a mail from: and a mail to: it still takes a while (i wrote a mail from: mail to: data and threw some test stuff in there by hand before it said anything about the mail From: being ok).

the redhat enterprise box itself is not running a firewall, we have a cisco pix in front of it taking care of all of that (i didn't turn the firewall on during the setup process and i haven't touched it since).  part of me wants to keep thinking its a DNS issue (every time i type in an address, it tries to resolve it and times out once or twice before finding it or something)
0
 
LVL 14

Accepted Solution

by:
kenfcamp earned 1600 total points
ID: 13578672
Are you running your own dns?

if so run dig <new_sever_name>
and dig -x <new_server_ip>

I'm assuming you posted the new servers ip in your DNS records.
you may also want to verify your ip settings are correct (gateway, netmask etc), correct listings in your various /etc/hosts files and so on
0
Get proactive database performance tuning online

At Percona’s web store you can order full Percona Database Performance Audit in minutes. Find out the health of your database, and how to improve it. Pay online with a credit card. Improve your database performance now!

 
LVL 1

Author Comment

by:onsite_tech
ID: 13578777
yup, i'm running DNS on this box as a secondary slave server that pulls all of its zone files from a master. its resolv.conf points to the primary ns server and then to timewarner (the T1 ISP).

both of those resolve via dig (the later pulling a ptr from timewarner's name servers).
0
 
LVL 14

Expert Comment

by:kenfcamp
ID: 13582105
just a thought,

You mentioned you used the following config files from a older server.
What version of sendmail was the old server using, what version is the new server using?

Where were these files located on the old server, and where are they on the new server
When you added the copied files to the new server, did you delete existing files?

Assuming you're using a newer version of RH/Sendmail verify submit.cf exists
local-host-names <--- verify the only listings are localhost, and the "new" server name
sendmail.cf <-- make sure there is no DM record for the old server name [DMSERVERNAME.COM]
0
 
LVL 40

Assisted Solution

by:jlevie
jlevie earned 400 total points
ID: 13590774
This sounds like a reverse DNS lookup issue. What happens if you do a reverse lookup on the server's IP and the IP you are trying the telnet test from?

If the system has a secondary name server running you should be using the localhost IP as the first nameserver in resolv.conf.
0
 
LVL 14

Expert Comment

by:kenfcamp
ID: 13591852
jlevie,

I was leaning toward that direction myself what I first read the question, but onsite_tech indicates that he's able to SSH/Telnet into the system just fine except for sendmail connections.

If the issue were reverse DNS related wouldn't it be expected that any connectivity would be lagged, rather than just Sendmail connections?
0
 
LVL 1

Author Comment

by:onsite_tech
ID: 13593806
I found the problem, it was reverse DNS but in a stupid way.  The box was set up with serverA as its hostname, but i went in and hacked it up and changed the hosts file and the network file to give it the outside ServerB.mydomain name.  problem was that sendmail was still using that serverA name it its helo statement (that was my tipoff actually, when i sat down and looked at it) so when i made sure everything was changed to the way i wanted it, i rebooted and the new sendmail helo statement had the right name, and it worked beautifully.

thanks for your help guys.  you rule
0

Featured Post

Percona Live Europe 2017 | Sep 25 - 27, 2017

The Percona Live Open Source Database Conference Europe 2017 is the premier event for the diverse and active European open source database community, as well as businesses that develop and use open source database software.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Local Continuous Replication is a cost effective and quick way of backing up Exchange server data. The following article describes the steps required to configure Local Continuous Replication. Also, the article tells you how to restore from a backup…
As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
Familiarize people with the process of utilizing SQL Server views from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Access…
In this video we show how to create an email address policy in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.:  First we need to log into the Exchange Admin Center. Navigate to the Mail Flow…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question