IMAP doesn't sync email from the external domain.

Use this forum if you have installed hMailServer and want to ask a question related to a production release of hMailServer. Before posting, please read the troubleshooting guide. A large part of all reported issues are already described in detail here.
Post Reply
internetms52
New user
New user
Posts: 6
Joined: 2018-12-19 03:50

IMAP doesn't sync email from the external domain.

Post by internetms52 » 2018-12-19 04:41

Hi everyone,

I am recently transferring email server to another domain.
what I tried was building a whole new domain then copy all the email data to the new mail server, then change the DNS setting.

when I tried to send email from Google to new email domain, ThunderBird Mail Client witch using IMAP configure doesn't display an email message.

But if I send an email by the original email domain, It show's at ThunderBird inbox.

I've checked server logs, got RECEIVED Message below:

"SMTPD" 3488 "SENT: 220 Welcome"
"SMTPD" 2200 "RECEIVED: EHLO mail-pl1-f176.google.com"
"SMTPD" 2200 "SENT: 250-mail.*.com[nl]250-SIZE 20480000[nl]250-AUTH LOGIN PLAIN[nl]250 HELP"
"SMTPD" 3312 "RECEIVED: MAIL FROM:<gmail> SIZE=2470"
"SMTPD" 3312 "SENT: 250 OK"
"SMTPD" 2200 "RECEIVED: RCPT TO:<New Email>"
"SMTPD" 2200 "SENT: 250 OK"
"SMTPD" 3244 "RECEIVED: DATA"
"SMTPD" 3244 "SENT: 354 OK, send."
"IMAPD" 3312 "RECEIVED: DONE"

The message looks good, but I didn't get any message from IMAP sync.
Is anyone else facing this issue?

My hmailServer version is 5.6.4-B2283 and I am using GoDaddy DNS Service.

User avatar
mattg
Moderator
Moderator
Posts: 20228
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: IMAP doesn't sync email from the external domain.

Post by mattg » 2018-12-19 04:55

If you want to transfer via IMAP
you connect to both servers with your mail client and drag and drop from one to the other
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

internetms52
New user
New user
Posts: 6
Joined: 2018-12-19 03:50

Re: IMAP doesn't sync email from the external domain.

Post by internetms52 » 2018-12-19 05:18

thanks for the reply.
But it's almost 30 accounts on the server.
If I can import data to the new Email server, I don't have to Sync email account one by one.
Is there any possibility I can keep both sites of the email domain, then shift through DNS?

User avatar
mattg
Moderator
Moderator
Posts: 20228
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: IMAP doesn't sync email from the external domain.

Post by mattg » 2018-12-19 08:22

sure

point to one or the other by IP address instead of FQDN

ie in mail client server settings use 123.123.123.999 instead of mail.example.com
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

internetms52
New user
New user
Posts: 6
Joined: 2018-12-19 03:50

Re: IMAP doesn't sync email from the external domain.

Post by internetms52 » 2018-12-20 10:40

After some experiment, I found that Email comes from Google or any other Email server will be stored in the "data" without domain name folder.
So, the mail client will only display previous Domain mail.

Data|
.......|-previousDomain|
................................|-mail from the previous domain
.......|-mail from an external domain(0KB)
.......|-another mail from an external domain(0KB)

Does anyone know what configuration will cause this issue?

User avatar
mattg
Moderator
Moderator
Posts: 20228
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: IMAP doesn't sync email from the external domain.

Post by mattg » 2018-12-20 13:48

mail sits in the data directory awaiting final delivery, either to a local account or an external account

If the are 0 KB files sitting there, your antivirus has probably broken them
Make sure that your antivirus excludes your data directory from routine scanning

are you sure that the message isn't also copied to the domain folders

Enable all logging, send your self an email from gmail, wait at least 90 seconds and post all logs created
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

internetms52
New user
New user
Posts: 6
Joined: 2018-12-19 03:50

Re: IMAP doesn't sync email from the external domain.

Post by internetms52 » 2018-12-21 05:19

Thank you for keep helping me figure out the problem.

There is no antivirus on this computer.
here is the software list:
  • 7-Zip 18.05 (x64)
  • Google Chrome
  • hMailServer 5.6.4-B2283
  • Microsoft .NET Framework 4.5.2
  • Microsoft Visual C++ 2013 Redistributable (x64)
  • Mozilla Maintenance Service
  • Mozilla Thunderbird 45.8.0 (x86 zh-TW)
  • MySQL Connector C++ 1.1.7
  • MySQL Connector J
  • MYSQL Comector Net 6.9.8
  • MySQL Connector/C 6.1
  • MySQL Documents 5.7
  • MySQL Examples and Samples 5.7
  • MySQL Fabric 1.5.6 & MySQL Utilities 1.5.6
  • MySQL Installer - Community
  • MySQL Notifier 1.1.6
  • MySQL Server 5.7
  • MySQL Workbench 6.3 CE
and logs while receiving Gmail(Sorry for the IP And domain name mask, my colleague doesn't allow me to post any messages have IP and Domain name on the public network.):
"DEBUG" 2760 "2018-12-21 09:46:28.713" "Creating session 18"
"TCPIP" 2760 "2018-12-21 09:46:28.713" "TCP - {public network guest A}connected to {private network server IP}:25."
"DEBUG" 2760 "2018-12-21 09:46:28.713" "TCP connection started for session 17"
"SMTPD" 2760 17 "2018-12-21 09:46:28.713" "{public network guest A}" "SENT: 220 Welcome"
"SMTPD" 3136 17 "2018-12-21 09:46:28.838" "{public network guest A}" "RECEIVED: EHLO mail-pg1-f179.google.com"
"SMTPD" 3136 17 "2018-12-21 09:46:28.838" "{public network guest A}" "SENT: 250-{server domain name}[nl]250-SIZE 20480000[nl]250-AUTH LOGIN PLAIN[nl]250 HELP"
"SMTPD" 4780 17 "2018-12-21 09:46:28.963" "{public network guest A}" "RECEIVED: MAIL FROM:<{gmail address A}> SIZE=14455"
"DEBUG" 4780 "2018-12-21 09:46:28.963" "Total spam score: 0"
"SMTPD" 4780 17 "2018-12-21 09:46:28.963" "{public network guest A}" "SENT: 250 OK"
"SMTPD" 2760 17 "2018-12-21 09:46:29.088" "{public network guest A}" "RECEIVED: RCPT TO:<{local mail server account name A}>"
"SMTPD" 2760 17 "2018-12-21 09:46:29.088" "{public network guest A}" "SENT: 250 OK"
"SMTPD" 2948 17 "2018-12-21 09:46:29.213" "{public network guest A}" "RECEIVED: DATA"
"SMTPD" 2948 17 "2018-12-21 09:46:29.213" "{public network guest A}" "SENT: 354 OK, send."
"DEBUG" 2760 "2018-12-21 09:47:36.667" "Creating session 20"
"TCPIP" 2760 "2018-12-21 09:47:36.667" "TCP - {public network guest C} connected to {private network server IP}:25."
"DEBUG" 2760 "2018-12-21 09:47:36.667" "TCP connection started for session 19"
"SMTPD" 2760 19 "2018-12-21 09:47:36.667" "{public network guest C}" "SENT: 220 Welcome"
"SMTPD" 2948 19 "2018-12-21 09:47:36.792" "{public network guest C}" "RECEIVED: EHLO mail-pf1-f169.google.com"
"SMTPD" 2948 19 "2018-12-21 09:47:36.792" "{public network guest C}" "SENT: 250-{server domain name}[nl]250-SIZE 20480000[nl]250-AUTH LOGIN PLAIN[nl]250 HELP"
"SMTPD" 4780 19 "2018-12-21 09:47:36.932" "{public network guest C}" "RECEIVED: MAIL FROM:<{gmail address A}> SIZE=13676"
"DEBUG" 4780 "2018-12-21 09:47:36.932" "Total spam score: 0"
"SMTPD" 4780 19 "2018-12-21 09:47:36.932" "{public network guest C}" "SENT: 250 OK"
"SMTPD" 2760 19 "2018-12-21 09:47:37.057" "{public network guest C}" "RECEIVED: RCPT TO:<{local mail server account name A}>"
"SMTPD" 2760 19 "2018-12-21 09:47:37.057" "{public network guest C}" "SENT: 250 OK"
"SMTPD" 2948 19 "2018-12-21 09:47:37.182" "{public network guest C}" "RECEIVED: DATA"
"SMTPD" 2948 19 "2018-12-21 09:47:37.182" "{public network guest C}" "SENT: 354 OK, send."

As you can see, it is no any error message between Welcome message and SMTPD SENT 354, but it's different with the email sending from previous server.
here is the log of sending email from previous server:

"DEBUG" 2760 "2018-12-21 10:56:17.621" "Creating session 82"
"TCPIP" 2760 "2018-12-21 10:56:17.621" "TCP - {public network guest D} connected to {private network server IP}:25."
"DEBUG" 2760 "2018-12-21 10:56:17.621" "TCP connection started for session 81"
"SMTPD" 2760 81 "2018-12-21 10:56:17.621" "{public network guest D}" "SENT: 220 Welcome"
"SMTPD" 592 81 "2018-12-21 10:56:17.652" "{public network guest D}" "RECEIVED: EHLO {previous server domain name}"
"SMTPD" 592 81 "2018-12-21 10:56:17.652" "{public network guest D}" "SENT: 250-{server domain name}[nl]250-SIZE 20480000[nl]250-AUTH LOGIN PLAIN[nl]250 HELP"
"SMTPD" 4164 81 "2018-12-21 10:56:17.668" "{public network guest D}" "RECEIVED: MAIL FROM:<{previous mail server account A}>"
"DEBUG" 4164 "2018-12-21 10:56:17.668" "Total spam score: 0"
"SMTPD" 4164 81 "2018-12-21 10:56:17.668" "{public network guest D}" "SENT: 250 OK"
"SMTPD" 4080 81 "2018-12-21 10:56:17.683" "{public network guest D}" "RECEIVED: RCPT TO:<{local mail server account name A}>"
"SMTPD" 4080 81 "2018-12-21 10:56:17.683" "{public network guest D}" "SENT: 250 OK"
"SMTPD" 2760 81 "2018-12-21 10:56:17.699" "{public network guest D}" "RECEIVED: DATA"
"SMTPD" 2760 81 "2018-12-21 10:56:17.699" "{public network guest D}" "SENT: 354 OK, send."
"DEBUG" 5016 "2018-12-21 10:56:19.887" "Adding task AsynchronousTask to work queue Asynchronous task queue"
"DEBUG" 4644 "2018-12-21 10:56:19.887" "Executing task AsynchronousTask in work queue Asynchronous task queue"
"DEBUG" 4644 "2018-12-21 10:56:19.887" "Total spam score: 0"
"DEBUG" 4644 "2018-12-21 10:56:19.887" "Saving message: {6079662F-51D1-47A9-B0E4-04282C0283B7}.eml"
"DEBUG" 4644 "2018-12-21 10:56:20.215" "Requesting SMTPDeliveryManager to start message delivery"
"SMTPD" 4644 81 "2018-12-21 10:56:20.215" "{public network guest D}" "SENT: 250 Queued (2.176 seconds)"
"SMTPD" 4080 81 "2018-12-21 10:56:20.230" "{public network guest D}" "RECEIVED: QUIT"
"SMTPD" 4080 81 "2018-12-21 10:56:20.230" "{public network guest D}" "SENT: 221 goodbye"
"DEBUG" 3592 "2018-12-21 10:56:20.230" "Ending session 81"
"DEBUG" 2096 "2018-12-21 10:56:20.293" "Adding task DeliveryTask to work queue SMTP delivery queue"
"DEBUG" 996 "2018-12-21 10:56:20.293" "Executing task DeliveryTask in work queue SMTP delivery queue"
"DEBUG" 996 "2018-12-21 10:56:20.293" "Delivering message..."
"APPLICATION" 996 "2018-12-21 10:56:20.308" "SMTPDeliverer - Message 55403: Delivering message from {previous mail server account A} to {local mail server account name A}. File: C:\Program Files (x86)\hMailServer\Data\{6079662F-51D1-47A9-B0E4-04282C0283B7}.eml"
"DEBUG" 996 "2018-12-21 10:56:20.308" "Applying rules"
"DEBUG" 996 "2018-12-21 10:56:20.308" "Performing local delivery"
"DEBUG" 996 "2018-12-21 10:56:20.387" "Applying rules"
"DEBUG" 996 "2018-12-21 10:56:20.387" "Saving message: {6079662F-51D1-47A9-B0E4-04282C0283B7}.eml"
"DEBUG" 996 "2018-12-21 10:56:20.465" "Reading messages from database."
"IMAPD" 996 9 "2018-12-21 10:56:20.465" "{Thunder Bird Client A}" "SENT: * 1 EXISTS"
"IMAPD" 996 9 "2018-12-21 10:56:20.465" "{Thunder Bird Client A}" "SENT: * 1 RECENT"
"DEBUG" 996 "2018-12-21 10:56:20.465" "AWStats::LogDeliverySuccess"
"IMAPD" 3592 9 "2018-12-21 10:56:20.496" "{Thunder Bird Client A}" "RECEIVED: DONE"
"IMAPD" 3592 9 "2018-12-21 10:56:20.496" "{Thunder Bird Client A}" "SENT: 27 OK IDLE terminated"
"DEBUG" 996 "2018-12-21 10:56:20.512" "Local delivery completed"
"APPLICATION" 996 "2018-12-21 10:56:20.512" "SMTPDeliverer - Message 55403: Message delivery thread completed."
"IMAPD" 5016 9 "2018-12-21 10:56:20.605" "{Thunder Bird Client A}" "RECEIVED: 28 check"
"IMAPD" 5016 9 "2018-12-21 10:56:20.605" "{Thunder Bird Client A}" "SENT: 28 OK CHECK completed"
"IMAPD" 2760 9 "2018-12-21 10:56:20.621" "{Thunder Bird Client A}" "RECEIVED: 29 getquotaroot "INBOX""
"IMAPD" 2760 9 "2018-12-21 10:56:20.621" "{Thunder Bird Client A}" "SENT: * QUOTAROOT "INBOX" ""[nl]* QUOTA "" ()[nl]29 OK GETQUOTAROOT completed"
"IMAPD" 4164 9 "2018-12-21 10:56:20.668" "{Thunder Bird Client A}" "RECEIVED: 30 UID fetch 1:* (FLAGS)"
"IMAPD" 4164 9 "2018-12-21 10:56:20.668" "{Thunder Bird Client A}" "SENT: * 1 FETCH (UID 535 FLAGS ())"
"IMAPD" 4164 9 "2018-12-21 10:56:20.668" "{Thunder Bird Client A}" "SENT: 30 OK UID completed"
"IMAPD" 592 9 "2018-12-21 10:56:20.762" "{Thunder Bird Client A}" "RECEIVED: 31 UID fetch 535 (UID RFC822.SIZE FLAGS BODY.PEEK[HEADER.FIELDS (From To Cc Bcc Subject Date Message-ID Priority X-Priority References Newsgroups In-Reply-To Content-Type Reply-To)])"
"IMAPD" 592 9 "2018-12-21 10:56:20.762" "{Thunder Bird Client A}" "SENT: * 1 FETCH (UID 535 RFC822.SIZE 2291 FLAGS () BODY[HEADER.FIELDS (From To Cc Bcc Subject Date Message-ID Priority X-Priority References Newsgroups In-Reply-To Content-Type Reply-To)] {342}"
"IMAPD" 592 9 "2018-12-21 10:56:20.762" "{Thunder Bird Client A}" "SENT: )"
"IMAPD" 592 9 "2018-12-21 10:56:20.762" "{Thunder Bird Client A}" "SENT: 31 OK UID completed"
"IMAPD" 2760 9 "2018-12-21 10:56:20.949" "{Thunder Bird Client A}" "RECEIVED: 32 UID fetch 535 (UID RFC822.SIZE BODY.PEEK[])"
"IMAPD" 2760 9 "2018-12-21 10:56:20.949" "{Thunder Bird Client A}" "SENT: * 1 FETCH (UID 535 RFC822.SIZE 2291 BODY[] {2332}"
"IMAPD" 2760 9 "2018-12-21 10:56:20.949" "{Thunder Bird Client A}" "SENT: )"
"IMAPD" 2760 9 "2018-12-21 10:56:20.949" "{Thunder Bird Client A}" "SENT: 32 OK UID completed"
"IMAPD" 4164 9 "2018-12-21 10:56:23.183" "{Thunder Bird Client A}" "RECEIVED: 33 UID fetch 535 (UID BODY.PEEK[HEADER.FIELDS (Content-Type Content-Transfer-Encoding)] BODY.PEEK[TEXT]<0.2048>)"
"IMAPD" 4164 9 "2018-12-21 10:56:23.183" "{Thunder Bird Client A}" "SENT: * 1 FETCH (UID 535 BODY[HEADER.FIELDS (Content-Type Content-Transfer-Encoding)] {80}"
"IMAPD" 4164 9 "2018-12-21 10:56:23.183" "{Thunder Bird Client A}" "SENT: BODY[TEXT]<0> {1002}"
"IMAPD" 4164 9 "2018-12-21 10:56:23.183" "{Thunder Bird Client A}" "SENT: )"
"IMAPD" 4164 9 "2018-12-21 10:56:23.183" "{Thunder Bird Client A}" "SENT: 33 OK UID completed"
"IMAPD" 1672 9 "2018-12-21 10:56:23.308" "{Thunder Bird Client A}" "RECEIVED: 34 IDLE"
"IMAPD" 1672 9 "2018-12-21 10:56:23.308" "{Thunder Bird Client A}" "SENT: + idling"

The email sends from outside domain seems to pass over saving the email messages.

I also read another post and give the HMSSettingsDiagnostics a try.

here is the configuration:

Code: Select all

2018-12-21   Hmailserver: 5.6.4-B2283

DOMAINS

   "Domain1.com" - maxxx.spxxxxxxxxx.com          Enabled: True
      |- "Alias1.com" - spxxxxxxxxx.com

SIGNATURE         LIMITS                       DKIM               ADVANCED
  Enabled: False   Max size:                0   Enabled: False   
                   Max message size:        0                      Plus addressing: False
                   Max size of accounts:    0                    
                                                                   Greylisting:     False
-----------------------------------------------------------------------------------------------

IP RANGES

IP: 127.0.0.1 - 127.0.0.1     Priority: 20     Name: My computer

  Allow connections                         Other
     SMTP:   True                              Antispam :   True !! 'Spam tests' not enabled !!
     POP3:  False                              Antivirus:   True !! ANTIVIRUS NOT CONFIGURED !!
     IMAP:  False                              SSL/TLS:    False

  Allow Deliveries from                     Require Authentication from
     Local To Local       -  True              Local To Local       -  True
     Local To External    -  True              Local To External    -  True
     External To Local    -  True              External To Local    - False
     External To External -  True              External To External -  True


IP: 0.0.0.0 - 255.255.255.255     Priority: 10     Name: Internet

  Allow connections                         Other
     SMTP:   True                              Antispam :   True !! 'Spam tests' not enabled !!
     POP3:   True                              Antivirus:   True !! ANTIVIRUS NOT CONFIGURED !!
     IMAP:   True                              SSL/TLS:    False

  Allow Deliveries from                     Require Authentication from
     Local To Local       -  True              Local To Local       -  True
     Local To External    -  True              Local To External    -  True
     External To Local    -  True              External To Local    - False
     External To External - False           


   !!  Warning:  DEFAULT DOMAIN is SET  !! - "Domain1.com"
------------------------------------------------------
AUTOBANNED Local Addresses:
    No entries

-----------------------------------------------------------------------------------------------

AUTOBAN
  Autoban Enabled: False

No problems were found in the IP range configuration.
-----------------------------------------------------------------------------------------------

INCOMING RELAYS
   No entries
-----------------------------------------------------------------------------------------------

MIRRORING         Disabled
-----------------------------------------------------------------------------------------------

PROTOCOLS

SMTP
GENERAL             DELIVERY                  RFC COMPLIANCE            ADVANCED
No. Connections:  0  No Retries:  4 Mins: 60   Plain Text:         True  Bind: 
                     Host: Domain1.com         Empty sender:       True  Batch recipients:    30
Max Msg Size: 20480  Relay:-                   Incorrect endings:  True  Use STARTTLS:      True
                     (none entered)            Disc. on invalid:   True  Delivered-To hdr: False
                                               Max number commands: 100  Loop limit:           5
                                                                         Recipient hosts:     15
  Routes:
     No routes defined.

POP3
  No. Connections: 0

IMAP
 GENERAL                   PUBLIC FOLDERS                    ADVANCED
  No. Connections:   0      Public folder name: #Public       IMAP sort:  True
                                                              IMAP Quota: True
                                                              IMAP Idle:  True
                                                              IMAP ACL:   True
                                                              Delim: "."
-----------------------------------------------------------------------------------------------

ANTISPAM

GENERAL                              SPAM TESTS              Score   SPAMASSASSIN
  Spam Mark:                  5       Use SPF:           False        Use Spamassassin:   False
  Add X-HmailServer-Spam:     True    Check HELO host:   False    
  Add X-HmailServer-Reason:   True    Check MX records:  False    
  Add X-HmailServer-Subject:  True    Verify DKIM:       False    
              Subject Text: "[SPAM]"
  Spam delete threshold: 20         Maximum message size: 1024

DNSBL ENTRIES:
   No 'enabled' entries

SURBL ENTRIES:
   No 'enabled' entries

GREYLISTING:
  Greylisting:  False

WHITELISTING
   No entries
-----------------------------------------------------------------------------------------------

ANTIVIRUS:  No application configured.

  Block Attachments: False
-----------------------------------------------------------------------------------------------

SSL CERTIFICATES
   No entries
-----------------------------------------------------------------------------------------------

SSL/TLS
             SSL 3.0 :  False
             TLS 1.0 :   True
             TLS 1.1 :   True
             TLS 1.2 :   True                Verify Remote SSL/TLS Certs:   True
SslCipherList  :

ECDHE-RSA-AES128-GCM-SHA256     - ECDHE-ECDSA-AES128-GCM-SHA256   - ECDHE-RSA-AES256-GCM-SHA384     
ECDHE-ECDSA-AES256-GCM-SHA384   - DHE-RSA-AES128-GCM-SHA256       - DHE-DSS-AES128-GCM-SHA256       
kEDH+AESGCM                     - ECDHE-RSA-AES128-SHA256         - ECDHE-ECDSA-AES128-SHA256       
ECDHE-RSA-AES128-SHA            - ECDHE-ECDSA-AES128-SHA          - ECDHE-RSA-AES256-SHA384         
ECDHE-ECDSA-AES256-SHA384       - ECDHE-RSA-AES256-SHA            - ECDHE-ECDSA-AES256-SHA          
DHE-RSA-AES128-SHA256           - DHE-RSA-AES128-SHA              - DHE-DSS-AES128-SHA256           
DHE-RSA-AES256-SHA256           - DHE-DSS-AES256-SHA              - DHE-RSA-AES256-SHA              
AES128-GCM-SHA256               - AES256-GCM-SHA384               - ECDHE-RSA-RC4-SHA               
ECDHE-ECDSA-RC4-SHA             - AES128                          - AES256                          
RC4-SHA                         - HIGH                            - !aNULL                          
!eNULL                          - !EXPORT                         - !DES                            
!3DES                           - !MD5                            - !PSK;                           
-----------------------------------------------------------------------------------------------

TCPIP PORTS                                         Connection Sec
               0.0.0.0         / 25    / SMTP   -   None                
               0.0.0.0         / 110   / POP3   -   None                
               0.0.0.0         / 143   / IMAP   -   None                
               0.0.0.0         / 465   / SMTP   -   None                
               0.0.0.0         / 587   / SMTP   -   None                
               0.0.0.0         / 993   / IMAP   -   None                
               0.0.0.0         / 995   / POP3   -   None                
-----------------------------------------------------------------------------------------------

LOGGING      Logging Enabled: True

  Paths:-
    Current:  C:\Program Files (x86)\hMailServer\Logs\hmailserver_2018-12-21.log
    Error:    C:\Program Files (x86)\hMailServer\Logs\ERROR_hmailserver_2018-12-21.log - !! ERRORS PRESENT !!
    Event:    C:\Program Files (x86)\hMailServer\Logs\hmailserver_events.log - Not present
    Awstats:  C:\Program Files (x86)\hMailServer\Logs\hmailserver_awstats.log
                        APPLICATION -    True
                        SMTP        -    True
                        POP3        -    True
                        IMAP        -    True
                        TCPIP       -    True
                        DEBUG       -    True
                        AWSTATS     -    True
-----------------------------------------------------------------------------------------------

SYSTEM TESTS

Database type: MySQL

IPv6 support is available in operating system.

Backup directory C:\Server\Mail is writable.

Relative message paths are stored in the database for all messages.

-----------------------------------------------------------------------------------------------

HMAILSERVER.INI

[Directories]
Program folder:  C:\Program Files (x86)\hMailServer\
Database folder: 
Data folder:     C:\Program Files (x86)\hMailServer\Data
Log folder:      C:\Program Files (x86)\hMailServer\Logs
Temp folder:     C:\Program Files (x86)\hMailServer\Temp
Event folder:    C:\Program Files (x86)\hMailServer\Events

[Database]
Type=              MYSQL
Username=          hmailserver
PasswordEncryption=1
Port=              3306
Server=            localhost
Internal=          0
-----------------------------------------------------------------------------------------------

Generated by HMSSettingsDiagnostics v1.95, Hmailserver Forum.

the Content of ERROR_hmailserver_2018-12-21.log is :
"ERROR" 4684 "2018-12-21 09:28:04.505" "Severity: 3 (Medium), Code: HM5026, Source: PersistentMessage::_WriteDataToMessageFile, Description: Message retrieval failed because message file C:\Program Files (x86)\hMailServer\Data\{local mail server domain}\eason\17\{1748D868-A015-4D62-A670-2B0F42E8F160}.eml did not exist."
"ERROR" 4684 "2018-12-21 09:28:04.567" "Severity: 3 (Medium), Code: HM5026, Source: PersistentMessage::_WriteDataToMessageFile, Description: Message retrieval failed because message file C:\Program Files (x86)\hMailServer\Data\{local mail server domain}\eason\39\{39FB1583-28E2-454F-A72A-B7C1BB81A6F7}.eml did not exist."
"ERROR" 4684 "2018-12-21 09:28:04.583" "Severity: 3 (Medium), Code: HM5026, Source: PersistentMessage::_WriteDataToMessageFile, Description: Message retrieval failed because message file C:\Program Files (x86)\hMailServer\Data\{local mail server domain}\eason\43\{43888A0D-AAF6-4929-8D5A-20001BCB0853}.eml did not exist."

which occurs before I send a test email from Gmail.

Many thanks for you guys, and wish I can found a solution for that.

User avatar
mattg
Moderator
Moderator
Posts: 20228
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: IMAP doesn't sync email from the external domain.

Post by mattg » 2018-12-21 06:16

internetms52 wrote:
2018-12-21 05:19
As you can see, it is no any error message between Welcome message and SMTPD SENT 354, but it's different with the email sending from previous server.
The email sends from outside domain seems to pass over saving the email messages.

...

I also read another post and give the HMSSettingsDiagnostics a try.
I can't see that
The first log snippets were incomplete, and show two connections to the 'OK Send'

The second snippet shows full acceptance and download of the message, and then an IMAP client seeing and downloading that message.
I don't see any errors

The errors that you show from the error log are from hours before


Do you have Microsoft Defender on that machine?
Exclude the data directory please
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

internetms52
New user
New user
Posts: 6
Joined: 2018-12-19 03:50

Re: IMAP doesn't sync email from the external domain.

Post by internetms52 » 2018-12-25 03:38

Thank you for your suggestion.

I am pretty sure that Hmail service has full control of the data folder.
the reason is, when i send email from my previous fully functional email server, it won't happen.
it only happens when I try sending email from the other email server(which may probably not build by "Hmailserver").
it's like Hmail service stuck on processing received email.
I can't move or delete those 0KB files until the process is over.

just like something timeout retry mechanism, the process starts to receive the mail and failed to get the connection with something, and then keep trying until the retry countdown is over, then "hmailserver" will remove the 0KB file, even the transfer is not successful.

I've fixed the MX records and DMARC and SPF, and I got all green from hMailServer diagnostics.

I will try to monitor packages, see what kind of connection the "hmailserver" needed while receive mail.

internetms52
New user
New user
Posts: 6
Joined: 2018-12-19 03:50

Re: IMAP doesn't sync email from the external domain.

Post by internetms52 » 2018-12-25 11:40

the problem solved.
SMTP package from Gmail can't get the response from Mail Server.
It's a problem with our new network environment, so when I send from the previous domain, the previous domain environment can accept MTU 1500 and didn't set the DF flag, packages will safety transferred to the new domain server.
While I send an email from Gmail, the router device in the middle said if you want to transfer packaged to google you have to change MTU below 1400.
so I have to change the MTU setting from windows server 2008 R2, and it worked.

the 0KB file is currently waiting for additional information because the Gmail server won't get any SMTP request from the new domain, so the file been created but still waiting data, I guess.

overall, thanks for mattg give me a very quick reply to every question, and since this is not really a hmailserver problem sorry for bothering you guys.

User avatar
Dravion
Senior user
Senior user
Posts: 1467
Joined: 2015-09-26 11:50
Location: Germany
Contact:

Re: IMAP doesn't sync email from the external domain.

Post by Dravion » 2018-12-25 13:04

Good Job.
Yeah, MTU Stuff can be verry nasty.

I had it a few years back. Firefox wasnt able to send any HTML Formular and took forever. After incrementing the MTU value, it was gone.

Merry XMass

Post Reply