1

Topic: LDAP unsupported dictionary type:ldap

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.1
- Deployed with iRedMail Easy or the downloadable installer? No
- Linux/BSD distribution name and version: FreeBSD
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): LDAP
- Web server (Apache or Nginx):nginx
- Manage mail accounts with iRedAdmin-Pro?No
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====
Hi I'm unable to connect to mail, after a php-extension upgrade of php-openldap. The installation failed to finish due to an existing file ldap-sass-client.

These are from my maillog files:
Apr 22 22:40:24 cha postfix/trivial-rewrite[2245]: warning: virtual_mailbox_domains: proxy:ldap:/usr/local/etc/postfix/ldap/virtual_mailbox_domains.cf: table lookup problem
Apr 22 22:40:24 cha postfix/trivial-rewrite[2245]: warning: virtual_mailbox_domains lookup failure
Apr 22 22:40:24 cha postfix/proxymap[2243]: warning: ldap:/usr/local/etc/postfix/ldap/virtual_mailbox_domains.cf is unavailable. unsupported dictionary type: ldap
Apr 22 22:40:24 cha postfix/trivial-rewrite[2245]: warning: virtual_mailbox_domains: proxy:ldap:/usr/local/etc/postfix/ldap/virtual_mailbox_domains.cf: table lookup problem
Apr 22 22:40:24 cha postfix/trivial-rewrite[2245]: warning: virtual_mailbox_domains lookup failure


Thanks.

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: LDAP unsupported dictionary type:ldap

Package 'postfix-ldap' is missing.

3

Re: LDAP unsupported dictionary type:ldap

Thanks for the reply.  I have started on a backup and restore, but am facing new issues like this:
Apr 23 14:49:18 cha postfix/proxymap[6136]: warning: dict_ldap_connect: Unable to bind to server ldap://127.0.0.1:389 with dn cn=vmail,dc=example,dc=com: 49 (Invalid credentials)
Apr 23 14:49:18 cha postfix/cleanup[6229]: warning: proxy:ldap:/usr/local/etc/postfix/ldap/sender_bcc_maps_user.cf lookup error for "root@cha.example.com"
Apr 23 14:49:18 cha postfix/cleanup[6229]: warning: 4977FV4qxpzCGh: sender_bcc_maps map lookup problem -- message not accepted, try again later
Apr 23 14:49:18 cha postfix/pickup[1293]: warning: maildrop/493bn81zl3zpDG: error writing 4977FV4qxpzCGh: queue file write error
Apr 23 14:49:19 cha postfix/pickup[1293]: 4977FW4rvnzCGj: uid=0 from=<root>
Apr 23 14:49:19 cha postfix/proxymap[6136]: warning: dict_ldap_connect: Unable to bind to server ldap://127.0.0.1:389 with dn cn=vmail,dc=example,dc=com: 49 (Invalid credentials)
Apr 23 14:49:19 cha postfix/cleanup[6229]: warning: proxy:ldap:/usr/local/etc/postfix/ldap/sender_bcc_maps_user.cf lookup error for "root@cha.example.com"
Apr 23 14:49:19 cha postfix/cleanup[6229]: warning: 4977FW4rvnzCGj: sender_bcc_maps map lookup problem -- message not accepted, try again later
Apr 23 14:49:19 cha postfix/pickup[1293]: warning: maildrop/495bd82B06z8DY: error writing 4977FW4rvnzCGj: queue file write error

Earlier I tried the following from your restore tutorial, and got this:
# slapadd -f /usr/local/etc/openldap/slapd.conf -l /var/vmail/backup/ldap/2020/04/2020-04-22-03-00-00.ldif
5ea131ea The first database does not allow slapadd; using the first available one (2)
ldif_parse_line: userPassword: invalid base64 encoding char ({) 0x7b

Is this still indicative of a missing postfix-ldap-sasl pkg missing? Would it be easier if I reinstall iRedMail to get the credentials working again?

Thanks!

4

Re: LDAP unsupported dictionary type:ldap

Hello,
I have decided to do a disk restore to get it up again.  Emails are working.

After system reboot, messages keep appearing in the /var/log/maillog:
Apr 24 07:53:56 cha postfix/master[3030]: warning: process /usr/local/libexec/postfix/qmgr pid 11311 exit status 1
Apr 24 07:53:56 cha postfix/master[3030]: warning: /usr/local/libexec/postfix/qmgr: bad command startup -- throttling
Apr 24 07:54:56 cha postfix/master[3030]: warning: process /usr/local/libexec/postfix/qmgr pid 11323 exit status 1
Apr 24 07:54:56 cha postfix/master[3030]: warning: /usr/local/libexec/postfix/qmgr: bad command startup -- throttling

Is there something I can do to set this right?

Thank you!

5

Re: LDAP unsupported dictionary type:ldap

for ref, this is what the .../etc/postfix/master.cf shows:
...
#628       inet  n       -       n       -       -       qmqpd
#smtp       inet  n       -       -       -       -       smtpd
pickup     unix  n       -       n       60      1       pickup
cleanup    unix  n       -       n       -       0       cleanup
#qmgr     unix  n       -       n       300     1       oqmgr
qmgr       unix  n       -       n       300     1       qmgr
tlsmgr     unix  -       -       n       1000?   1       tlsmgr
...

thks

6

Re: LDAP unsupported dictionary type:ldap

Try to restart Postfix service and check its log file immedately in /var/log/maillog, please paste that log here for troubleshooting.

7

Re: LDAP unsupported dictionary type:ldap

Hi there,
Here are the logs:
Apr 24 17:14:40 cha postfix/postfix-script[38353]: stopping the Postfix mail system
Apr 24 17:14:40 cha postfix/master[3030]: terminating on signal 15
Apr 24 17:14:42 cha postfix/postscreen[38356]: DNSBL rank 5 for [95.141.23.11]:39366
Apr 24 17:14:42 cha postfix/postscreen[38356]: DISCONNECT [95.141.23.11]:39366
Apr 24 17:14:46 cha postfix/postqueue[38357]: fatal: Queue report unavailable - mail system is down
Apr 24 17:14:48 cha postfix/postfix-script[38432]: warning: /var/spool/postfix/etc/resolv.conf and /etc/resolv.conf differ
Apr 24 17:14:48 cha postfix/postfix-script[38437]: starting the Postfix mail system
Apr 24 17:14:48 cha postfix/master[38439]: daemon started -- version 3.4.9, configuration /usr/local/etc/postfix
Apr 24 17:14:48 cha postfix/master[38439]: warning: process /usr/local/libexec/postfix/qmgr pid 38441 exit status 1
Apr 24 17:14:48 cha postfix/master[38439]: warning: /usr/local/libexec/postfix/qmgr: bad command startup -- throttling
Apr 24 17:15:48 cha postfix/master[38439]: warning: process /usr/local/libexec/postfix/qmgr pid 38459 exit status 1
Apr 24 17:15:48 cha postfix/master[38439]: warning: /usr/local/libexec/postfix/qmgr: bad command startup -- throttling
Apr 24 17:16:29 cha postfix/master[38439]: warning: unix_trigger_event: read timeout for service public/qmgr
Apr 24 17:16:48 cha postfix/master[38439]: warning: process /usr/local/libexec/postfix/qmgr pid 38474 exit status 1
Apr 24 17:16:48 cha postfix/master[38439]: warning: /usr/local/libexec/postfix/qmgr: bad command startup -- throttling

I have compared the two etc/resolv.conf files, they have the same content, except 1 of them has an extra carriage-return.

Thanks again!  :-)

8

Re: LDAP unsupported dictionary type:ldap

Did you modify any Postfix config files especially /etc/postfix/main.cf and master.cf?

9

Re: LDAP unsupported dictionary type:ldap

ZhangHuangbin wrote:

Did you modify any Postfix config files especially /etc/postfix/main.cf and master.cf?

I don't think I did. Here's what the directory looks like after the installation.

root@cha:/usr/local/etc/postfix # ls -lt
total 264
-rw-r--r--  1 root  wheel    49152 Mar 10 02:45 aliases.db
-rw-r--r--  1 root  wheel     1795 Mar 10 02:45 aliases
-rw-r--r--  1 root  wheel    12432 Mar 10 02:45 main.cf
drwxr-xr-x  2 root  wheel      512 Mar 10 02:45 disclaimer
-rw-r--r--  1 root  wheel      124 Mar 10 02:44 postscreen_access.cidr
-rw-r--r--  1 root  wheel        0 Mar 10 02:44 postscreen_dnsbl_reply
-rw-r--r--  1 root  wheel     9344 Mar 10 02:44 master.cf
drwxr-xr-x  2 root  wheel     1024 Mar 10 02:44 ldap
-rw-r--r--  1 root  wheel      193 Mar 10 02:44 command_filter.pcre
-rw-r--r--  1 root  wheel    18689 Mar 10 02:44 helo_access.pcre
-rw-r-----  1 root  wheel        0 Mar 10 02:44 helo_access.pcre.2020.03.09.20.57.41
-rw-r-----  1 root  postfix      0 Mar 10 02:44 sender_access.pcre
-rw-r-----  1 root  postfix      0 Mar 10 02:44 body_checks.pcre
-rw-r-----  1 root  postfix      0 Mar 10 02:44 header_checks
-rw-r--r--  1 root  wheel     6340 Mar 10 02:44 master.cf.2020.03.09.20.57.41
-rw-r--r--  1 root  wheel    27126 Mar 10 02:44 main.cf.2020.03.09.20.57.41
-rw-r--r--  1 root  wheel    27104 Mar 10 02:05 main.cf.sample
-rw-r--r--  1 root  wheel     6340 Mar 10 02:05 master.cf.sample
-rw-r--r--  1 root  wheel    37667 Mar 10 02:05 main.cf.default
-rw-r--r--  1 root  wheel     3547 Mar 10 02:05 bounce.cf.default
-rw-r--r--  1 root  wheel     1629 Mar 10 02:05 TLS_LICENSE
-rw-r--r--  1 root  wheel    26493 Mar 10 02:05 LICENSE

We are losing emails –– I did not realize this. On the surface, the connections look okay, and emails can be sent out, and connections-in all show green (Mail Connection doctor). But they sort of disappearing to nowhere. Test emails sent out are not received and I can't figure where they went.

10

Re: LDAP unsupported dictionary type:ldap

I cannot figure out the root cause with pasted info.
Would you like to buy a support ticket to get support via direct ssh access?
https://www.iredmail.org/support.html

11

Re: LDAP unsupported dictionary type:ldap

Hey Zhang,
I got the emails running again...  it was the libexec/postfix/qmgr that was rollback by the restore software, it did not replace that and 3 others. So the 'contaminated' pieces were still in the directory. I went back a few more days to find what the directory looked like and replaced the entire libexec/postfix with one that had no changes prior. What was a few moments ago:
root@cha:/usr/local/libexec/postfix # ls -lt
total 1744
-rwxr-xr-x  2 root  wheel  130872 Apr 21 09:12 lmtp
-rwxr-xr-x  2 root  wheel   74760 Apr 21 09:12 nqmgr
-rwxr-xr-x  2 root  wheel   74760 Apr 21 09:12 qmgr
-rwxr-xr-x  2 root  wheel  130872 Apr 21 09:12 smtp
-rwxr-xr-x  1 root  wheel   32672 Mar 10 02:05 virtual
-rwxr-xr-x  1 root  wheel   24280 Mar 10 02:05 verify
-rwxr-xr-x  1 root  wheel   37464 Mar 10 02:05 trivial-rewrite
-rwxr-xr-x  1 root  wheel   47752 Mar 10 02:05 tlsproxy
-rwxr-xr-x  1 root  wheel   28624 Mar 10 02:05 tlsmgr
-rwxr-xr-x  1 root  wheel   19864 Mar 10 02:05 spawn
-rwxr-xr-x  1 root  wheel  246936 Mar 10 02:05 smtpd
-rwxr-xr-x  1 root  wheel   20016 Mar 10 02:05 showq
-rwxr-xr-x  1 root  wheel   19896 Mar 10 02:05 scache
-rwxr-xr-x  1 root  wheel   28408 Mar 10 02:05 qmqpd
....

Originally, I thought that getting a PHP-extension that Opencart needed was not a big deal, esp when put with

make install clean

, however, it pulled in another biggie with it, and it was careless of me to let that through.

I was so thrilled to hear the sound of all the lost emails coming home.  big_smile

Many thanks... I have sent some coffee your way (........447645F)!

12

Re: LDAP unsupported dictionary type:ldap

Thanks for sharing and the coffee. smile