Постфикс не цепляет пользователей из лдап.
Конфиг постфикса:
Код: Выделить всё
queue_directory = /var/spool/postfix
command_directory = /usr/local/sbin
daemon_directory = /usr/local/libexec/postfix
data_directory = /var/db/postfix
mail_owner = postfix
myhostname = lst103.ls1.ru
mydomain = mydomain.ru
mydestination = $myhostname, localhost, localhost.localdomain, localhost.$mydomain, $mydomain, mydomain.ru
myorigin = $mydomain
inet_interfaces = all
local_recipient_maps = unix:passwd.byname $alias_maps
unknown_local_recipient_reject_code = 550
mynetworks_style = subnet
mynetworks =192.168.0.0/16, 127.0.0.0/8
biff = no
debug_peer_list = 127.0.0.1 192.168.0.241
virtual_transport = virtual
mailbox_transport = virtual
local_transport = virtual
message_size_limit = 10280000
mailbox_size_limit = 20480000
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth
cyrus_destination_recipient_limit=1
broken_sasl_auth_clients = yes
smtpd_pw_server_security_options = noanonymous
virtual_uid_maps = static:1001
virtual_gid_maps = static:1001
virtual_recipient_maps = ldap:ldapsource
#virtual_alias_maps = ldap:ldapsourcealias
#virtual_alias_maps = ldap:ldapsource
virtual_mailbox_size_limit = 20480000
virtual_minimum_uid = 500
virtual_mailbox_base =/var/spool/mail
virtual_result_attribute = mailbox
#virtual_mailbox_maps = ldap:ldapsource
virtual_maildir_extended = yes
ldapsource_server_host = 192.168.101.104
ldapsource_search_base = ou=people,dc=mydomain,dc=ru
ldapsource_server_port = 389
#ldapsource_domain = mydomain.ru
ldapsource_query_filter = (&(mail=%s))
#ldapsource_result_attribute = mailbox
ldapsourcealias_server_host = 192.168.101.104
ldapsource_bind = yes
ldapsource_bind_dn = cn=ldapadmin,dc=mydomain,dc=ru
ldapsource_bind_pw = secret
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
mail_name = exchange
mail_version = 0.1
smtpd_banner = $myhostname ESMTP $mail_name ($mail_version) (Windows 3.11)
debug_peer_level = 4
debugger_command =
PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin
xxgdb $daemon_directory/$process_name $process_id & sleep 5
delay_warning_time = 4
sendmail_path = /usr/local/sbin/sendmail
newaliases_path = /usr/local/bin/newaliases
mailq_path = /usr/local/bin/mailq
setgid_group = maildrop
manpage_directory = /usr/local/man
Код: Выделить всё
May 6 07:34:04 lst104 slapd[4352]: connection_get(10): got connid=1034
May 6 07:34:04 lst104 slapd[4352]: connection_read(10): checking for input on id=1034
May 6 07:34:04 lst104 slapd[4352]: op tag 0x63, time 1304667244
May 6 07:34:04 lst104 slapd[4352]: conn=1034 op=101 do_search
May 6 07:34:04 lst104 slapd[4352]: >>> dnPrettyNormal: <dc=mydomain,dc=ru>
May 6 07:34:04 lst104 slapd[4352]: <<< dnPrettyNormal: <dc=mydomain,dc=ru>, <dc=mydomain,dc=ru>
May 6 07:34:04 lst104 slapd[4352]: => bdb_search
May 6 07:34:04 lst104 slapd[4352]: bdb_dn2entry("dc=mydomain,dc=ru")
May 6 07:34:04 lst104 slapd[4352]: search_candidates: base="dc=mydomain,dc=ru" (0x00000001) scope=2
May 6 07:34:04 lst104 slapd[4352]: => bdb_dn2idl("dc=mydomain,dc=ru")
May 6 07:34:04 lst104 slapd[4352]: => bdb_equality_candidates (objectClass)
May 6 07:34:04 lst104 slapd[4352]: => key_read
May 6 07:34:04 lst104 slapd[4352]: <= bdb_index_read: failed (-30989)
May 6 07:34:04 lst104 slapd[4352]: <= bdb_equality_candidates: id=0, first=0, last=0
May 6 07:34:04 lst104 slapd[4352]: => bdb_equality_candidates (objectClass)
May 6 07:34:04 lst104 slapd[4352]: => key_read
May 6 07:34:04 lst104 slapd[4352]: <= bdb_index_read 2 candidates
May 6 07:34:04 lst104 slapd[4352]: <= bdb_equality_candidates: id=2, first=17, last=27
May 6 07:34:04 lst104 slapd[4352]: => bdb_equality_candidates (mail)
May 6 07:34:04 lst104 slapd[4352]: => key_read
May 6 07:34:04 lst104 slapd[4352]: <= bdb_index_read 1 candidates
May 6 07:34:04 lst104 slapd[4352]: <= bdb_equality_candidates: id=1, first=27, last=27
May 6 07:34:04 lst104 slapd[4352]: bdb_search_candidates: id=1 first=27 last=27
May 6 07:34:04 lst104 slapd[4352]: => send_search_entry: conn 1034 dn="cn=user11,ou=people,dc=mydomain,dc=ru"
May 6 07:34:04 lst104 slapd[4352]: <= send_search_entry: conn 1034 exit.
May 6 07:34:04 lst104 slapd[4352]: send_ldap_result: conn=1034 op=101 p=3
May 6 07:34:04 lst104 slapd[4352]: send_ldap_response: msgid=102 tag=101 err=0
Код: Выделить всё
May 6 07:49:37 lst103 postfix/smtpd[60539]: connect from unknown[192.168.0.241]
May 6 07:49:38 lst103 postfix/smtpd[60539]: NOQUEUE: reject: RCPT from unknown[192.168.0.241]: 550 5.1.1 <user11@mydomain.ru>: Recipient address rejected: User unknown in local recipient table; from=<user11@mydomain.ru> to=<user11@mydomain.ru> proto=ESMTP helo=<[192.168.0.241]>
May 6 07:49:38 lst103 postfix/smtpd[60539]: disconnect from unknown[192.168.0.241]