Unable to save email domain or email

Hello,
I have installed erpnext production version v12.6.0. The app runs but when I try to create or edit email domain the screen greys out for more than a minute and the nothing saves. The same is with creating just email account.


The browser console does show:

jquery.min.js:4 POST https://erp.suncab.cz/api/method/frappe.desk.form.save.savedocs 504 (Gateway Time-out)

The mail server responds well I supose:
nc -vv mail.hukot.net 993
Connection to mail-hukot-net 993 port [tcp/imaps] succeeded!
nc -vv mail.hukot.net 465
Connection to mail-hukot-net 465 port [tcp/urd] succeeded!

I looked in the logs in frappe-bench/logs/ and did not found anything about.
So I will apreaciate any guidance or help to find where the problem is coming from.

In Settings, Core - is there anything in that Error Log?
Have you tried bench enable-scheduler , in a terminal ?

There is no log in settings Core. If I try to create one it appears an empty page.


The bench enable-sheduler says:

bench enable-scheduler
Enabled for site1.local

In the frappe.log are some errors:

~/frappe-bench/logs$ cat bench.log
2020-03-24 21:07:03,219 INFO Getting app erpnext
2020-03-24 21:07:12,132 INFO installing erpnext
erp-frappe@erp:~/frappe-bench/logs$ cat frappe.log

[DEBUG] 2020-03-25 08:30:54,363 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:31:54,476 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:32:54,614 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:33:54,725 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:34:56,789 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:35:56,901 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:36:57,040 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[ERROR] 2020-03-25 08:37:43,177 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/app.py:
Site: site1.local
Form Dict: {
 "cmd": "frappe.desk.reportview.get"
}
Request Error
Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/app.py", line 62, in ap                                                                                                                                                                                          plication
    response = frappe.api.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/api.py", line 55, in ha                                                                                                                                                                                          ndle
    return frappe.handler.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 22, i                                                                                                                                                                                          n handle
    data = execute_cmd(cmd)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 61, i                                                                                                                                                                                          n execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 1054                                                                                                                                                                                          , in call
    return fn(*args, **newargs)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 527,                                                                                                                                                                                           in wrapper_fn
    retval = fn(*args, **get_newargs(fn, kwargs))
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", li                                                                                                                                                                                          ne 20, in get
    args = get_form_params()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", li                                                                                                                                                                                          ne 54, in get_form_params
    fields = data["fields"]
KeyError: 'fields'
[ERROR] 2020-03-25 08:37:43,285 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/error.py:
Could not take error snapshot: invalid syntax (, line 1)
Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/app.py", line 62, in ap                                                                                                                                                                                          plication
    response = frappe.api.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/api.py", line 55, in ha                                                                                                                                                                                          ndle
    return frappe.handler.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 22, i                                                                                                                                                                                          n handle
    data = execute_cmd(cmd)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 61, i                                                                                                                                                                                          n execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 1054                                                                                                                                                                                          , in call
    return fn(*args, **newargs)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 527,                                                                                                                                                                                           in wrapper_fn
    retval = fn(*args, **get_newargs(fn, kwargs))
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", li                                                                                                                                                                                          ne 20, in get
    args = get_form_params()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", li                                                                                                                                                                                          ne 54, in get_form_params
    fields = data["fields"]
KeyError: 'fields'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/error.py", line 3                                                                                                                                                                                          6, in make_error_snapshot
    snapshot = get_snapshot(exception)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/error.py", line 1                                                                                                                                                                                          32, in get_snapshot
    value = eval(value)
  File "", line 1
    
    ^
SyntaxError: invalid syntax
[DEBUG] 2020-03-25 08:38:28,256 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:39:28,366 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:40:30,110 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:41:30,213 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:42:31,134 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:43:31,236 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:44:31,362 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:45:31,484 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:46:31,605 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:47:31,707 | /home/erp-frappe/frappe-bench/apps/frappe/frap                                                                                                                                                                                          pe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
erp-frappe@erp:~/frappe-bench/logs$ cat frappe.log
[DEBUG] 2020-03-25 07:58:44,154 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local

[DEBUG] 2020-03-25 08:17:52,109 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:18:52,222 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:19:52,327 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:20:52,479 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:21:52,592 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:22:52,699 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:23:52,810 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:24:52,963 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:25:53,070 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:26:53,211 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:27:53,312 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:28:53,440 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:29:54,248 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:30:54,363 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:31:54,476 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:32:54,614 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:33:54,725 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:34:56,789 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:35:56,901 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:36:57,040 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[ERROR] 2020-03-25 08:37:43,177 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/app.py:
Site: site1.local
Form Dict: {
 "cmd": "frappe.desk.reportview.get"
}
Request Error
Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/app.py", line 62, in application
    response = frappe.api.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/api.py", line 55, in handle
    return frappe.handler.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 22, in handle
    data = execute_cmd(cmd)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 61, in execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 1054, in call
    return fn(*args, **newargs)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 527, in wrapper_fn
    retval = fn(*args, **get_newargs(fn, kwargs))
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", line 20, in get
    args = get_form_params()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", line 54, in get_form_params
    fields = data["fields"]
KeyError: 'fields'
[ERROR] 2020-03-25 08:37:43,285 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/error.py:
Could not take error snapshot: invalid syntax (, line 1)
Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/app.py", line 62, in application
    response = frappe.api.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/api.py", line 55, in handle
    return frappe.handler.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 22, in handle
    data = execute_cmd(cmd)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 61, in execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 1054, in call
    return fn(*args, **newargs)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 527, in wrapper_fn
    retval = fn(*args, **get_newargs(fn, kwargs))
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", line 20, in get
    args = get_form_params()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", line 54, in get_form_params
    fields = data["fields"]
KeyError: 'fields'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/error.py", line 36, in make_error_snapshot
    snapshot = get_snapshot(exception)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/error.py", line 132, in get_snapshot
    value = eval(value)
  File "", line 1
    
    ^
SyntaxError: invalid syntax
[DEBUG] 2020-03-25 08:38:28,256 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local

Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:05:48,990 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local

[DEBUG] 2020-03-25 08:11:51,234 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:12:51,373 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local

[DEBUG] 2020-03-25 08:33:54,725 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:34:56,789 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:35:56,901 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:36:57,040 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[ERROR] 2020-03-25 08:37:43,177 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/app.py:
Site: site1.local
Form Dict: {
 "cmd": "frappe.desk.reportview.get"
}
Request Error
Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/app.py", line 62, in application
    response = frappe.api.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/api.py", line 55, in handle
    return frappe.handler.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 22, in handle
    data = execute_cmd(cmd)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 61, in execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 1054, in call
    return fn(*args, **newargs)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 527, in wrapper_fn
    retval = fn(*args, **get_newargs(fn, kwargs))
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", line 20, in get
    args = get_form_params()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", line 54, in get_form_params
    fields = data["fields"]
KeyError: 'fields'
[ERROR] 2020-03-25 08:37:43,285 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/error.py:
Could not take error snapshot: invalid syntax (, line 1)
Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/app.py", line 62, in application
    response = frappe.api.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/api.py", line 55, in handle
    return frappe.handler.handle()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 22, in handle
    data = execute_cmd(cmd)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/handler.py", line 61, in execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 1054, in call
    return fn(*args, **newargs)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 527, in wrapper_fn
    retval = fn(*args, **get_newargs(fn, kwargs))
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", line 20, in get
    args = get_form_params()
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/desk/reportview.py", line 54, in get_form_params
    fields = data["fields"]
KeyError: 'fields'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/error.py", line 36, in make_error_snapshot
    snapshot = get_snapshot(exception)
  File "/home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/error.py", line 132, in get_snapshot
    value = eval(value)
  File "", line 1
    
    ^
SyntaxError: invalid syntax
[DEBUG] 2020-03-25 08:38:28,256 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:39:28,366 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:40:30,110 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local
Queued events for site site1.local
[DEBUG] 2020-03-25 08:41:30,213 | /home/erp-frappe/frappe-bench/apps/frappe/frappe/utils/scheduler.py:
Site: site1.local

Can you say the operating system, and how ERPNext was installed ? The lack of Error Log in Settings core is odd. If there was an authentication problem when setting up the email account I think the log would catch it.

I am using VPS with Ubuntu Server 18.04 LTS with all updated. For the installation I have used Easy install script for production. The strange think is that if I leave account@example.com and I press save it does say that the incoming email account is wrong. So it does some stuff when I press save, but when I write the working account it does stay grayed.

It looks like that the problem rise up when I check tls for outgoing emails. With diferent providers it does the same. If I don’t check that box it saves the settings.

The same problem here some time ago. I can’t recall if it was an authentication problem or something to do with the login email not agreeing with the account email domain. I’m only using SMTP . Can you post a screenshot of the email domain settings?

This does not work:


If I uncheck tls it does save.

For smtp try port 587 , and try sending a document, a purchase order for example, and see if the error log catches anything.

If I change the port to 587 or any different than the 465 that is specified by the mail provider the error “Outgoing email account not correct” jumps out.

Try changing the example email address domain to the same as the one for the address of the user.

I did try, nothing changes. Other interesting thing is that if I leave it without tls and try send email from the system a log appears in the System settings logs. That looks that is probably some problem with the ssl tls test. I tried a bitnami stack on aws and had the same problem.
DOn’t you know where could I see how the validation process proceeds?

Can you install a mail client on the host and try your credentials from that? See if anything here can be used to help debug - https://frappe.io/docs/user/en/debugging

Works well

echo "This is the message body" | swaks --to ondrej.blazik@gmail.com --from "ondrej@suncab.cz" --server mail.hukot.net --auth LOGIN --auth-user "ondrej@suncab.cz" --auth-password "somepassword" -tls
=== Trying mail.hukot.net:25...
=== Connected to mail.hukot.net.
<-  220 Hukot.cz (mail.hukot.net) ESMTP
 -> EHLO erp.suncab.cz
<-  250-mail.hukot.net
<-  250-PIPELINING
<-  250-SIZE 157286400
<-  250-VRFY
<-  250-ETRN
<-  250-STARTTLS
<-  250-AUTH PLAIN LOGIN
<-  250-AUTH=PLAIN LOGIN
<-  250-ENHANCEDSTATUSCODES
<-  250 8BITMIME
 -> STARTTLS
<-  220 2.0.0 Ready to start TLS
=== TLS started with cipher TLSv1.2:DHE-RSA-AES256-GCM-SHA384:256
=== TLS no local certificate set
=== TLS peer DN="/CN=*.hukot.net"
 ~> EHLO erp.suncab.cz
<~  250-mail.hukot.net
<~  250-PIPELINING
<~  250-SIZE 157286400
<~  250-VRFY
<~  250-ETRN
<~  250-AUTH PLAIN LOGIN
<~  250-AUTH=PLAIN LOGIN
<~  250-ENHANCEDSTATUSCODES
<~  250 8BITMIME
 ~> AUTH LOGIN
<~  334 VXNlcm5hbWU6
 ~> b25kcmVqQHN1bmNhYi5jeg==
<~  334 UGFzc3dvcmQ6
 ~> Qk5WSjV5dnVxMXVVVE83clp3Z1k=
<~  235 2.7.0 Authentication successful
 ~> MAIL FROM:
<~  250 2.1.0 Ok
 ~> RCPT TO:
<~  250 2.1.5 Ok
 ~> DATA
<~  354 End data with .
 ~> Date: Thu, 26 Mar 2020 21:12:13 +0100
 ~> To: ondrej.blazik@gmail.com
 ~> From: ondrej@suncab.cz
 ~> Subject: test Thu, 26 Mar 2020 21:12:13 +0100
 ~> Message-Id: <20200326211213.005780@erp.suncab.cz>
 ~> X-Mailer: swaks v20170101.0 jetmore.org/john/code/swaks/
 ~>
 ~> This is a test mailing
 ~>
 ~> .
<~  250 2.0.0 Ok: queued as 5602EF214C
 ~> QUIT
<~  221 2.0.0 Bye
=== Connection closed with remote host.

Now I will try more debugging

I found that I just needed to use port 25.
It’s my fault I did not realized that erpnext is using STARTTLS.

My provider uses port 465 for SSL/TLS and port 25 for unsafe connections and STARTTLS.
Yes it’s true that not saying nothing even in the logs about what is the problem is weird but not that much.

Perfect… thanks for your great help.

3 Likes

Exactly same happens. Disabling SSL/TLS solves the issue. Strange bug

bro i have the same problem can you just share the configurations for email domain