mail routing trouble (ensim/linux dedicated)
CHEERS to anyone who can tell me what's going on here!I've been trying to figure this out all day and it's killing me. I have a dedicated linux server and a few domains hosted on it.
My problem: When I send mail out from me@domain.com using PHP mail() or IMAP_OPEN(), I want to get all bounces to get back to catch-all@domain.com. What it's doing however is being caught by root@dedicated.myserver.com - the root email account for the server.
So, I setup an alias at /etc/alias to forward the root mail to the catch-all@mydomain.com (root: me), so it does work, but now I'll get ALL root mail from the entire server going to my domain catchall account. I don't want that.
I'm at a loss as to what's going on. Also, I do have squirrelmail setup on my domain, and when I send mail from it and it bounces, it goes to the proper place!
See these examples, both now routed to my catchall inbox:
Bounces from PHP mail() or IMAP_SEND():
send From anyone@mydomain.com
---------------------------------------
Subject: Returned mail
From: Mail Delivery Subsystem <MAILER-DAEMON@dedicated.e-interactive.com>
To: apache@dedicated.e-interactive.com <--SHOULD BE ANYONE@MYDOMAIN.COM
Bounces from Squirrelmail:
send From anyone@mydomain.com
---------------------------------------
Subject: Returned mail
From: Mail Delivery Subsystem <MAILER-DAEMON@dedicated.e-interactive.com>
To: <anyone@mydomain.com> <--- THIS IS CORRECT