LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-12-2005, 04:09 PM   #1
puremourning
LQ Newbie
 
Registered: Jan 2005
Posts: 23

Rep: Reputation: 15
sendmail and php


could someone give me some pointers as to how to set up my (desktop) box which i use as a test webserver so that php mail() will work from sendmail.

i have set up sendmail to route to my isp smtp server with

Code:
define(`SMART_HOST',`smtp.ntlworld.com')
and i can send from the command line. php mail() however doesnt ever arrive. mail log looks like this for the cmdline:

Code:
May 12 21:42:22 cpc1-with2-6-0-cust34 sendmail[14816]: j4CKg4px014816: from=root, size=76, class=0, nrcpts=1, msgid=<200505122042.j4CKg4px014816@cpc1-with2-6-0-cust34.bagu.cable.ntl.com>, relay=root@localhost
May 12 21:42:22 cpc1-with2-6-0-cust34 sendmail[14817]: j4CKgMBp014817: from=<root@cpc1-with2-6-0-cust34.bagu.cable.ntl.com>, size=350, class=0, nrcpts=1, msgid=<200505122042.j4CKg4px014816@cpc1-with2-6-0-cust34.bagu.cable.ntl.com>, proto=ESMTP, daemon=MTA, relay=localhost.localdomain [127.0.0.1]
May 12 21:42:22 cpc1-with2-6-0-cust34 sendmail[14816]: j4CKg4px014816: to=benj@puremourning.co.uk, ctladdr=root (0/0), delay=00:00:18, xdelay=00:00:00, mailer=relay, pri=30076, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (j4CKgMBp014817 Message accepted for delivery)
May 12 21:42:26 cpc1-with2-6-0-cust34 sendmail[14819]: j4CKgMBp014817: to=<benj@puremourning.co.uk>, ctladdr=<root@cpc1-with2-6-0-cust34.bagu.cable.ntl.com> (0/0), delay=00:00:04, xdelay=00:00:04, mailer=relay, pri=120350, relay=smtp.ntlworld.com. [212.250.162.8], dsn=2.0.0, stat=Sent (Message received: 20050512204045.HCPK24880.aamta01-win....cable.ntl.com)
but the one from php (apache) just says:

Code:
May 12 21:48:17 cpc1-with2-6-0-cust34 sendmail[14837]: j4CKmHSc014837: from=apache, size=292, class=0, nrcpts=0, msgid=<200505122048.j4CKmHSc014837@cpc1-with2-6-0-cust34.bagu.cable.ntl.com>, relay=apache@localhost
i assume i need to give apache priviledges to send mail?
 
Old 05-12-2005, 05:06 PM   #2
puremourning
LQ Newbie
 
Registered: Jan 2005
Posts: 23

Original Poster
Rep: Reputation: 15
nevermind, i sorted it. For reference:

add "apache" to /etc/mail/trusted-users
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
php+ sendmail no good - python + sendmail ok nephish Linux - Networking 1 10-07-2005 01:19 PM
php and sendmail akamaru607 Linux - Newbie 1 08-25-2005 12:51 PM
php sendmail... HELP! Doug86 Linux - Newbie 3 07-29-2005 09:09 AM
PHP/Sendmail Help dailyuser Programming 0 08-31-2004 10:35 AM
Sendmail and PHP Aldyn Linux - Newbie 0 06-02-2003 10:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:48 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration