bambenek

Member
Feb 1, 2002
15
0
301
Whenever I log into the machine, and try to send mail from an address on the machine to an address on the machine (in the shell), I get the silly mail loops back to me (MX error?) message...

It happens on all accounts that are local...
 
B

bdraco

Guest
[quote:a9bed9b7df][i:a9bed9b7df]Originally posted by bambenek[/i:a9bed9b7df]

Whenever I log into the machine, and try to send mail from an address on the machine to an address on the machine (in the shell), I get the silly mail loops back to me (MX error?) message...

It happens on all accounts that are local...[/quote:a9bed9b7df]
Try running /scripts/mailperm
 

bambenek

Member
Feb 1, 2002
15
0
301
Found it. The problem is that when you send mail locally on a machine (or have a forwarded) it uses sendmail. When the To: address is somewhere on the same machine, sendmail balks because it doesn't know anything about the domains or users because exim handles all that.

I tried to just input the localdomains file into sendmail.cf and that KINDA worked. The problem was that it would deliver based on user name on the machine, not to any &virtual& users.

What worked was moving the sendmail binary, and created a softlink named sendmail that pointed to exim, and everythig works wonderfully now.
 

moronhead

Well-Known Member
Aug 12, 2001
706
0
316
[quote:5702e5222f][i:5702e5222f]Originally posted by bambenek[/i:5702e5222f]

..... I tried to just input the localdomains file into sendmail.cf and that KINDA worked. ..... [/quote:5702e5222f]

sendmail.cf in a cpanel box? Where's that file?
 

bambenek

Member
Feb 1, 2002
15
0
301
When the server was installed, sendmail wasn't uninstalled, it was just disabled. /etc/sendmail.cf still was there. The problem is that when you have .forwards, and local mail programs (like pine), it uses /usr/sbin/sendmail to send the mail. When it looks at where it's going, it will use the sendmail.cf and associated configurations. In Cpanel'd boxes, it notices that the mail is pointed back at itself, but if there isn't anything in sendmail.cf to indicate all the local domains, it'll bounce. But when it sends mail back to the same host it uses sendmail to deliver, not exim, therefore it delivers based on user accounts, not on virtual domains and virtual accounts.

I'm not sure if you can just delete sendmail all together, but having /usr/sbin/sendmail softlinked to /usr/sbin/exim uses exim as the mail transfer agent and it bypasses all the goofy sendmail issues.