Current time: 12-24-2024, 11:57 PM Hello There, Guest! (LoginRegister)


Post Reply 
mail from www-data?
Author Message
achioo Offline
Junior Member
*

Posts: 76
Joined: Nov 2006
Reputation: 0
Post: #1
mail from www-data?
Ok I've tried adding php_admin_value sendmail_from user@domain.com but all email from php is still being sent as www-data@nonexistent.local any thoughts?
11-05-2007 02:22 PM
Find all posts by this user Quote this message in a reply
achioo Offline
Junior Member
*

Posts: 76
Joined: Nov 2006
Reputation: 0
Post: #2
RE: mail from www-data?
I've also tried editing the sendmail_path -f parameter to no avail. phpinfo() lists the path as /usr/sbin/sendmail -t -i... any thoughts?
11-05-2007 02:34 PM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #3
RE: mail from www-data?
Are you running php-fastcgi/suexec or mod_php?
11-05-2007 06:07 PM
Visit this user's website Find all posts by this user Quote this message in a reply
achioo Offline
Junior Member
*

Posts: 76
Joined: Nov 2006
Reputation: 0
Post: #4
RE: mail from www-data?
I think I've tried both...
11-05-2007 09:37 PM
Find all posts by this user Quote this message in a reply
joximu Offline
helper
*****
Moderators

Posts: 7,024
Joined: Jan 2007
Reputation: 92
Post: #5
RE: mail from www-data?
If fastcgi-php-suexec then the settings are in /var/www/fcgi/<domain>/php5(or 4?)/php.ini

if mod_php then you can add a php_admin_value in the apache config...

BUT: sendmail_from is only used in php/windows... (see php docu).

I think we have to change something in postfix so that outgoing mails are valid.

/J
11-05-2007 10:46 PM
Visit this user's website Find all posts by this user Quote this message in a reply
rbtux Offline
Moderator
*****
Moderators

Posts: 1,847
Joined: Feb 2007
Reputation: 33
Post: #6
RE: mail from www-data?
output of postconf -n would be nice, and additionally the according part from the maillog
11-05-2007 10:57 PM
Visit this user's website Find all posts by this user Quote this message in a reply
achioo Offline
Junior Member
*

Posts: 76
Joined: Nov 2006
Reputation: 0
Post: #7
RE: mail from www-data?
joximu,

I've actually tried editing that php.ini and set it so that the path is /usr/sbin/sendmail -t -i -f email@address.com (which should work with unix) but it still doesn't Sad it's kinda disappointing...


rbtux,

I'll get it as soon as I can...
11-06-2007 01:05 AM
Find all posts by this user Quote this message in a reply
achioo Offline
Junior Member
*

Posts: 76
Joined: Nov 2006
Reputation: 0
Post: #8
RE: mail from www-data?
Correction... it's not running as fcgid... it's using the standard /etc/php5/apache2/php.ini so my guess is that it's mod_php but it still won't pull from php_admin_value (to include the previously mentioned path edit)
11-06-2007 01:08 AM
Find all posts by this user Quote this message in a reply
achioo Offline
Junior Member
*

Posts: 76
Joined: Nov 2006
Reputation: 0
Post: #9
RE: mail from www-data?
rbtux

Code:
postconf -n

alias_database = hash:/etc/aliases
append_at_myorigin = yes
append_dot_mydomain = no
biff = no
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/lib/postfix
inet_interfaces = all
local_destination_recipient_limit = 1
local_recipient_maps = unix:passwd.byname $alias_database
local_transport = local
mail_spool_directory = /var/mail
mailbox_command = procmail -a "$EXTENSION"
mailbox_size_limit = 0
mydestination = $myhostname, $mydomain
mydomain = some.domain.local
myhostname = some.domain
mynetworks_style = host
myorigin = $mydomain
setgid_group = postdrop
smtpd_recipient_restrictions = permit_mynetworks,                               permit_sasl_authenticated,                               reject_unauth_destination                               check_policy_service inet:127.0.0.1:60000
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sasl_security_options = noanonymous
smtpd_sender_restrictions = permit_mynetworks,                               permit_sasl_authenticated,                               reject_unauth_destination
transport_maps = hash:/etc/postfix/ispcp/transport
virtual_alias_maps = hash:/etc/postfix/ispcp/aliases
virtual_gid_maps = static:8
virtual_mailbox_base = /var/mail/virtual
virtual_mailbox_domains = hash:/etc/postfix/ispcp/domains
virtual_mailbox_limit = 0
virtual_mailbox_maps = hash:/etc/postfix/ispcp/mailboxes
virtual_minimum_uid = 1001
virtual_transport = virtual
virtual_uid_maps = static:1001

Code:
mail.log

Nov  5 06:36:05 ftp postfix/qmgr[9624]: 20D5D8383AE: from=<www-data@some.domain.local>, size=2044, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 2B74683836F: from=<www-data@some.domain.local>, size=2046, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 2408083837F: from=<www-data@some.domain.local>, size=2023, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 288558383FA: from=<www-data@some.domain.local>, size=2107, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 5616B8383C6: from=<www-data@some.domain.local>, size=2057, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 6DF1983845C: from=<www-data@some.domain.local>, size=1623, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: D5576838427: from=<www-data@some.domain.local>, size=1621, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: D19E28383A5: from=<www-data@some.domain.local>, size=2040, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: DB0138383F8: from=<www-data@some.domain.local>, size=2074, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 4B86683847C: from=<www-data@some.domain.local>, size=1603, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 458A68383EC: from=<www-data@some.domain.local>, size=2087, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 3FCDA83832E: from=<www-data@some.domain.local>, size=2101, nrcpt=1 (queue active)
Nov  5 06:36:05 ftp postfix/qmgr[9624]: 9CA6F838335: from=<www-data@some.domain.local>, size=2041, nrcpt=1 (queue active)
Nov  5 06:36:06 ftp postfix/qmgr[9624]: 80E83838495: from=<www-data@some.domain.local>, size=1619, nrcpt=1 (queue active)
11-06-2007 03:55 AM
Find all posts by this user Quote this message in a reply
Schlummi Offline
Newbie
*

Posts: 5
Joined: Oct 2007
Reputation: 0
Post: #10
RE: mail from www-data?
On my system, I had to change the following after installation:
/etc/postfix/main.cf

Line mydomain = <my domain>.local
to
Line mydomain = <my domain>

After that mailing seems to work.
11-06-2007 06:27 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 4 Guest(s)