# Setting up Sendmail

## n0ir

I have been looking the forums over for a solution to this but came up with nothing. I am trying to set up sendmail on my system so it can mail me with system reports and other things. Everytime I try to send mail out from the command line, it never reaches the destination. Here are some logs. What does 'stat=Deferred: Invalid Argument' mean and how can this be fixed? Any ideas?

```

Jul  2 11:02:04 localhost sendmail[7088]: g62G24O5007088: from=root, size=37, class=0, nrcpts=1, msgid=<200207021602.g62G24O5007088@loopback.ou.edu>, relay=root@localhost

Jul  2 11:02:04 localhost sendmail[7089]: g62G24mP007089: from=<root@loopback.ou.edu>, size=305, class=0, nrcpts=1, msgid=<200207021602.g62G24O5007088@loopback.ou.edu>, proto=ESMTP, daemon=MTA, relay=localhost [127.0.0.1]

Jul  2 11:02:04 localhost sendmail[7088]: g62G24O5007088: to=mandarin@ou.edu, ctladdr=root (0/0), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30037, relay=loopback.ou.edu. [127.0.0.1], dsn=2.0.0, stat=Sent (g62G24mP007089 Message accepted for delivery)

Jul  2 11:02:04 localhost sendmail[7091]: g62G24mP007089: to=<mandarin@ou.edu>, ctladdr=<root@loopback.ou.edu> (0/0), delay=00:00:00, xdelay=00:00:00, mailer=esmtp, pri=30305, relay=mailspool.ou.edu. [129.15.2.126], dsn=4.0.0, stat=Deferred: Invalid argument

```

I was trying to mail with this simple command:

```

echo 'blah blah' | mail -s stuff somewhere@ou.edu

```

Anyone know what's up?

----------

## n0ir

Maybe I posted this in the wrong section? Maybe it should be in newbies. Sorry if this is the case..

----------

## rizzo

Meh use postfix.  I run sendmail at home on RedHat and postfix at work on Gentoo and postfix was by FAR more easy to configure and get running.  Sendmail by default won't accept mail from other boxes etc. and has lots of other caveats like that.

----------

## n0ir

 *Quote:*   

> Meh use postfix. I run sendmail at home on RedHat and postfix at work on Gentoo and postfix was by FAR more easy to configure and get running. Sendmail by default won't accept mail from other boxes etc. and has lots of other caveats like that.

 

Awesome. Postfix worked right outta the box. Any configuration suggestions?

----------

