The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

nobody@ problem with php mail()

Discussion in 'E-mail Discussions' started by blueghozt, Jul 6, 2009.

  1. blueghozt

    blueghozt Registered

    Joined:
    Sep 6, 2007
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Brighton
    going bananas trying to find a solution to this - my new cpanel vps will not send mail from my php scripts that work on another, same spec, vps

    using php mail() results in all outbound mails being marked with return path of nobody@hostname - I have checked the Tweak Settings checkbox to disallow nobody@ mails so they are now just being discarded - all outbound mails are being discarded.

    The support at the vps host just said to edit php to not send from nobody@ - like that's what I have been trying to find out how to do for hours now - recompiled apache again - still no joy - has anyone had this problem before, or more importantly anyone know how to fix it? I need to be up and running in the morning with this.... :confused:
     
  2. jganders

    jganders Registered

    Joined:
    Jul 6, 2009
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    I had probs with nobody. apache is typically installed under nobody.
    Lets say you have a cpanel account 'myweb'. And your domain is myweb.com. When someone browses myweb.com the php scripts see the system user as nobody.

    You may need to recompile apache using mod_suphp. suPHP provides an easy way to run PHP scripts with different users on the same server. It provides security, because the PHP scripts are not run with the rights of the webserver's user (nobody). In addition to that you probably won't have to use PHP's "safe mode", which applies many restrictions on php scripts.

    If you recompile apache (using easyapache for instance) with the mod_suphp and people browse myweb.com, the running php scripts will then see the system user as, you guessed it, 'myweb'.

    If you decide to use mod_suphp you must make sure all files have permissions 644 and all directories 755.
     
  3. blueghozt

    blueghozt Registered

    Joined:
    Sep 6, 2007
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Brighton
    thanks for the suggestion - I did that just now but no luck - raised a ticket to see if I can get more help from the techs.
     
  4. blueghozt

    blueghozt Registered

    Joined:
    Sep 6, 2007
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Brighton
    now they tell me to check for open ports - so I am scrabbling around for this now - it seems like portsentry is the firewall I am running and might not have open ports for sending mail hence bouncebacks (though why to nobody@ and not the sending address?)
     
Loading...

Share This Page