ScriptInstallation.In Add me to Skype

Home
Services
PHP Script Installation
CGI Script Installation
Linux Tips
FreeBSD Tips
Windows Tips
Server Tips
Scripts Directory
HOW-TO
Contact Us


Sendmail Error - DSN: Data format error

On a FreeBSD server with sendmail mail server, mail from PHP scripts are not going out.

I tested sending mail from SSH prompt and that worked fine.

On checking mail log at /var/log/maillog found following error.

Oct 9 02:45:51 www sendmail[55971]: k992joX1055971: from=www, size=85, class=0, nrcpts=1, msgid=<200610090245.k992joX1055971@www.che-lives.com>, relay=www@localhost
Oct 9 02:45:51 www sendmail[55971]: k992joX1055971: to=myemailid@gmail.com, ctladdr=www (80/80), delay=00:00:01, xdelay=00:00:00, mailer=relay, pri=30085, relay=[127.0.0.1] [127.0.0.1], dsn=5.6.0, stat=Data format error
Oct 9 02:45:51 www sendmail[55971]: k992joX1055971: k992joX2055971: DSN: Data format error
Oct 9 02:45:51 www sendmail[55971]: k992joX2055971: to=www, delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=31109, relay=[127.0.0.1], dsn=5.3.0, stat=User unknown
Oct 9 02:45:51 www sendmail[55971]: k992joX2055971: k992joX3055971: return to sender: User unknown
Oct 9 02:45:51 www sendmail[55971]: k992joX3055971: to=postmaster, delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=32133, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (k992jpJ4055972 Message accepted for delivery)

The problem is fixed by editing php.ini file and adding from email id to sendmail.

sendmail_path = /usr/sbin/sendmail -t -i -f admin@hostedomain.com



Copyright © ScriptInstallation.in