Join the community today
Register Now

Email email sending not working

Discussion in 'Domains, DNS, Email & SSL Certificates' started by hitman, Jan 13, 2018.

  1. hitman

    hitman Member

    121
    11
    18
    Jul 18, 2014
    Ratings:
    +15
    Local Time:
    5:54 PM
    hello
    i am facing this issue where the server cannot send emails

    this is the log from when trying to send an email from terminal
    command used is
    Code:
    echo "this is the body" | mail -s "this is the subject" "[email protected]"
    results
    Code:
    Jan 12 16:27:46 name sendmail[1533]: w0CGRkEJ001533: from=root, size=237, class=0, nrcpts=1, msgid=<[email protected]>, [email protected]
    Jan 12 16:27:46 name sendmail[1533]: w0CGRkEJ001533: [email protected], ctladdr=root (0/0), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30237, relay=[127.0.0.1] [127.0.0.1], dsn=4.0.0, stat=Deferred: Connection refused by [127.0.0.1]
    

    any idea what might be wrong?
     
  2. eva2000

    eva2000 Administrator Staff Member

    35,076
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    12:54 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    1. has email ever worked on server before and after centmin mod install ?
    2. have you modified postfix MTA server in anyway since centmin mod install ? if you have, what did you change ?
    3. web host ? some web hosts like Vultr block outbound emails until you contact them for ID verification so they will unblock out bound email sending. Other web hosts like speedykvm/incero based block email sending on main server IP.

    You'll need to post on the forums with the following info
    • Server or VPS details ? XEN, KVM, OpenVZ, VMWare or dedicated server ? OS ? CentOS 6.9 or 7.4 ? 32bit or 64bit ?
    • What version of Centmin Mod ? .07 stable or 08 stable or .09 beta01 or another branch version ?
    • Was it fresh install or upgrade ?
    • Method of install ? Via centmin.sh menu option 1, Git install or curl one liner install as outlined at centminmod.com/download.html ?
    • How long ago did you install Centmin Mod ?
    FYI, centmin mod usually defaults to install postfix MTA server.
     
    • Like Like x 1
  3. hitman

    hitman Member

    121
    11
    18
    Jul 18, 2014
    Ratings:
    +15
    Local Time:
    5:54 PM

    1. i do not remember at all, but from the depths of my mind i think it never worked
    2. never touched MTA server
    3. i am on Vultr, had already contacted them and its not from their side
    more info

    System Up Since: 2017-09-03 13:42:34
    Server Type: kvm
    CentOS Version: 7.4
    Centmin Mod: 123.09beta01.b012
    Fresh Install: yes
    Install Method: curl command
     
  4. eva2000

    eva2000 Administrator Staff Member

    35,076
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    12:54 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    strange then you should be running postfix and not sendmail

    output for
    Code (Text):
    service postfix status
    


    output for command to check CSF Firewall's whitelisted ports
    Code (Text):
    egrep '^TCP_|^TCP6_|^UDP_|^UDP6_' /etc/csf/csf.conf
    

    example
    Code (Text):
    egrep '^TCP_|^TCP6_|^UDP_|^UDP6_' /etc/csf/csf.conf
    TCP_IN = "20,21,22,25,53,80,110,143,161,443,465,587,993,995,1110,1186,1194,81,9418,30001:50011"
    TCP_OUT = "993,995,465,587,1110,1194,9418,20,21,22,25,53,80,110,113,443,587,993,995"
    UDP_IN = "67,68,1110,33434:33534,20,21,53"
    UDP_OUT = "67,68,1110,33434:33534,20,21,53,113,123"
    TCP6_IN = "20,21,22,25,53,80,110,143,161,443,465,587,993,995,1110,1186,1194,81,9418,30001:50011"
    TCP6_OUT = "993,995,465,587,20,21,22,25,53,80,110,113,443,587,993,995"
    UDP6_IN = "20,21,53"
    UDP6_OUT = "20,21,53,113,123"
    


    wrap outputs in CODE tags
     
  5. eva2000

    eva2000 Administrator Staff Member

    35,076
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    12:54 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    might need initial install log to dig deeper

    To troubleshoot initial installation, you need to check the initial install log at /root/centminlogs and instructions under Sharing logs and errors heading for using Pastebin.com or Gists to share a sanitised version of the contents of the initial install log. You can see full details at How to troubleshoot Centmin Mod initial install issues

    Example list /root/centminlogs files in date ascending order and grep for install.log
    Code (Text):
    ls -lahrt /root/centminlogs | grep install.log
    

    example output returns install log at /root/centminlogs/centminmod_1.2.3-eva2000.09.001_111016-112321_install.log
    Code (Text):
    ls -lahrt /root/centminlogs | grep install.log
    -rw-r--r--  1 root root 2.2M Oct 11 01:40 centminmod_1.2.3-eva2000.09.001_111016-112321_install.log
    

    in SSH use cat to ouput contents of /root/centminlogs/centminmod_1.2.3-eva2000.09.001_111016-112321_install.log. Clear your SSH client window/buffer so only output is the contents of the file
    Code (Text):
    cat /root/centminlogs/centminmod_1.2.3-eva2000.09.001_111016-112321_install.log
    

    Then copy and paste into Pastebin.com or Gists entry. If your SSH window scroll buffer isn't that large to get the whole contents of the install log, you can download file manually and copy and paste contents. But makes sure it's sanitised version of the contents of the initial install log as outlined at How to troubleshoot Centmin Mod initial install issues
     
  6. hitman

    hitman Member

    121
    11
    18
    Jul 18, 2014
    Ratings:
    +15
    Local Time:
    5:54 PM
    thank you veeery much for your help
    it turned out that a server restart fixed things, i did not try that before :facepalm:
     
    • Like Like x 1
  7. eva2000

    eva2000 Administrator Staff Member

    35,076
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    12:54 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    was about to say after vultr unblocks emails, you would need to restart server :)
     
..