# [RISOLTO]  Server virtuale Postfix non funziona

## DevOne

Ciao a tutti, ho un problema abbastanza urgente!

Sto creando un server di posta ex-nuovo, da affiancare a quello attuale, ma

con la guida presente sul sito gentoo, non riesco in nessun modo ad autenticare

sia in pop, che imap che in smtp....

Inoltre sui log riguardandi pop3 ed imap, il comando chdir da permission denied, anche se i permessi

sono settati!!

Questo è il log che mi produce:

```

Apr 14 10:38:10 mail postfix/smtpd[6540]: connection established

Apr 14 10:38:10 mail postfix/smtpd[6540]: master_notify: status 0

Apr 14 10:38:10 mail postfix/smtpd[6540]: name_mask: resource

Apr 14 10:38:10 mail postfix/smtpd[6540]: name_mask: software

Apr 14 10:38:10 mail postfix/smtpd[6540]: name_mask: noanonymous

Apr 14 10:38:10 mail postfix/smtpd[6540]: connect from host10-211.pool82187.interbusiness.it[82.187.211.10]

Apr 14 10:38:10 mail postfix/smtpd[6540]: match_list_match: host10-211.pool82187.interbusiness.it: no match

Apr 14 10:38:10 mail postfix/smtpd[6540]: match_list_match: 82.187.211.10: no match

Apr 14 10:38:10 mail postfix/smtpd[6540]: match_list_match: host10-211.pool82187.interbusiness.it: no match

Apr 14 10:38:10 mail postfix/smtpd[6540]: match_list_match: 82.187.211.10: no match

Apr 14 10:38:10 mail postfix/smtpd[6540]: match_hostname: host10-211.pool82187.interbusiness.it ~? 82.187.211.10

Apr 14 10:38:10 mail postfix/smtpd[6540]: match_hostaddr: 82.187.211.10 ~? 82.187.211.10

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 220 mail.maiettasrl.it ESMTP Qmail on Alpha (1.1.9)

Apr 14 10:38:10 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: EHLO [10.0.0.17]

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250-mail.maiettasrl.it

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250-PIPELINING

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250-SIZE 20240000

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250-VRFY

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250-ETRN

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250-STARTTLS

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250-AUTH LOGIN PLAIN

Apr 14 10:38:10 mail postfix/smtpd[6540]: match_list_match: host10-211.pool82187.interbusiness.it: no match

Apr 14 10:38:10 mail postfix/smtpd[6540]: match_list_match: 82.187.211.10: no match

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250-AUTH=LOGIN PLAIN

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 250 8BITMIME

Apr 14 10:38:10 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: STARTTLS

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 454 TLS not available due to local problem

Apr 14 10:38:10 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: AUTH PLAIN AGdpYW5uaS5yb21hbm9AbWFpZXR0YXNybC5pdAAucm9tYTE5NzY=

Apr 14 10:38:10 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: sasl_method PLAIN, init_response AGdpYW5uaS5yb21hbm9AbWFpZXR0YXNybC5pdAAucm9tYTE5NzY=

Apr 14 10:38:10 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded initial response

Apr 14 10:38:10 mail postfix/smtpd[6540]: warning: SASL authentication failure: Password verification failed

Apr 14 10:38:10 mail postfix/smtpd[6540]: warning: host10-211.pool82187.interbusiness.it[82.187.211.10]: SASL PLAIN authentication failed

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 535 Error: authentication failed

Apr 14 10:38:10 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: AUTH LOGIN

Apr 14 10:38:10 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: sasl_method LOGIN

Apr 14 10:38:10 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: uncoded challenge: Username:

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 334 VXNlcm5hbWU6

Apr 14 10:38:10 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: Z2lhbm5pLnJvbWFub0BtYWlldHRhc3JsLml0

Apr 14 10:38:10 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded response: mia@email.it

Apr 14 10:38:10 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: uncoded challenge: Password:

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 334 UGFzc3dvcmQ6

Apr 14 10:38:10 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: LnJvbWExOTc2

Apr 14 10:38:10 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded response: XXXXXX

Apr 14 10:38:10 mail postfix/smtpd[6540]: warning: host10-211.pool82187.interbusiness.it[82.187.211.10]: SASL LOGIN authentication failed

Apr 14 10:38:10 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 535 Error: authentication failed

Apr 14 10:38:11 mail postfix/smtp[6544]: warning: connect #6 to subsystem private/scache: No such file or directory

Apr 14 10:38:11 mail postfix/smtp[6546]: warning: connect #6 to subsystem private/scache: No such file or directory

Apr 14 10:38:14 mail pop3d: Connection, ip=[::ffff:82.187.211.10]

Apr 14 10:38:14 mail pop3d: chdir /home/vmail/maiettasrl.it/patrizia.quaranta/.maildir/: Permission denied

Apr 14 10:38:21 mail postfix/smtp[6544]: warning: connect #7 to subsystem private/scache: No such file or directory

Apr 14 10:38:21 mail postfix/smtp[6546]: warning: connect #7 to subsystem private/scache: No such file or directory

Apr 14 10:38:29 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: AUTH PLAIN AGdpYW5uaS5yb21hbm9AbWFpZXR0YXNybC5pdAAucm9tYTE5NzY=

Apr 14 10:38:29 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: sasl_method PLAIN, init_response AGdpYW5uaS5yb21hbm9AbWFpZXR0YXNybC5pdAAucm9tYTE5NzY=

Apr 14 10:38:29 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded initial response

Apr 14 10:38:29 mail postfix/smtpd[6540]: warning: SASL authentication failure: Password verification failed

Apr 14 10:38:29 mail postfix/smtpd[6540]: warning: host10-211.pool82187.interbusiness.it[82.187.211.10]: SASL PLAIN authentication failed

Apr 14 10:38:29 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 535 Error: authentication failed

Apr 14 10:38:29 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: AUTH LOGIN

Apr 14 10:38:29 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: sasl_method LOGIN

Apr 14 10:38:29 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: uncoded challenge: Username:

Apr 14 10:38:29 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 334 VXNlcm5hbWU6

Apr 14 10:38:29 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: Z2lhbm5pLnJvbWFub0BtYWlldHRhc3JsLml0

Apr 14 10:38:29 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded response: mia@email.it

Apr 14 10:38:29 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: uncoded challenge: Password:

Apr 14 10:38:29 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 334 UGFzc3dvcmQ6

Apr 14 10:38:29 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: LnJvbWExOTc2

Apr 14 10:38:29 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded response: password

Apr 14 10:38:29 mail postfix/smtpd[6540]: warning: host10-211.pool82187.interbusiness.it[82.187.211.10]: SASL LOGIN authentication failed

Apr 14 10:38:29 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 535 Error: authentication failed

Apr 14 10:38:31 mail postfix/smtp[6544]: warning: connect #8 to subsystem private/scache: No such file or directory

Apr 14 10:38:31 mail postfix/smtp[6546]: warning: connect #8 to subsystem private/scache: No such file or directory

Apr 14 10:38:32 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: AUTH PLAIN AGdpYW5uaS5yb21hbm9AbWFpZXR0YXNybC5pdAAucm9tYTE5NzY=

Apr 14 10:38:32 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: sasl_method PLAIN, init_response AGdpYW5uaS5yb21hbm9AbWFpZXR0YXNybC5pdAAucm9tYTE5NzY=

Apr 14 10:38:32 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded initial response

Apr 14 10:38:32 mail postfix/smtpd[6540]: warning: SASL authentication failure: Password verification failed

Apr 14 10:38:32 mail postfix/smtpd[6540]: warning: host10-211.pool82187.interbusiness.it[82.187.211.10]: SASL PLAIN authentication failed

Apr 14 10:38:32 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 535 Error: authentication failed

Apr 14 10:38:32 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: AUTH LOGIN

Apr 14 10:38:32 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: sasl_method LOGIN

Apr 14 10:38:32 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: uncoded challenge: Username:

Apr 14 10:38:32 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 334 VXNlcm5hbWU6

Apr 14 10:38:32 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: Z2lhbm5pLnJvbWFub0BtYWlldHRhc3JsLml0

Apr 14 10:38:32 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded response: mia@email.it

Apr 14 10:38:32 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: uncoded challenge: Password:

Apr 14 10:38:32 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 334 UGFzc3dvcmQ6

Apr 14 10:38:32 mail postfix/smtpd[6540]: < host10-211.pool82187.interbusiness.it[82.187.211.10]: LnJvbWExOTc2

Apr 14 10:38:32 mail postfix/smtpd[6540]: smtpd_sasl_authenticate: decoded response: XXXXX

Apr 14 10:38:32 mail postfix/smtpd[6540]: warning: host10-211.pool82187.interbusiness.it[82.187.211.10]: SASL LOGIN authentication failed

Apr 14 10:38:32 mail postfix/smtpd[6540]: > host10-211.pool82187.interbusiness.it[82.187.211.10]: 535 Error: authentication failed

Apr 14 10:38:34 mail postfix/smtpd[6540]: smtp_get: EOF

Apr 14 10:38:34 mail postfix/smtpd[6540]: match_hostname: host10-211.pool82187.interbusiness.it ~? 82.187.211.10

Apr 14 10:38:34 mail postfix/smtpd[6540]: match_hostaddr: 82.187.211.10 ~? 82.187.211.10

Apr 14 10:38:34 mail postfix/smtpd[6540]: lost connection after AUTH from host10-211.pool82187.interbusiness.it[82.187.211.10]

Apr 14 10:38:34 mail postfix/smtpd[6540]: disconnect from host10-211.pool82187.interbusiness.it[82.187.211.10]

Apr 14 10:38:34 mail postfix/smtpd[6540]: master_notify: status 1

Apr 14 10:38:34 mail postfix/smtpd[6540]: connection closed

```

Monta:

dev-libs/cyrus-sasl-2.1.21-r2

mail-mta/postfix-2.2.5

net-mail/courier-imap-4.0.1

udev

Ho riscontrato molte diversità tra la vecchia guida e quella nuova...

----------

## Dun

```

cat /etc/conf.d/saslauthd

cat /etc/courier/authlib/authdaemonrc

```

Plz  :Smile: 

----------

## DevOne

 *Dun wrote:*   

> 
> 
> ```
> 
> cat /etc/conf.d/saslauthd
> ...

 

saslauthd:

```

# $Header: /var/cvsroot/gentoo-x86/dev-libs/cyrus-sasl/files/saslauthd-2.1.20.conf,v 1.1 2004/10/31 06:13:48 langthang Exp $

# Config file for /etc/init.d/saslauthd

# Initial (empty) options.

SASLAUTHD_OPTS=""

# Specify the authentications mechanism.

# *NOTE* For list see: saslauthd -v

# From 2.1.19, add "-r" to options for old behavior

# ie. reassemble user and realm to user@realm form.

# SASLAUTHD_OPTS="${SASLAUTH_MECH} -a pam -r"

SASLAUTHD_OPTS="${SASLAUTH_MECH} -a pam"

# Specify the hostname for remote IMAP server.

# *NOTE* Only needed if rimap auth mech is used.

#SASLAUTHD_OPTS="${SASLAUTHD_OPTS} -O localhost"

# Specify the number of worker processes to create.

#SASLAUTHD_OPTS="${SASLAUTHD_OPTS} -n 5"

# Enable credential cache, cache size, and timeout.

# *NOTE* Size is measured in kilobytes

#        Timeout is measured in seconds

#SASLAUTHD_OPTS="${SASLAUTHD_OPTS} -c -s 128 -t 30"

```

Avevo anche provato con le impostazioni della guida (ne aggiunge 2)

authdaemonrc:

```

##VERSION: $Id: authdaemonrc.in,v 1.10 2004/11/10 00:42:04 mrsam Exp $

#

# Copyright 2000-2004 Double Precision, Inc.  See COPYING for

# distribution information.

#

# authdaemonrc created from authdaemonrc.dist by sysconftool

#

# Do not alter lines that begin with ##, they are used when upgrading

# this configuration.

#

# This file configures authdaemond, the resident authentication daemon.

#

# Comments in this file are ignored.  Although this file is intended to

# be sourced as a shell script, authdaemond parses it manually, so

# the acceptable syntax is a bit limited.  Multiline variable contents,

# with the \ continuation character, are not allowed.  Everything must

# fit on one line.  Do not use any additional whitespace for indentation,

# or anything else.

##NAME: authmodulelist:2

#

# The authentication modules that are linked into authdaemond.  The

# default list is installed.  You may selectively disable modules simply

# by removing them from the following list.  The available modules you

# can use are: authuserdb authpam authshadow authmysql authcustom

#

# Previous setting (inserted by sysconftool):

#

#

# authmodulelist="authmysql authpam"

#

authmodulelist="authmysql authpam"

##NAME: authmodulelistorig:2

#

# This setting is used by Courier's webadmin module, and should be left

# alone

#

# Previous setting (inserted by sysconftool):

#

#

# authmodulelistorig="authcustom authcram authuserdb authmysql authpam"

#

authmodulelistorig="authuserdb authpam authshadow authmysql authcustom"

##NAME: daemons:0

#

# The number of daemon processes that are started.  authdaemon is typically

# installed where authentication modules are relatively expensive: such

# as authldap, or authmysql, so it's better to have a number of them running.

# PLEASE NOTE:  Some platforms may experience a problem if there's more than

# one daemon.  Specifically, SystemV derived platforms that use TLI with

# socket emulation.  I'm suspicious of TLI's ability to handle multiple

# processes accepting connections on the same filesystem domain socket.

#

# You may need to increase daemons if as your system load increases.  Symptoms

# include sporadic authentication failures.  If you start getting

# authentication failures, increase daemons.  However, the default of 5

# SHOULD be sufficient.  Bumping up daemon count is only a short-term

# solution.  The permanent solution is to add more resources: RAM, faster

# disks, faster CPUs...

#

# DEFAULT SETTING from /var/tmp/portage/courier-authlib-0.53/image//etc/courier/authlib/authdaemonrc.dist:

#

#daemons=5

#

daemons=5

##NAME: authdaemonvar:2

#

# authdaemonvar is here, but is not used directly by authdaemond.  It's

# used by various configuration and build scripts, so don't touch it!

#

# Previous setting (inserted by sysconftool):

#

#

# authdaemonvar=/var/lib/courier-imap/authdaemon

#

authdaemonvar=/var/lib/courier/authdaemon

##NAME: DEBUG_LOGIN:0

#

# Dump additional diagnostics to syslog

#

# DEBUG_LOGIN=0   - turn off debugging

# DEBUG_LOGIN=1   - turn on debugging

# DEBUG_LOGIN=2   - turn on debugging + log passwords too

#

# ** YES ** - DEBUG_LOGIN=2 places passwords into syslog.

#

# Note that most information is sent to syslog at level 'debug', so

# you may need to modify your /etc/syslog.conf to be able to see it.

DEBUG_LOGIN=0

##NAME: DEFAULTOPTIONS:0

#

# A comma-separated list of option=value pairs. Each option is applied

# to an account if the account does not have its own specific value for

# that option. So for example, you can set

#   DEFAULTOPTIONS="disablewebmail=1,disableimap=1"

# and then enable webmail and/or imap on individual accounts by setting

# disablewebmail=0 and/or disableimap=0 on the account.

DEFAULTOPTIONS=""

```

Un'altra cosa: nei log si possono notare anche dei warning a "scache" o "private/anvil" e via dicendo

che non ho capito che cosa sono e perchè escono!!!

Inoltre ho provato ad inviare una mail dal libero verso il mio server, e dice che il dominio (che postfix dovrebbe considerare valido), non viene trovato!

infatti al prompt, rispetto all'altro server, mi da solo: macchina.(none) anzicchè macchina.dominio

----------

## .:chrome:.

calma.

postfix offre servizio SMTP, non POP né IMAP, quindi non dare la colpa tutta a lui

prima cosa: compila cyrus-sasl con flag authdaemond, e fai in modo che postfix conosca gli utenti locali e che recapiti loro la posta locale nelle relative maildir

successivamente configura courier-authlib per poter accedere correttamente ai tuoi utenti via POP o IMAP.

fatto questo usa authdaemond come mezzo di autenticazione come ti è stato suggerito

----------

## DevOne

Ciao,

sono riuscito a far funzionare il server smtp, 

commentando una proprietà di postfix che sul vecchio server

non da problemi (anche se tutte le versioni dei pacchetti sono le stesse su entrambi i server);

Ora ho l'unico problema su courier-imap: non riesco a scaricarare per mancata autenticazione!

Sulle guide, non c'è spiegato molto: fare l'emerge e creare i certificati!!

Non so cosa altro provare per controllare l'autenticazione!   :Mad: 

----------

## DevOne

 *DevOne wrote:*   

> 
> 
> Ora ho l'unico problema su courier-imap: non riesco a scaricarare per mancata autenticazione!
> 
> Sulle guide, non c'è spiegato molto: fare l'emerge e creare i certificati!!
> ...

 

 :Embarassed:   :Embarassed:   :Embarassed: 

Ho controllato la password che avevo settato per il test, ed era diversa da quella che abitualmente

usavo...  :Laughing: 

Adesso funziona! 

Grazie a tutti per il supporto

Ciao

----------

