• Contact Us
  • Home
  • Installation
  • Troubleshooting

How to Fix MDB Map Full Error

Written by Maryanne Normann

Updated at September 11th, 2025

  • Quick Start
  • Installation
    Best Practices Configuration Troubleshooting Design Performance Platform
  • Maintenance
    Releases Upgrade
  • Reference
+ More

Table of Contents

Overview Increasing olcDbMaxSize (cn=config) Increasing maxsize (slapd.conf) See Also

Date: 11-04-2022

Overview

The MDB backend requires a setting called maxsize/olcDbMaxSize, which sets the maximum on-disk size (in bytes) of its data.mdb file. When the amount of data inside the data.mdb file reaches the maximum size, the MDB database will no longer accept any writes.

If slapd refuses to add/modify entries, check the slapd logs for the following error message:

MDB_MAP_FULL: Environment mapsize limit reached (-30792)

If this message is present, you must increase the value of the maxsize/olcDbMaxSize setting to allow for more data to be added.

Increasing olcDbMaxSize (cn=config)

Create the following .ldif file:

# File: UpdateDbMaxSize.ldif
#
dn: olcDatabase={N}mdb,cn=config
changetype: modify
replace: olcDbMaxSize
olcDbMaxSize: <new size in bytes>
-

The {N} represents the database number in the slapd configuration directory.

Use the ldapmodify command to set the new value in the configuration:

ldapmodify -xH ldap:/// -D dc=example,dc=com -W -f UpdateDbMaxSize.ldif

The setting takes effect immediately and does not require a restart of slapd or a reload of the backend database.

Increasing maxsize (slapd.conf)

  1. Open the slapd.conf configuration file
  2. Update the value of the maxsize setting with the new value in bytes
  3. Test the configuration change with the slaptest utility:
slaptest -vf /opt/symas/etc/openldap/slapd.conf
  1. If slaptest succeeds, restart the slapd daemon/service; the change will not take effect until this is done.
systemctl restart slapd

See Also

  • slapd-mdb(5) Man Page
  • slapd.conf(5) Man Page
Copyright © 2020-2024 Symas Corporation. All rights reserved.
mdb space

Was this article helpful?

Yes
No
Give feedback about this article

Related Articles

  • How To Get a slapd Stack Trace Using gdb
  • LDAP Return Codes
  • Solving Common Problems
  • Symas Blog RSS Feed
  • Symas on Facebook
  • Symas on Twitter
  • Symas Blog
  • Symas on LinkedIn
  • Symas YouTube Channel

Copyright © 2023, Symas Corporation. All rights reserved. Privacy Statement (updated July 31, 2023)

Phone:

Main Office: +1.650.963.7601
Fax: +1.650.390.6284

Email:

Sales: sales@symas.com
Support: support@symas.com

Office Hours:

8:00 AM - 5:00 PM ET

Office Location:

Symas Corporation
PO Box 391
Grand Junction, CO 81507 USA

Expand