Solved - Email system error

Discussion in 'Installation/Configuration' started by Thilak, Sep 23, 2018.

  1. Thilak

    Thilak Member

    I have installed ISPConfig on ubuntu with all default settings using auto installer. After configuration, I have followed this url to configure SSL on all main services.
    From begenning, I am getting some errors in the mail servers like 10025 port being used by another process, 10026 is being used by another etc. I have restarted the whole server and then I got mail server running. But, later I got 10024 is being used by another process while sending mails. Below are the error logs from mail server section.

    connect to 127.0.0.1[127.0.0.1]:10024: Connection refused
    postfix/master[22364]: fatal: bind 127.0.0.1 port 10025: Address already in use
    postfix/master[6103]: fatal: bind 127.0.0.1 port 10026: Address already in use
    Can't connect to TCP port 10025 on 127.0.0.1 [Address already in use]#012 at line 64 in file /usr/share/perl5/Net/Server/Proto/TCP.pm

    Can anyone help me out how can I get my mail server working perfectly? I do not use SMTP from my server. I just use wordpress plugins to send mails from other SMTP servers and receive mails on my server. MX record is perfectly configured (It was working fine with CWP previously. I switched to ISP config to solve FTP error of CWP)

    Update: I am using ISPConfig 3.1.13 running on Ubuntu LTS 18.04.
    I can't even send mails from local server to local.
    I tried to find which process is using port 10025 and found that perl was using it. After reboot server, I got problem to port 10024 which was used by some other process. Sendmail is not installed on the server. Tried by restarting postfix server etc. Problem remains same.
     
    Last edited: Sep 23, 2018
  2. Taleman

    Taleman Well-Known Member HowtoForge Supporter

  3. Thilak

    Thilak Member

  4. Thilak

    Thilak Member

    Here are the requested + few extra logs from the server. [Note: In installation log, I have changed the IP and some changes done. Also, I have appended .txt to the extension of all files to avoid file upload blocks]
    I had selected all default settings. But, I found that there is some error in dbconfig noted somewhere later. I would like to install wordpress on this server once problems are solved.
     

    Attached Files:

  5. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Did you do the ISPConfig install on an empty host? I mean, you write you had some other system and then started using ISPConfig, but did you install ISPConfig on the host that already was set up for that other system?
    The htf_report.txt seems strange, there is localhost instead of the IP-number. And Postfix configuration file may be faulty. Compare what you have there with tie Perfect Server Guide.
     
  6. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Find out what process is running on those ports postfix complains about.
    Use fuser command to find the PID, then use that Process ID to see what process it is.
    Code:
    fuser -n tcp 10024
    Code:
    ps -ef | grep thatPIDfromPreviousCommand
     
  7. Thilak

    Thilak Member

    It is fresh server with fresh ubuntu installed from Digital Ocean.
    [Note: Currently, monitor tab of the ISPConfig is showing 0 errors. But, I cannot use emails for both incoming and outgoing.]
    "And Postfix configuration file may be faulty. Compare what you have there with tie Perfect Server Guide." --> Is there any available configuration file to compare? or any way to reset to default as required for ISPC?

    There is no process is currently using port 10024.
    Here is the list of port numbers I got from 'netstat -ltnp'
    Active Internet connections (only servers)
    Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
    tcp 0 0 0.0.0.0:993 0.0.0.0:* LISTEN 698/dovecot
    tcp 0 0 0.0.0.0:995 0.0.0.0:* LISTEN 698/dovecot
    tcp 0 0 127.0.0.1:10023 0.0.0.0:* LISTEN 895/postgrey --pidf
    tcp 0 0 127.0.0.1:10025 0.0.0.0:* LISTEN 1058/master
    tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 810/mysqld
    tcp 0 0 127.0.0.1:10027 0.0.0.0:* LISTEN 1058/master
    tcp 0 0 127.0.0.1:11211 0.0.0.0:* LISTEN 704/memcached
    tcp 0 0 0.0.0.0:110 0.0.0.0:* LISTEN 698/dovecot
    tcp 0 0 0.0.0.0:143 0.0.0.0:* LISTEN 698/dovecot
    tcp 0 0 0.0.0.0:21 0.0.0.0:* LISTEN 949/pure-ftpd (SERV
    tcp 0 0 10.47.0.6:53 0.0.0.0:* LISTEN 640/named
    tcp 0 0 192.168.1.1:53 0.0.0.0:* LISTEN 640/named
    tcp 0 0 127.0.0.1:53 0.0.0.0:* LISTEN 640/named
    tcp 0 0 127.0.0.53:53 0.0.0.0:* LISTEN 500/systemd-resolve
    tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 709/sshd
    tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 1058/master
    tcp 0 0 127.0.0.1:953 0.0.0.0:* LISTEN 640/named
    tcp6 0 0 :::443 :::* LISTEN 860/apache2
    tcp6 0 0 :::993 :::* LISTEN 698/dovecot
    tcp6 0 0 :::995 :::* LISTEN 698/dovecot
    tcp6 0 0 ::1:10023 :::* LISTEN 895/postgrey --pidf
    tcp6 0 0 :::110 :::* LISTEN 698/dovecot
    tcp6 0 0 :::143 :::* LISTEN 698/dovecot
    tcp6 0 0 :::8080 :::* LISTEN 860/apache2
    tcp6 0 0 :::80 :::* LISTEN 860/apache2
    tcp6 0 0 :::8081 :::* LISTEN 860/apache2
    tcp6 0 0 :::21 :::* LISTEN 949/pure-ftpd (SERV
    tcp6 0 0 :::53 :::* LISTEN 640/named
    tcp6 0 0 :::22 :::* LISTEN 709/sshd
    tcp6 0 0 :::25 :::* LISTEN 1058/master
    tcp6 0 0 ::1:953 :::* LISTEN 640/named
     
  8. Thilak

    Thilak Member

    I have a static IP for the server. I want to use this server to host 2 wordpress websites and email hosting for 2 domains (Only incoming mails. Outgoing mails will be overridden in wordpress to use different SMTP server).
     
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    Please post the /etc/postfix/master.cf file of your server.
     
  10. Thilak

    Thilak Member

    Attached both master and main
     

    Attached Files:

  11. till

    till Super Moderator Staff Member ISPConfig Developer

    You missed to removed the # in front of the smtps and the submission line. Remove the # in both lines and restart postfix.
     
  12. Thilak

    Thilak Member

    Done. Still having errors. I get errors from Gmail while sending mails to it as "The recipient server did not accept our requests to connect". I think there is a major issue.
    I will rebuild the server again from blank. Do I need to switch to debian or ubuntu is ok?
     
  13. till

    till Super Moderator Staff Member ISPConfig Developer

    Do not reinstall the server, the problem can be outside of the server and with a reinstall you will just waste your time. To test the mail system:

    1) Create an email account in ispconfig.
    2) Login to webmail (roundcube) on your server with the email address and password of this account.
    3) send en email to the same email address you used for roundcube login, the email should arrive in inbox in roundcube within a few seconds. If not, take a look at the mail.log file to see why.
     
  14. Thilak

    Thilak Member

    Now, I am getting message sent notification in roundcube. But, mail is not delivering to either same ID or different ID.
    I got the log in mail.err as
    Sep 24 18:18:15 mydomain amavis[1481]: (01481-04) (!!)AV: ALL VIRUS SCANNERS FAILED
    mail log is attached.
     

    Attached Files:

  15. till

    till Super Moderator Staff Member ISPConfig Developer

    This is the reason for your problem:

    Code:
    warning: do not list domain mydomain.com in BOTH mydestination and virtual_mailbox_domains
    The tutorial instructed you to use a subdomain like server1.example.com for the server hostname to avoid the error you have now but you used a domain name (not subdomain) instead. To fix your error, replace your domain name with a subdomain in:

    /etc/hosts
    /etc/hostname
    /etc/mailname
    /etc/postfix/main.cf

    (wherever it occurs in these files) and restart the server / vm.
     
  16. Thilak

    Thilak Member

    Done. Again started some errors.
    mail.err:
    Sep 25 00:08:50 hosting spampd[1176]: 2018/09/25-00:08:50 Can't connect to TCP port 10025 on 127.0.0.1 [Address already in use]#012 at line 64 in file /usr/share/perl5/Net/Server/Proto/TCP.pm
    Sep 25 00:09:40 hosting amavis[1226]: (01226-01) (!!)AV: ALL VIRUS SCANNERS FAILED
    Sep 25 00:10:02 hosting amavis[1227]: (01227-01) (!!)AV: ALL VIRUS SCANNERS FAILED

    mail.log attached
     

    Attached Files:

  17. Thilak

    Thilak Member

    I have created 2 sites called mydomain.com & mydomain2.com. I also added 2 mail domains same as sites. Created 2 accounts in one domain and one account in another. Cross domain mailing using roundcube as well as mail to same address is not working. my host name was set in Digital Ocean control panel and it is auto set to the server. Also, I had used same domain name for all FQDN. Now, I have updated the domain with subdomain as you told previously.
     
  18. Thilak

    Thilak Member

    Now I got one mail account working after changing to subdomain. I have one more email domain in same server. I had added that domain to mydomain field of Postfix config file. Do I need to remove it? Will additional mail domains work in ISPConfig?

    Also, I see more delay in email delivery. I was using same postfix and Dovecot in CWP panel first and there it was working fine. There too I had two domains.
     
  19. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    When you get that "address already in use" can you see what process is using that port? Like in #6.
    Check if some stuff has failed:
    Code:
    systemctl --state=failed
    Is something disabled or otherwise not started?
    Code:
    systemctl list-unit-files
     
  20. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes and yes. Email domains may not be added in mydomain field in main.cf file, if you add them there, then the email domain will not work.
     

Share This Page