ubuntuusers.de

Dovecot Verbindung schlägt fehl

Status: Ungelöst | Ubuntu-Version: Xubuntu 24.04 (Noble Numbat)
Antworten |

glaskugel

Anmeldungsdatum:
8. Juli 2010

Beiträge: 3612

Ich helfe jemanden bei der Einreichtung von dovecot.

Bei mir:

$ openssl s_client -connect 192.168.178.33:993
C...
read R BLOCK
* OK [CAPABILITY IMAP4rev1 SASL-IR LOGIN-REFERRALS ID ENABLE IDLE LITERAL+ AUTH=PLAIN] Dovecot (Ubuntu) ready.

Bei mir funktioniert auch alles rund um Mails und IMAP.

Bei ihm:

openssl s_client -connect 192.168.178.100:993
4---0:error:8000006F:system library:BIO_connect:Connection refused:../crypto/bio/bio_sock2.c:114:calling connect()
4---0:error:10000067:BIO routines:BIO_connect:connect error:../crypto/bio/bio_sock2.c:116:
connect:errno=111

Ich weiß jetzt nicht, ob mittlerweile ein Selbstzertifikat notwendig ist, hat er sicher nicht gemacht. Ich erinnere mich nicht mehr, was ich dich diesbzgl. gemacht habe.

/etc/dovecot/conf.d/10-mail.conf

mail_location = maildir:~/Maildir
namespace inbox {
  inbox = yes
}
mail_privileged_group = mail
protocol !indexer-worker {
}

Braucht ihr weitere Informationen?

DJKUhpisse Team-Icon

Supporter, Wikiteam
Avatar von DJKUhpisse

Anmeldungsdatum:
18. Oktober 2016

Beiträge: 18180

Wohnort: in deinem Browser, hier auf dem Bildschirm

Schaue mit Wireshark, was bei ihm ankommt (TCP RST oder ICMP etc.). Mit dem Zertifikat hat das Wohl nix zu tun.

sebix Team-Icon

Moderator, Webteam

Anmeldungsdatum:
14. April 2009

Beiträge: 5559

glaskugel schrieb:

openssl s_client -connect 192.168.178.100:993
4---0:error:8000006F:system library:BIO_connect:Connection refused:../crypto/bio/bio_sock2.c:114:calling connect()
4---0:error:10000067:BIO routines:BIO_connect:connect error:../crypto/bio/bio_sock2.c:116:
connect:errno=111

Connection refused → Da ist kein Port offen.

glaskugel

(Themenstarter)

Anmeldungsdatum:
8. Juli 2010

Beiträge: 3612

Ergänzend, Server und Mailclient ist derselbe PC.

In Stufe 1 geht es nur mal darum, dass es grundsätzlich funktioniert. Zugriffe von anderen Clients auf den lokalen (!) IMAP-Server sind ein 2. Schritt. Es geht auch nur um Zugriffe aus dem lokalen Netz.

Schaue mit Wireshark, was bei ihm ankommt (TCP RST oder ICMP etc.).

Mein Freund ist bei schwierigen Dingen nur in der Lage Befehle auszuführen, die ich vorgebe. Kannst du einen Befehl vorschlagen?

Mit dem Zertifikat hat das Wohl nix zu tun.

Vielleicht geht da noch was ab. Ich habe bei meinen Aufzeichnungen was verwechselt und habe nicht mehr alles. Ich erinnere mich nur mehr dumpf, dass ich bei irgendeiner dovecot-Anleitung was fand, wo ich mir dachte, wenn man das nicht weiß, steht man an.

Connection refused → Da ist kein Port offen.

Immer nur 1 PC, irgendwas falsch konfiguriert? Aber viel kann man bei dovecot nicht konfigurieren, siehe oben.

Kann auf diesem Level eine falsche Postfix-Konfiguration schon wirken?

Ich habe bei mir die Postfix-Konfiguration von 22.04 verwendet, hat bei mir sofort funktioniert. Er sollte es genauso gemacht haben, weiß natürlich nicht, ob ein Fehler passiert ist. Ich bin nicht vor Ort und helfe nur über Telefon.

Ich klär jetzt mal ab, ob alle Pakete installiert sind. Bei mir:

~$ dpkg -l | grep dove
ii  dovecot-core                                   1:2.3.21+dfsg1-2ubuntu6                       amd64        secure POP3/IMAP server - core files
ii  dovecot-imapd                                  1:2.3.21+dfsg1-2ubuntu6                       amd64        secure POP3/IMAP server - IMAP daemon
ii  dovecot-managesieved                           1:2.3.21+dfsg1-2ubuntu6                       amd64        secure POP3/IMAP server - ManageSieve server
ii  dovecot-pop3d                                  1:2.3.21+dfsg1-2ubuntu6                       amd64        secure POP3/IMAP server - POP3 daemon
ii  dovecot-sieve                                  1:2.3.21+dfsg1-2ubuntu6                       amd64        secure POP3/IMAP server - Sieve filters support

sebix Team-Icon

Moderator, Webteam

Anmeldungsdatum:
14. April 2009

Beiträge: 5559

glaskugel schrieb:

Immer nur 1 PC, irgendwas falsch konfiguriert?

Ja. Dovecot lauscht nicht. Jedenfalls nicht auf dem Port.

Aber viel kann man bei dovecot nicht konfigurieren, siehe oben.

Doch, sehr viel.

Kann auf diesem Level eine falsche Postfix-Konfiguration schon wirken?

Nein.

Um hier irgendwie zu helfen, brauchen wir mehr Infos. zB sudo systemctl status dovecot.service, die Konfiguration (inbesondere die des Ports), oder ss -tlpn etc.

glaskugel

(Themenstarter)

Anmeldungsdatum:
8. Juli 2010

Beiträge: 3612

Um hier irgendwie zu helfen, brauchen wir mehr Infos. zB sudo systemctl status dovecot.service, die Konfiguration (inbesondere die des Ports), oder ss -tlpn etc.

Gerne, muss das immer nur verständlich per Telefon meinem Freund erklären.

Aber viel kann man bei dovecot nicht konfigurieren, siehe oben.

Doch, sehr viel.

Ich bezog mich auf die Standstard-Konfiguratio nach der Installation. Bei mir ist alles default bis auf:

mail_location = maildir:~/Maildir

Siehe /etc/dovecot/conf.d/10-mail.conf eingangs.

Also die installierten Pakete sind bei mir und ihm ident.

Ich poste das jetzt wie ich es erhalten habe:

nmap scan localhost
Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-03-24 22:16 CET
Failed to resolve "scan".
Nmap scan report for localhost (127.0.0.1)
Host is up (0.00013s latency).
Not shown: 984 closed tcp ports (conn-refused)
PORT      STATE SERVICE
22/tcp    open  ssh
25/tcp    open  smtp
80/tcp    open  http
110/tcp   open  pop3
111/tcp   open  rpcbind
143/tcp   open  imap
631/tcp   open  ipp
783/tcp   open  spamassassin
993/tcp   open  imaps
995/tcp   open  pop3s
2049/tcp  open  nfs
4242/tcp  open  vrml-multi-use
8042/tcp  open  fs-agent
8200/tcp  open  trivnet1
9050/tcp  open  tor-socks
10024/tcp open  unknown

Nmap done: 1 IP address (1 host up) scanned in 0.07 seconds

Aber:

nmap scan 192.168.178.100
Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-03-24 22:17 CET
Failed to resolve "scan".
Nmap scan report for ccu3-webui.fritz.box (192.168.178.100)
Host is up (0.0031s latency).
Not shown: 991 closed tcp ports (conn-refused)
PORT     STATE SERVICE
22/tcp   open  ssh
80/tcp   open  http
443/tcp  open  https
1999/tcp open  tcp-id-port
2000/tcp open  cisco-sccp
2001/tcp open  dc
2010/tcp open  search
8181/tcp open  intermapper
8701/tcp open  unknown

Nmap done: 1 IP address (1 host up) scanned in 0.08 seconds

Woher da jetzt ccu3 kommt? Sein Rechner heißt "server". Die IP des PCs stimmt. Muss mal fragen was die CCU3 für IP hat.

Ich schätze mal Antwort frühestens morgen Abend, habe ihn hartnäckig schon aus dem Bett geholt 😉 2 Geräte mit gleicher IP wären natürlich schlimm. Prüfen wir!

sebix Team-Icon

Moderator, Webteam

Anmeldungsdatum:
14. April 2009

Beiträge: 5559

glaskugel schrieb:

Die IP des PCs stimmt.

Unter der Annahme, dass die Aussage stimmt: Dann lauscht dovecot nicht auf dieser IP-Adresse, sondern auf localhost. ss -tlpn haette diese Frage beantwortet. Ebenso die Konfiguration von dovecot, insbesondere die listen Direktive.

glaskugel

(Themenstarter)

Anmeldungsdatum:
8. Juli 2010

Beiträge: 3612

Bei mir ist:

[Bitte Ausgabe erweitern]

$ nmap 192.168.178.33
Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-03-24 22:35 CET
Nmap scan report for mailsv.local.iax2.eu.org (192.168.178.33)
Host is up (0.00018s latency).
Not shown: 988 closed tcp ports (conn-refused)
PORT     STATE SERVICE
22/tcp   open  ssh
80/tcp   open  http
110/tcp  open  pop3
111/tcp  open  rpcbind
143/tcp  open  imap
993/tcp  open  imaps
995/tcp  open  pop3s
2049/tcp open  nfs
4242/tcp open  vrml-multi-use
8042/tcp open  fs-agent
8080/tcp open  http-proxy
8200/tcp open  trivnet1
$ nmap localhost
Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-03-24 22:37 CET
Nmap scan report for localhost (127.0.0.1)
Host is up (0.00017s latency).
Not shown: 980 closed tcp ports (conn-refused)
PORT      STATE SERVICE
22/tcp    open  ssh
25/tcp    open  smtp
80/tcp    open  http
110/tcp   open  pop3
111/tcp   open  rpcbind
143/tcp   open  imap
631/tcp   open  ipp
783/tcp   open  spamassassin
993/tcp   open  imaps
995/tcp   open  pop3s
2049/tcp  open  nfs
3306/tcp  open  mysql
4242/tcp  open  vrml-multi-use
5432/tcp  open  postgresql
8042/tcp  open  fs-agent
8080/tcp  open  http-proxy
8200/tcp  open  trivnet1
9050/tcp  open  tor-socks
10024/tcp open  unknown
10025/tcp open  unknown

Nmap done: 1 IP address (1 host up) scanned in 0.08 seconds

Ich habe bei mir da nichts bzgl. Ports konfiguriert, es sind die Default-Ports bei dovecot.

Die gewünschten Abfragen kommen ASAP. Aber jetzt will ich mal wissen, ob die IP doppelt vergeben sind. Wenn da auf die CCU3 (Homematic Server) als Mailserver zugegriffen wird, dann wundert mich gar nichts.

Bei mir:

$ ss -tlpn
State     Recv-Q    Send-Q       Local Address:Port         Peer Address:Port    Process    
LISTEN    0         64                 0.0.0.0:2049              0.0.0.0:*                  
LISTEN    0         200              127.0.0.1:5432              0.0.0.0:*                  
LISTEN    0         64                 0.0.0.0:35883             0.0.0.0:*                  
LISTEN    0         511              127.0.0.1:6379              0.0.0.0:*                  
LISTEN    0         100                0.0.0.0:143               0.0.0.0:*                  
LISTEN    0         16                 0.0.0.0:8200              0.0.0.0:*                  
LISTEN    0         100                0.0.0.0:110               0.0.0.0:*                  
LISTEN    0         4096               0.0.0.0:111               0.0.0.0:*                  
LISTEN    0         100                0.0.0.0:993               0.0.0.0:*                  
LISTEN    0         100                0.0.0.0:995               0.0.0.0:*                  
LISTEN    0         4096               0.0.0.0:34011             0.0.0.0:*                  
LISTEN    0         4096               0.0.0.0:59325             0.0.0.0:*                  
LISTEN    0         100              127.0.0.1:25                0.0.0.0:*                  
LISTEN    0         4096             127.0.0.1:631               0.0.0.0:*                  
LISTEN    0         4096               0.0.0.0:39785             0.0.0.0:*                  
LISTEN    0         4096             127.0.0.1:783               0.0.0.0:*                  
LISTEN    0         4096             127.0.0.1:9050              0.0.0.0:*                  
LISTEN    0         4096             127.0.0.1:9392              0.0.0.0:*                  
LISTEN    0         200                0.0.0.0:8042              0.0.0.0:*                  
LISTEN    0         100              127.0.0.1:10025             0.0.0.0:*                  
LISTEN    0         4096             127.0.0.1:10024             0.0.0.0:*                  
LISTEN    0         100              127.0.0.1:1883              0.0.0.0:*                  
LISTEN    0         4096            127.0.0.54:53                0.0.0.0:*                  
LISTEN    0         50                 0.0.0.0:4242              0.0.0.0:*                  
LISTEN    0         100                0.0.0.0:4190              0.0.0.0:*                  
LISTEN    0         4096               0.0.0.0:38179             0.0.0.0:*                  
LISTEN    0         80               127.0.0.1:3306              0.0.0.0:*                  
LISTEN    0         4096         127.0.0.53%lo:53                0.0.0.0:*                  
LISTEN    0         64                    [::]:2049                 [::]:*                  
LISTEN    0         4096                  [::]:60683                [::]:*                  
LISTEN    0         511                  [::1]:6379                 [::]:*                  
LISTEN    0         100                   [::]:143                  [::]:*                  
LISTEN    0         4096                     *:22                      *:*                  
LISTEN    0         511                      *:80                      *:*                  
LISTEN    0         100                   [::]:110                  [::]:*                  
LISTEN    0         4096                  [::]:111                  [::]:*                  
LISTEN    0         100                   [::]:993                  [::]:*                  
LISTEN    0         100                   [::]:995                  [::]:*                  
LISTEN    0         4096                  [::]:40405                [::]:*                  
LISTEN    0         511                      *:8080                    *:*                  
LISTEN    0         4096                 [::1]:10024                [::]:*                  
LISTEN    0         64                    [::]:45473                [::]:*                  
LISTEN    0         100                  [::1]:1883                 [::]:*                  
LISTEN    0         100                   [::]:4190                 [::]:*                  
LISTEN    0         4096                 [::1]:783                  [::]:*                  
LISTEN    0         4096                  [::]:46265                [::]:*                  
LISTEN    0         4096                 [::1]:631                  [::]:*                  
LISTEN    0         4096                  [::]:47053                [::]:*                  
LISTEN    0         100                  [::1]:25                   [::]:*                  

Ebenso die Konfiguration von dovecot,

Bei mir, auskommentiertes wurde weggelassen.

/etc/dovecot/conf.d/10-mail.conf 

mail_location = maildir:~/Maildir
namespace inbox {
  inbox = yes
}
mail_privileged_group = mail
protocol !indexer-worker {
}

Ebenso die Konfiguration von dovecot, insbesondere die listen Direktive.

Ich weiß nicht genau was du meinst, bei mir ist alles default, bei ihm sicher auch.

Bei mir:

$ grep -r listen /etc/dovecot/conf.d/
/etc/dovecot/conf.d/10-director.conf:# what director service's inet_listener is using.
/etc/dovecot/conf.d/10-director.conf:  unix_listener login/director {
/etc/dovecot/conf.d/10-director.conf:  fifo_listener login/proxy-notify {
/etc/dovecot/conf.d/10-director.conf:  unix_listener director-userdb {
/etc/dovecot/conf.d/10-director.conf:  inet_listener {
/etc/dovecot/conf.d/10-master.conf:  inet_listener imap {
/etc/dovecot/conf.d/10-master.conf:  inet_listener imaps {
/etc/dovecot/conf.d/10-master.conf:  inet_listener pop3 {
/etc/dovecot/conf.d/10-master.conf:  inet_listener pop3s {
/etc/dovecot/conf.d/10-master.conf:  inet_listener submission {
/etc/dovecot/conf.d/10-master.conf:  inet_listener submissions {
/etc/dovecot/conf.d/10-master.conf:  unix_listener lmtp {
/etc/dovecot/conf.d/10-master.conf:  # Create inet listener only if you can't use the above UNIX socket
/etc/dovecot/conf.d/10-master.conf:  #inet_listener lmtp {
/etc/dovecot/conf.d/10-master.conf:  unix_listener auth-userdb {
/etc/dovecot/conf.d/10-master.conf:  #unix_listener /var/spool/postfix/private/auth {
/etc/dovecot/conf.d/10-master.conf:  unix_listener dict {
/etc/dovecot/conf.d/10-tcpwrapper.conf:# inet_listener in master.conf
/etc/dovecot/conf.d/10-tcpwrapper.conf:#  unix_listener login/tcpwrap {
/etc/dovecot/conf.d/90-quota.conf:# Example quota-warning service. The unix listener's permissions should be
/etc/dovecot/conf.d/90-quota.conf:#  unix_listener quota-warning {
/etc/dovecot/conf.d/90-sieve-extprograms.conf:  #unix_listener sieve-pipe/do-something {
/etc/dovecot/conf.d/20-managesieve.conf:  #inet_listener sieve {
/etc/dovecot/conf.d/20-managesieve.conf:  #inet_listener sieve_deprecated {

Bei mir:

root@mailsv:~# systemctl status dovecot.service
● dovecot.service - Dovecot IMAP/POP3 email server
     Loaded: loaded (/usr/lib/systemd/system/dovecot.service; enabled; preset: enabled)
     Active: active (running) since Mon 2025-03-24 22:13:20 CET; 43min ago
       Docs: man:dovecot(1)
             https://doc.dovecot.org/
   Main PID: 1913 (dovecot)
     Status: "v2.3.21 (47349e2482) running"
      Tasks: 5 (limit: 15375)
     Memory: 9.2M (peak: 14.8M)
        CPU: 309ms
     CGroup: /system.slice/dovecot.service
             ├─1913 /usr/sbin/dovecot -F
             ├─2059 dovecot/anvil
             ├─2061 dovecot/log
             ├─2065 dovecot/config
             └─3507 dovecot/stats

Mär 24 22:35:36 mailsv.local.*.*.org dovecot[2061]: imap-login: Disconnected: Connectio>
Mär 24 22:35:36 mailsv.local.*.*.org dovecot[2061]: pop3-login: Disconnected: Connectio>
Mär 24 22:37:07 mailsv.local.*.*.org dovecot[2061]: pop3-login: Disconnected: Connectio>
Mär 24 22:37:07 mailsv.local.*.*.org dovecot[2061]: imap-login: Disconnected: Connectio>
Mär 24 22:37:07 mailsv.local.*.*.org dovecot[2061]: pop3-login: Disconnected: Connectio>
Mär 24 22:37:07 mailsv.local.*.*.org dovecot[2061]: imap-login: Disconnected: Connectio>
Mär 24 22:37:22 mailsv.local.*.*.org dovecot[2061]: pop3-login: Disconnected: Connectio>
Mär 24 22:37:22 mailsv.local.*.*.org dovecot[2061]: imap-login: Disconnected: Connectio>
Mär 24 22:37:22 mailsv.local.*.*.org dovecot[2061]: imap-login: Disconnected: Connectio>
Mär 24 22:37:22 mailsv.local.*.*.org dovecot[2061]: pop3-login: Disconnected: Connectio>

Ausgaben von meinem Freund, bitte um Geduld.

glaskugel

(Themenstarter)

Anmeldungsdatum:
8. Juli 2010

Beiträge: 3612

Der Ubuntu-Server läuft nicht auf .100 sondern auf .120 und die Fritzbox vergab eine DHCP-Adresse im ausgeschlossenen DHCP-Bereich. Jedenfalls hat der Ubuntu-PC jetzt eine manuelle statische Adresse eingetragen.

Alles folgende ist von meinem Freund und nicht von mir.

Zum leichteren Vergleich nochmal:

$ nmap localhost
Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-03-25 21:28 CET
Nmap scan report for localhost (127.0.0.1)
Host is up (0.00011s latency).
Not shown: 984 closed tcp ports (conn-refused)
PORT      STATE SERVICE
22/tcp    open  ssh
25/tcp    open  smtp
80/tcp    open  http
110/tcp   open  pop3
111/tcp   open  rpcbind
143/tcp   open  imap
631/tcp   open  ipp
783/tcp   open  spamassassin
993/tcp   open  imaps
995/tcp   open  pop3s
2049/tcp  open  nfs
4242/tcp  open  vrml-multi-use
8042/tcp  open  fs-agent
8200/tcp  open  trivnet1
9050/tcp  open  tor-socks
10024/tcp open  unknown

Nmap done: 1 IP address (1 host up) scanned in 0.08 seconds

Jetzt mit richtiger IP-Adresse:

$ nmap 192.168.178.120
Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-03-25 21:20 CET
Nmap scan report for server.fritz.box (192.168.178.120)
Host is up (0.00014s latency).
Not shown: 989 closed tcp ports (conn-refused)
PORT     STATE SERVICE
22/tcp   open  ssh
80/tcp   open  http
110/tcp  open  pop3
111/tcp  open  rpcbind
143/tcp  open  imap
993/tcp  open  imaps
995/tcp  open  pop3s
2049/tcp open  nfs
4242/tcp open  vrml-multi-use
8042/tcp open  fs-agent
8200/tcp open  trivnet1

Noch immer mit richtiger IP-Adresse Fehler:

$ openssl s_client -connect 192.168.178.120
4077D2A67E7D0000:error:8000006F:system library:BIO_connect:Connection refused:../crypto/bio/bio_sock2.c:114:calling connect()
4077D2A67E7D0000:error:10000067:BIO routines:BIO_connect:connect error:../crypto/bio/bio_sock2.c:116:
connect:errno=111

Dump:

$ ss -tlpn
State    Recv-Q   Send-Q     Local Address:Port      Peer Address:Port  Process   
LISTEN   0        64               0.0.0.0:2049           0.0.0.0:*               
LISTEN   0        64               0.0.0.0:43245          0.0.0.0:*               
LISTEN   0        4096          127.0.0.54:53             0.0.0.0:*               
LISTEN   0        100              0.0.0.0:110            0.0.0.0:*               
LISTEN   0        4096             0.0.0.0:111            0.0.0.0:*               
LISTEN   0        4096           127.0.0.1:10024          0.0.0.0:*               
LISTEN   0        16               0.0.0.0:8200           0.0.0.0:*               
LISTEN   0        100              0.0.0.0:143            0.0.0.0:*               
LISTEN   0        4096             0.0.0.0:57733          0.0.0.0:*               
LISTEN   0        100              0.0.0.0:995            0.0.0.0:*               
LISTEN   0        100              0.0.0.0:993            0.0.0.0:*               
LISTEN   0        4096           127.0.0.1:783            0.0.0.0:*               
LISTEN   0        4096           127.0.0.1:9050           0.0.0.0:*               
LISTEN   0        4096             0.0.0.0:34051          0.0.0.0:*               
LISTEN   0        4096           127.0.0.1:631            0.0.0.0:*               
LISTEN   0        4096             0.0.0.0:34285          0.0.0.0:*               
LISTEN   0        100            127.0.0.1:25             0.0.0.0:*               
LISTEN   0        4096             0.0.0.0:47155          0.0.0.0:*               
LISTEN   0        4096       127.0.0.53%lo:53             0.0.0.0:*               
LISTEN   0        200              0.0.0.0:8042           0.0.0.0:*               
LISTEN   0        100              0.0.0.0:4190           0.0.0.0:*               
LISTEN   0        50               0.0.0.0:4242           0.0.0.0:*               
LISTEN   0        100                [::1]:25                [::]:*               
LISTEN   0        64                  [::]:2049              [::]:*               
LISTEN   0        4096               [::1]:631               [::]:*               
LISTEN   0        4096               [::1]:783               [::]:*               
LISTEN   0        4096                [::]:60881             [::]:*               
LISTEN   0        4096               [::1]:10024             [::]:*               
LISTEN   0        100                 [::]:110               [::]:*               
LISTEN   0        4096                [::]:111               [::]:*               
LISTEN   0        511                    *:80                   *:*               
LISTEN   0        4096                   *:22                   *:*               
LISTEN   0        100                 [::]:143               [::]:*               
LISTEN   0        64                  [::]:33379             [::]:*               
LISTEN   0        4096                [::]:41855             [::]:*               
LISTEN   0        100                 [::]:995               [::]:*               
LISTEN   0        100                 [::]:993               [::]:*               
LISTEN   0        4096                [::]:39561             [::]:*               
LISTEN   0        100                 [::]:4190              [::]:*               
LISTEN   0        4096                [::]:45757             [::]:*  

Sieht anders als bei mir aus:

root@server:~# systemctl status dovecot.service
● dovecot.service - Dovecot IMAP/POP3 email server
     Loaded: loaded (/usr/lib/systemd/system/dovecot.service; enabled; preset: >
     Active: active (running) since Tue 2025-03-25 20:39:47 CET; 49min ago
       Docs: man:dovecot(1)
             https://doc.dovecot.org/
   Main PID: 2409 (dovecot)
     Status: "v2.3.21 (47349e2482) running"
      Tasks: 6 (limit: 18899)
     Memory: 9.6M (peak: 14.4M)
        CPU: 123ms
     CGroup: /system.slice/dovecot.service
             ├─2409 /usr/sbin/dovecot -F
             ├─2535 dovecot/anvil
             ├─2536 dovecot/log
             ├─2537 dovecot/config
             ├─6822 dovecot/stats
             └─6908 dovecot/auth

Mär 25 20:39:47 server.local.#.#.org dovecot[2409]: master: Dovecot v2.3.21>
Mär 25 20:39:47 server.local.#.#.org systemd[1]: Started dovecot.service - >
Mär 25 21:20:58 server.local.#.#.org dovecot[2536]: imap-login: Disconnecte>
Mär 25 21:20:58 server.local.#.#.org dovecot[2536]: pop3-login: Disconnecte>
Mär 25 21:20:58 server.local.#.#.org dovecot[2536]: imap-login: Disconnecte>
lines 1-23...skipping...
● dovecot.service - Dovecot IMAP/POP3 email server
     Loaded: loaded (/usr/lib/systemd/system/dovecot.service; enabled; preset: enabled)
     Active: active (running) since Tue 2025-03-25 20:39:47 CET; 49min ago
       Docs: man:dovecot(1)
             https://doc.dovecot.org/
   Main PID: 2409 (dovecot)
     Status: "v2.3.21 (47349e2482) running"
      Tasks: 6 (limit: 18899)
     Memory: 9.6M (peak: 14.4M)
        CPU: 123ms
     CGroup: /system.slice/dovecot.service
             ├─2409 /usr/sbin/dovecot -F
             ├─2535 dovecot/anvil
             ├─2536 dovecot/log
             ├─2537 dovecot/config
             ├─6822 dovecot/stats
             └─6908 dovecot/auth

Mär 25 20:39:47 server.local.#.#.org dovecot[2409]: master: Dovecot v2.3.21 (47349e2482) starting up for imap, sieve, pop3 (core dumps disabled)
Mär 25 20:39:47 server.local.#.#.org systemd[1]: Started dovecot.service - Dovecot IMAP/POP3 email server.
Mär 25 21:20:58 server.local.#.#.org dovecot[2536]: imap-login: Disconnected: Connection closed: read(size=1026) failed: Connection reset by peer (disconnected before auth was ready, waited 0 secs): user=<>, rip=192.168.178.120, lip=192.168.178.120, secured, session=<48RxdTAxaJfAqLJ4>
Mär 25 21:20:58 server.local.#.#.org dovecot[2536]: pop3-login: Disconnected: Connection closed (no auth attempts in 0 secs): user=<>, rip=192.168.178.120, lip=192.168.178.120, secured, session=<Mt5xdTAxMrvAqLJ4>
Mär 25 21:20:58 server.local.#.#.org dovecot[2536]: imap-login: Disconnected: Connection closed: read(size=1026) failed: Connection reset by peer (no auth attempts in 0 secs): user=<>, rip=192.168.178.120, lip=192.168.178.120, TLS handshaking: read(size=1026) failed: Connection reset by peer, session=<BeVxdTAx1I>
Mär 25 21:20:58 server.local.#.#.org dovecot[2536]: pop3-login: Disconnected: Connection closed: read(size=1026) failed: Connection reset by peer (no auth attempts in 0 secs): user=<>, rip=192.168.178.120, lip=192.168.178.120, TLS handshaking: read(size=1026) failed: Connection reset by peer, session=<welxdTAx4M>
Mär 25 21:28:12 server.local.#.#.org dovecot[2536]: imap-login: Disconnected: Connection closed: read(size=1026) failed: Connection reset by peer (disconnected before auth was ready, waited 0 secs): user=<>, rip=127.0.0.1, lip=127.0.0.1, secured, session=<fOZNjzAxRot/AAAB>
Mär 25 21:28:12 server.local.#.#.org dovecot[2536]: pop3-login: Disconnected: Connection closed (no auth attempts in 0 secs): user=<>, rip=127.0.0.1, lip=127.0.0.1, secured, session=<9fhNjzAxwrJ/AAAB>
Mär 25 21:28:12 server.local.#.#.org dovecot[2536]: imap-login: Disconnected: Connection closed: read(size=1026) failed: Connection reset by peer (no auth attempts in 0 secs): user=<>, rip=127.0.0.1, lip=127.0.0.1, TLS handshaking: read(size=1026) failed: Connection reset by peer, session=<7wZOjzAx5rt/AAAB>
Mär 25 21:28:12 server.local.#.#.org dovecot[2536]: pop3-login: Disconnected: Connection closed: read(size=1026) failed: Connection reset by peer (no auth attempts in 0 secs): user=<>, rip=127.0.0.1, lip=127.0.0.1, TLS handshaking: read(size=1026) failed: Connection reset by peer, session=<EQdOjzAx+pN/AAAB>

Zum Testen verwenden wir mutt, funktioniert bei mir, bei ihm nicht. Standard-Mail-Client ist Claws-Mail, funktioniert bei mir, bei ihm nicht. Problem bei ihm ist immer die Verbindung.

sebix Team-Icon

Moderator, Webteam

Anmeldungsdatum:
14. April 2009

Beiträge: 5559

glaskugel schrieb:

Noch immer mit richtiger IP-Adresse Fehler:

$ openssl s_client -connect 192.168.178.120
4077D2A67E7D0000:error:8000006F:system library:BIO_connect:Connection refused:../crypto/bio/bio_sock2.c:114:calling connect()
4077D2A67E7D0000:error:10000067:BIO routines:BIO_connect:connect error:../crypto/bio/bio_sock2.c:116:
connect:errno=111

Da fehlt die Angabe des Ports im Befehl.

glaskugel

(Themenstarter)

Anmeldungsdatum:
8. Juli 2010

Beiträge: 3612

$ openssl s_client -connect 192.168.178.120:993
CONNECTED(00000003)
Can't use SSL_get_servername
depth=0 CN = server.local.#.#.org
verify return:1
---
Certificate chain
 0 s:CN = server.local.#.#.org
   i:CN = server.local.#.#.org
   a:PKEY: rsaEncryption, 2048 (bit); sigalg: RSA-SHA256
   v:NotBefore: Mar 16 19:04:40 2025 GMT; NotAfter: Mar 14 19:04:40 2035 GMT
---
Server certificate
-----BEGIN CERTIFICATE-----
M..g=
-----END CERTIFICATE-----
subject=CN = server.local.#.#.org
issuer=CN = server.local.#.#.org
---
No client certificate CA names sent
Peer signing digest: SHA256
Peer signature type: RSA-PSS
Server Temp Key: X25519, 253 bits
---
SSL handshake has read 1365 bytes and written 373 bytes
Verification: OK
---
New, TLSv1.3, Cipher is TLS_AES_256_GCM_SHA384
Server public key is 2048 bit
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
Early data was not sent
Verify return code: 0 (ok)
---
---
Post-Handshake New Session Ticket arrived:
SSL-Session:
    Protocol  : TLSv1.3
    Cipher    : TLS_AES_256_GCM_SHA384
    Session-ID: D..C
    Session-ID-ctx: 
    Resumption PSK: 8..6
    PSK identity: None
    PSK identity hint: None
    SRP username: None
    TLS session ticket lifetime hint: 7200 (seconds)
    TLS session ticket:
    0000 ....L~........

    Start Time: 1742999312
    Timeout   : 7200 (sec)
    Verify return code: 0 (ok)
    Extended master secret: no
    Max Early Data: 0
---
read R BLOCK
---
Post-Handshake New Session Ticket arrived:
SSL-Session:
    Protocol  : TLSv1.3
    Cipher    : TLS_AES_256_GCM_SHA384
    Session-ID: 0...9
    Session-ID-ctx: 
    Resumption PSK: 8...6
    PSK identity: None
    PSK identity hint: None
    SRP username: None
    TLS session ticket lifetime hint: 7200 (seconds)
    TLS session ticket:
    0000 ...e

    Start Time: 1742999312
    Timeout   : 7200 (sec)
    Verify return code: 0 (ok)
    Extended master secret: no
    Max Early Data: 0
---
read R BLOCK
* OK [CAPABILITY IMAP4rev1 SASL-IR LOGIN-REFERRALS ID ENABLE IDLE LITERAL+ AUTH=PLAIN] Dovecot (Ubuntu) ready.

sebix Team-Icon

Moderator, Webteam

Anmeldungsdatum:
14. April 2009

Beiträge: 5559

Perfekt, mit richtiger IP-Adresse und Port gehts nun ☺

Wenn nun damit alle Fragen geklaert sind, bitte das Thema als geloest markieren.

glaskugel

(Themenstarter)

Anmeldungsdatum:
8. Juli 2010

Beiträge: 3612

Wenn nun damit alle Fragen geklaert sind

Ich fürchte nein. Nur weil ein Befehl falsch gepostet wurde, funktionniert es ja nicht.

Ich muss das mit meinem Freund noch intensiver testen.

Die einfachste Variante für einen Test ist doch ein Test mit einem lokalen Mail des Users an sich selbst.

cat ~/.muttrc
set mbox_type=Maildir
set folder="~/Maildir"
set mask="!^\\.[^.]"
set mbox="~/Maildir"
set record="+.Sent"
set postponed="+.Drafts"
set spoolfile="~/Maildir"

Funktioniert bei mir bestens, da kommt nirgends eine IP-Adresse vor, also kann es nicht an der falschen IP-Adresse liegen. Ich denke wir lassen mai ein tail bei den Mail-Logs mitlaufen, vielleicht sieht man da was.

Hast du irgendeinen Vorschlag? Letztlich zählt ja, dass man Mails mit einem Mail-Client sieht. Wie schon geschrieben, getestet wird mit mutt, Als 2. Schritt dann Claws-Mail und da wird die eigene IP-Adresse angegeben, wird ja immer das lokale Postfach abgefragt, das von fetchmail gefüttert wird.

sebix Team-Icon

Moderator, Webteam

Anmeldungsdatum:
14. April 2009

Beiträge: 5559

glaskugel schrieb:

Hast du irgendeinen Vorschlag?

Fuer welches Problem? Die Verbindung auf den IMAP-Port klappt ja nun und die Antwort des Servers passt auch.

glaskugel

(Themenstarter)

Anmeldungsdatum:
8. Juli 2010

Beiträge: 3612

Ich stelle die Frage auch gerne wo anders, aber keine Ahnung wo, dürfte die Stecknadel im Heuhaufen sein, auch wenn es nur eine Kleinigkeit sein kann.

mutt meint "Maildir ist kein Postfach" beim jeweiligen User.

Tests werden mit einem User durchgefüht, der sudoer ist.

2025-03-26T19:38:09.643995+01:00 server postfix/pickup[2984]: 9D18A182A3F41: uid=1000 from=<ab>
2025-03-26T19:38:09.649291+01:00 server postfix/cleanup[22370]: 9D18A182A3F41: message-id=<Z-RJkYO3UgfPbYcr@server.local.#.#.org>
2025-03-26T19:38:09.651021+01:00 server postfix/qmgr[2985]: 9D18A182A3F41: from=<ab@server.local.#.#.org>, size=400, nrcpt=1 (queue active)
2025-03-26T19:38:09.658390+01:00 server postfix/local[22372]: 9D18A182A3F41: to=<ec@server.local.#.#.org>, orig_to=<ab@localhost>, relay=local, delay=0.02, delays=0.02/0/0/0, dsn=2.0.0, 

status=sent (delivered to mailbox)
2025-03-26T19:38:09.658474+01:00 server postfix/qmgr[2985]: 9D18A182A3F41: removed

Das Log liest sich ja gut. Keine Ahnung, warum mutt glaubt, dass es kein Postfach ist. Siehe muttrc davor. Der PC wurde schon mehrfach gestartet, nachdem die muttrc erstellt wurde.

Antworten |