Posted on 2006-05-17
Last Modified: 2007-12-19
My virtual dedicated server is slow to respond when Outlook connects to send new mail.  I think I've tracked it down to the following.   qmail-smptd runs under xinetd with these parameters:

service smtp
        socket_type     = stream
        protocol        = tcp
        wait            = no
        disable         = no
        user            = root
        instances       = UNLIMITED
        server          = /var/qmail/bin/tcp-env
        server_args     = /var/qmail/bin/relaylock /var/qmail/bin/qmail-smtpd /var/qmail/bin/smtp_auth /var/qmail/bin/true /var/qmail/bin/cmd5checkpw /var/qmail/bin/true

tcp-env has these options:
     -r    (Default.)  Attempt to obtain TCPREMOTEINFO  from  the
          remote host.

     -R    Do not attempt to obtain TCPREMOTEINFO from the remote

          Give up on the TCPREMOTEINFO connection  attempt  after
          timeout seconds.  Default: 30.

So, by default I'm getting a 30 second delay.  Is there any value in attempting to obtain TCPREMOTEINFO?  If so, what would be a sensible value to set the timeout to?

Question by:johnalphaone
    LVL 5

    Expert Comment

    in the file

    find the following line:

    then just add -H to one of the arguments

    reboot the server, and everything is much faster now!

    --hope it works :)
    LVL 5

    Expert Comment

    or add following

    server_args = -Rt0 and then service xinetd restart

    Author Comment

    That file does not exist.  qmail-smtpd is being run under tcp-env, not tcpserver.

    Author Comment

    >or add following

    >server_args = -Rt0 and then service xinetd restart

    Yes I know to do that.  But you haven't answered the question;-
    "Is there any value in attempting to obtain TCPREMOTEINFO?  If so, what would be a sensible value to set the timeout to?"
    LVL 5

    Expert Comment

    Try something like "host -d" and tell us how long the query takes. It should be in the last line that says something like "Received 193 bytes from in 173 ms"

    You may still have a problem on that machine that should likely be fixed.

    Author Comment

    For the third time, THIS is the question:-
    "Is there any value in attempting to obtain TCPREMOTEINFO?  If so, what would be a sensible value to set the timeout to?"
    LVL 5

    Expert Comment

    not able to understand your question?

    U mean to say in Qmail-smtp asking TCPREMOTEINFO?
    LVL 23

    Accepted Solution

    TCPREMOTEINFO comes from posting a request with Ident service; which involves connecting back to the user.
    It only works if the user's machine responds to Ident requests on port 113.  Information about the username
    of a user connecting, as well as their host Operating System  may be provided to you.

    The sole value of enabling this capability on any service is for auditing and logging purposes -- to enable you
    to track down e-mail abuse on your network for instance.

    Windows machines will normally not respond to TCPREMOTEINFO; you just have to wait for it to timeout
    before you can connect ---  since most users run windows machines, the information requested over
    Ident to be stored as $TCPREMOTEINFO  is  useless the vast majority of the time.

    The formal value of requesting TCPREMOTEINFO data is purely for logging and auditing purposes; it cannot
    safely be used for access control, because it is possible for a user to provide a fake Ident reply.

    To avoid creating loops, TCPREMOTEINFO  information should  not be requested by servers that run
    on port 113  (Ident).

    It may also cause problems to enable  TCPREMOTEINFO for servers running on  port 53 (SMTP) .

    No timeout is really reasonable if speed is a concern --- the longer you set the timeout value, the more you
    will slow down the service.

    In general, I prefer to use 10 to 15 seconds for the timeout - Yes, Ident requests that would go through
    if a longer wait were allowed sometimes timeout; however, the same can happen with 30 seconds or 90

    Something's definitely amiss or running very slowly, if it takes 15 seconds to get a simple TCPREMOTEINFO
    response, and there's more than a passing chance  the problem lasts longer than 15 more seconds.


    Author Comment


    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Join & Write a Comment

    If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
    Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
    Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
    Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

    728 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

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now