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.

SMTP Tweak not working

Discussion in 'E-mail Discussions' started by dolphyn, Feb 18, 2009.

  1. dolphyn

    dolphyn Well-Known Member

    Joined:
    Nov 27, 2001
    Messages:
    64
    Likes Received:
    0
    Trophy Points:
    6
    cPanel Access Level:
    Root Administrator
    SMTP Tweak not working on VPS (found solution)

    I have enabled the SMTP Tweak in WHM, but I can still connect directly from a user account to an external SMTP server using telnet or perl. Any suggestions for troubleshooting?

    I don't know how the SMTP Tweak actually works, so I'm not sure where to look. :(
     
    #1 dolphyn, Feb 18, 2009
    Last edited: Feb 25, 2009
  2. rhenderson

    rhenderson Well-Known Member

    Joined:
    Apr 21, 2005
    Messages:
    785
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Oklahoma
    cPanel Access Level:
    Root Administrator
    Just curious if your running CSF? If so that tweak will cause CSF to not work.
     
  3. dolphyn

    dolphyn Well-Known Member

    Joined:
    Nov 27, 2001
    Messages:
    64
    Likes Received:
    0
    Trophy Points:
    6
    cPanel Access Level:
    Root Administrator
    Okay, I have partially answered my own question. Apparently CPanel is managing (or mismanaging) iptables behind the scenes.

    On another server where SMTP Tweak works, "/etc/init.d/iptables status" shows:
    Code:
    Chain OUTPUT (policy ACCEPT)
    target     prot opt source               destination
    ACCEPT     tcp  --  anywhere             localhost          tcp dpt:smtp OWNER UID match cpanel
    ACCEPT     tcp  --  anywhere             localhost          tcp dpt:smtp
    ACCEPT     tcp  --  anywhere             anywhere           tcp dpt:smtp OWNER GID match mail
    ACCEPT     tcp  --  anywhere             anywhere           tcp dpt:smtp OWNER GID match mailman
    ACCEPT     tcp  --  anywhere             anywhere           tcp dpt:smtp OWNER UID match root
    REJECT     tcp  --  anywhere             anywhere           tcp dpt:smtp reject-with icmp-port-unreachable
    Well, that makes sense, but nothing of the sort shows up on the VPS where SMTP Tweak is broken. However, if I do "/etc/init.d/cpanel restart", then the iptables status shows:
    Code:
    Chain OUTPUT (policy ACCEPT)
    num  target     prot opt source               destination
    1    ACCEPT     tcp  --  0.0.0.0/0            127.0.0.1           tcp dpt:25
    2    REJECT     tcp  --  0.0.0.0/0            0.0.0.0/0           tcp dpt:25 reject-with icmp-port-unreachable
    With that setting, even Exim cannot send outgoing mail, which is just dandy. But the configuration goes away if I restart iptables, since none of it is in /etc/sysconfig/iptables. And if I reboot the server, there are a lot of iptables settings which seem to appear from out of the blue.

    (And no, I'm not running CSF or APF ... but I'm going to look into them today.)
     
  4. dolphyn

    dolphyn Well-Known Member

    Joined:
    Nov 27, 2001
    Messages:
    64
    Likes Received:
    0
    Trophy Points:
    6
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page