1

I have set-up sendmail on my Ubuntu server but it takes ages to send an email. It doesn't actually sent the email but it takes about 20 seconds.

Try it here: http://genyx.co.uk/form/index.php

You can tell if its sent because it says yay or nay at the top. You don't have to enter any information, just click submit.

I installed sendmail with the default configuration.

Can anyone help?

11
  • did you ever change your hostname after installing?
    – Mike
    Commented Mar 6, 2012 at 14:18
  • after installing sendmail or ubuntu?
    – Adam
    Commented Mar 6, 2012 at 14:31
  • I think @Mike is trying to ascertain whether your server has its hostname set properly. Sendmail will attempt to figure out the hostname of the server before sending mail and this may be taking time if it doesn't resolve correctly. It is also worth checking your DNS setup to make sure DNS queries are happening quickly. You also could do with posting some Sendmail log output for when you're sending a message (you may need to up the log level in the config file). If you're now using postfix, we still need log output to help. We're not psychic (well...I'm not).
    – webtoe
    Commented Mar 6, 2012 at 15:27
  • Hi, where are the logs located?
    – Adam
    Commented Mar 6, 2012 at 15:50
  • /var/log/mail.log
    – adamo
    Commented Mar 6, 2012 at 16:07

2 Answers 2

1

According to the log files that you posted the delay problem is this:

Mar 6 13:50:36 GenyxPrimary sendmail[8384]: My unqualified host name (GenyxPrimary) unknown; sleeping for retry

Edit /etc/mail/sendmail.mc and add at the bottom the following two lines:

LOCAL_CONFIG
Djgenyx.co.uk

Next see this answer in order to make sure that mail gets delivered properly to where it has to. Do not forget to run sudo sendmailconfig after completing editing sendmail.mc.

Right now it seems that mail gets accepted by your email provider:

Mar 6 13:55:51 GenyxPrimary sm-mta[9354]: q26DtnqT009352: to=, ctladdr= (33/33), delay=00:00:02, xdelay=00:00:02, mailer=esmtp, pri=120377, relay=mx1.emailsrvr.com. [98.129.184.131], dsn=2.0.0, stat=Sent (Ok: queued as 7A/C9-03931-657165F4)

so you have to check whether it is tagged or rejected as spam.

2
  • Thanks for the help! I still have no idea what I just did but it worked :)
    – Adam
    Commented Mar 6, 2012 at 18:14
  • Whenever you feel like diving into sendmail, grab the bat book
    – adamo
    Commented Mar 6, 2012 at 19:11
0

Let's call sendmail a command line tool and Sendmail MTA as big sendmail

I guess you have installed big sendmail (that also provides sendmail). It's the most ancient MTA. But probably it can be used for your need if you configure it properly. But I would recommend install postfix or ssmtp (both provides sendmail).

2
  • I installed postfix, but now it says "yay" as if its sent, but I don't receive any mail
    – Adam
    Commented Mar 6, 2012 at 15:17
  • check for postifx log (/var/log/maillog on my machine) Commented Mar 14, 2012 at 14:30

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .