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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sendmail test?

Status
Not open for further replies.

litton1

Technical User
Apr 21, 2005
584
GB
hi all, Ok there is going to be some really no0b questions here so please bare with me. You have been warned lol!
First thing is first. I am not sending or recieving mail (tried pine)I would like to send mail from one user to another (same computer) just to give it a test (been told to try this), my first question is how do I do that. Hope that is not a big question?


Binary Intelligence, true or false?
 
Easiest way is:

# echo "test 1" | mail -s "test message" userid

Requires the "mail" command, which you probably have.

Also, you can use pine. Addressing to a userid only, without any "@domain.com", implies delivery to the local machine.
 
ok i warned you? is userid same as user name? i did one with the username but how do i know if it arrived?

just for updates here is some print out log files

=========================================
mail.info just a few lines::: /varlog/mail.info
Jul 30 08:47:56 asml sendmail[15194]: j6QNQv10009681: to=<email@site.com>, ctladdr=< (30/8), delay=3+08:20:57, xdelay=00:00:00, mailer=relay, pri=14790372, relay=mail.best-answer.com., dsn=4.0.0, stat=Deferred: Connection refused by mail.best-answer.com.

Jul 30 08:47:56 asml sendmail[15194]: j6QNKDV4009395: to=<email@site.com>, ctladdr=< (30/8), delay=3+08:27:41, xdelay=00:00:00, mailer=relay, pri=14880372, relay=mail.best-answer.com., dsn=4.0.0, stat=Deferred: Connection refused by mail.best-answer.com.

Jul 30 08:47:56 asml sendmail[15194]: j6QNCebN009366: to=<email@site.com>, ctladdr=< (30/8), delay=3+08:35:09, xdelay=00:00:00, mailer=relay, pri=14970372, relay=mail.best-answer.com., dsn=4.0.0, stat=Deferred: Connection refused by mail.best-answer.com.
Jul 30 08:57:32 asml imapd[15206]: Logout user=??? host=localhost [127.0.0.1]


mail.warning just a few lines ::
hmm none at this point? this could be because i emptied all logs yesterday

==========================
mail.err just a few lines /var/log/mail.err

Jul 25 22:12:24 asml sendmail-client[3297]: persistent queue runner control process: lost all children: wait returned ECHILD
Jul 27 00:26:30 asml sendmail-client[3300]: persistent queue runner control process: lost all children: wait returned ECHILD
Jul 27 00:33:41 asml sendmail-client[9677]: persistent queue runner control process: lost all children: wait returned ECHILD
Jul 27 00:43:20 asml sendmail-client[9965]: persistent queue runner control process: lost all children: wait returned ECHILD
Jul 27 14:45:36 asml sendmail-client[3278]: persistent queue runner control process: lost all children: wait returned ECHILD

==============================
/var/log/mail just a few lines
Jul 30 08:47:56 asml sendmail[15194]: j6QNKDV4009395: to=<email@site.com>, ctladdr=< (30/8), delay=3+08:27:41, xdelay=00:00:00, mailer=relay, pri=14880372, relay=mail.best-answer.com., dsn=4.0.0, stat=Deferred: Connection refused by mail.best-answer.com.
Jul 30 08:47:56 asml sendmail[15194]: j6QNCebN009366: to=<email@site.com>, ctladdr=< (30/8), delay=3+08:35:09, xdelay=00:00:00, mailer=relay, pri=14970372, relay=mail.best-answer.com., dsn=4.0.0, stat=Deferred: Connection refused by mail.best-answer.com.
Jul 30 08:57:32 asml imapd[15206]: imap service init from 127.0.0.1
Jul 30 08:57:32 asml imapd[15206]: Logout user=??? host=localhost [127.0.0.1]
Jul 30 09:07:32 asml imapd[15243]: imap service init from 127.0.0.1
Jul 30 09:07:32 asml imapd[15243]: Logout user=??? host=localhost [127.0.0.1]

thanks for your reply:)

Binary Intelligence, true or false?
 
First, what's "mail.best-answer.com"? It looks like that's a smart host for relaying outbound messages, or it's the MX host for "site.com". Either way, it's not accepting connections. Try "telnet mail.best-answer.com 25" and see if sendmail is listening.

Remember that sendmail's default is to listen on localhost only. See if there's a directive in sendmail.cf (I don't remember the option at the moment) for the MTA to listen on 127.0.0.1 and remove it if it's there. It's easier if you use m4 and sendmail.mc rather than editing sendmail.cf directly.
 
i have to use the local IP as there is no loopback support

220 asml.best-answer ESMTP Sendmail 8.13.1/8.13.1/SuSE Linux 0.7; Sat, 30 Jul 20
05 18:05:52 +0100

this seems to show that sendmail was listening?


Binary Intelligence, true or false?
 
hi all, by some miracle the server is now excepting emails. if i send an email from yahoo to my root account, it get there no probs but if i try to return the mail it errors. by errors i mean is returned as host unknown. i have tried sending them to myusername@yahoo.co.uk but it just says host unknown? i have included the return mail so you may see
Code:
The original message was received at Sun, 31 Jul 2005 01:06:24 +0100
from localhost [127.0.0.1]
with id j6V06L6w004537

   ----- The following addresses had permanent fatal errors -----
<asmtony@yahoo.co.uk>
    (reason: 550 Host unknown)

   ----- Transcript of session follows -----
550 5.1.2 <asmtony@yahoo.co.uk>... Host unknown (Name server: sendmail: host not found)
unnamed

Return-Path: <root@best-answer.com>
Received: from asml.best-answer (localhost [127.0.0.1])
        by asml.best-answer (8.13.1/8.13.1/SuSE Linux 0.7) with ESMTP id j6V06L6w004537
        for <asmtony@yahoo.co.uk>; Sun, 31 Jul 2005 01:06:24 +0100
Received: from localhost (localhost [[UNIX: localhost]])
        by asml.best-answer (8.13.1/8.13.1/Submit) id j6V06Lp1004536
        for asmtony@yahoo.co.uk; Sun, 31 Jul 2005 01:06:21 +0100
From: root <root@best-answer.com>
Reply-To: admin@best-anser.com
Organization: asm
To: tony mcevoy <asmtony@yahoo.co.uk>
Subject: Re: another test from T
Date: Sun, 31 Jul 2005 01:06:21 +0100
User-Agent: KMail/1.7.1
References: <20050731001012.62880.qmail@web26104.mail.ukl.yahoo.com>
In-Reply-To: <20050731001012.62880.qmail@web26104.mail.ukl.yahoo.com>
MIME-Version: 1.0
Content-Type: text/plain;
  charset="utf-8"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
Message-Id: <200507310106.21330.root@best-answer.com>
any ideas thx in advance T

Binary Intelligence, true or false?
 
I am going to start a new thread as i feel this one has too many log post in and hence not getting any replies

Binary Intelligence, true or false?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top