Hi,
I'm new to this mailing list. I have a simple question... I have deployed a huge subscriber ldap database with more than 400 000 entries in a SUSE machine installing OpenLDAP with Yast.
I've found huge log files in /var/lib/ldap that I cannot delete. Google says that I should tune my DB_CONFIG file to optimize the use of the the Berkeley backend, but I don't find this file. Should I create it?
Thanks a lot
Echedey Lorenzo echedey@gmail.com writes:
Hi,
I'm new to this mailing list. I have a simple question... I have deployed a huge subscriber ldap database with more than 400 000 entries in a SUSE machine installing OpenLDAP with Yast.
I've found huge log files in /var/lib/ldap that I cannot delete. Google says that I should tune my DB_CONFIG file to optimize the use of the the Berkeley backend, but I don't find this file. Should I create it?
SUSE comes with a default DB_CONFIG in /var/lib/ldap, the log files are the transaction logs of BerkeleyDB, do not delete these files. If you want to get rid of some old transaction logs, add to DB_CONFIG set_flags DB_LOG_AUTOREMOVE
-Dieter
Thanks for your answer,
My /var/lib/ldap does not contain any DB_CONFIG file except __db.00x, *.bdb and log.000xxx files :(
Should I create it? Where does my Berkeley takes it configuration from? Or maybe it is in another place...
Thanks a lot
2010/2/10 Dieter Kluenter dieter@dkluenter.de
Echedey Lorenzo echedey@gmail.com writes:
Hi,
I'm new to this mailing list. I have a simple question... I have
deployed a
huge subscriber ldap database with more than 400 000 entries in a SUSE
machine
installing OpenLDAP with Yast.
I've found huge log files in /var/lib/ldap that I cannot delete. Google
says
that I should tune my DB_CONFIG file to optimize the use of the the
Berkeley
backend, but I don't find this file. Should I create it?
SUSE comes with a default DB_CONFIG in /var/lib/ldap, the log files are the transaction logs of BerkeleyDB, do not delete these files. If you want to get rid of some old transaction logs, add to DB_CONFIG set_flags DB_LOG_AUTOREMOVE
-Dieter
-- Dieter Klünter | Systemberatung http://dkluenter.de GPG Key ID:8EF7B6C6 53°37'09,95"N 10°08'02,42"E
Echedey Lorenzo echedey@gmail.com writes:
Thanks for your answer,
My /var/lib/ldap does not contain any DB_CONFIG file except __db.00x, *.bdb and log.000xxx files :(
Should I create it? Where does my Berkeley takes it configuration from? Or maybe it is in another place...
If you have setup a configuration backend, than there is no requirement for a DB_CONFIG file as the appropriate database parameters are in olcDatabase={x}bdb.ldif, something like
olcDbConfig: {0}set_cachesize 0 67108864 1 olcDbConfig: {1}set_lg_regionmax 262144 olcDbConfig: {2}set_lg_bsize 2097152 olcDbConfig: {3}set_flags DB_LOG_AUTOREMOVE
If there is no configuration backend and no DB_CONFIG in the database directory, than you should create this file. These are the default SUSE settings:
,----[ DB_CONFIG ] | set_cachesize 0 15000000 1 | set_lg_regionmax 262144 | set_lg_bsize 2097152 | set_flags DB_LOG_AUTOREMOVE `----
but note that you have to recreate the database, it is not sufficient to just add a DB_CONFIG file, this file has to be present when creating the database.
-Dieter
I think the best option, as you suggest, is to recreate everything. Is it enough to remove all /var/lib/ldap contents, restart the ldap service, and populate all again? My intention is to have 8M entries as max.
Thanks for your help
2010/2/11 Dieter Kluenter dieter@dkluenter.de
Echedey Lorenzo echedey@gmail.com writes:
Thanks for your answer,
My /var/lib/ldap does not contain any DB_CONFIG file except __db.00x,
*.bdb and log.000xxx files :(
Should I create it? Where does my Berkeley takes it configuration from? Or maybe it is in another place...
If you have setup a configuration backend, than there is no requirement for a DB_CONFIG file as the appropriate database parameters are in olcDatabase={x}bdb.ldif, something like
olcDbConfig: {0}set_cachesize 0 67108864 1 olcDbConfig: {1}set_lg_regionmax 262144 olcDbConfig: {2}set_lg_bsize 2097152 olcDbConfig: {3}set_flags DB_LOG_AUTOREMOVE
If there is no configuration backend and no DB_CONFIG in the database directory, than you should create this file. These are the default SUSE settings:
,----[ DB_CONFIG ] | set_cachesize 0 15000000 1 | set_lg_regionmax 262144 | set_lg_bsize 2097152 | set_flags DB_LOG_AUTOREMOVE `----
but note that you have to recreate the database, it is not sufficient to just add a DB_CONFIG file, this file has to be present when creating the database.
-Dieter
-- Dieter Klünter | Systemberatung http://dkluenter.de GPG Key ID:8EF7B6C6 53°37'09,95"N 10°08'02,42"E
----- Echedey Lorenzo echedey@gmail.com wrote:
I think the best option, as you suggest, is to recreate everything. Is it enough to remove all /var/lib/ldap contents, restart the ldap service, and populate all again? My intention is to have 8M entries as max.
Thanks for your help
There is zero need to recreate everything. Dieter is wrong. Simply stop slapd, create the DB_CONFIG file, run db_recover to regenerate the bdb database profile, then start slapd. This has been the standard way to do this since OpenLDAP 2.1. Dieter should know this.
--Quanah
2010/2/11 Dieter Kluenter dieter@dkluenter.de
Echedey Lorenzo echedey@gmail.com writes:
Thanks for your answer,
My /var/lib/ldap does not contain any DB_CONFIG file except __db.00x,
*.bdb and log.000xxx files :(
Should I create it? Where does my Berkeley takes it configuration from? Or maybe it is in another place...
If you have setup a configuration backend, than there is no requirement for a DB_CONFIG file as the appropriate database parameters are in olcDatabase={x}bdb.ldif, something like
olcDbConfig: {0}set_cachesize 0 67108864 1 olcDbConfig: {1}set_lg_regionmax 262144 olcDbConfig: {2}set_lg_bsize 2097152 olcDbConfig: {3}set_flags DB_LOG_AUTOREMOVE
If there is no configuration backend and no DB_CONFIG in the database directory, than you should create this file. These are the default SUSE settings:
,----[ DB_CONFIG ] | set_cachesize 0 15000000 1 | set_lg_regionmax 262144 | set_lg_bsize 2097152 | set_flags DB_LOG_AUTOREMOVE `----
but note that you have to recreate the database, it is not sufficient to just add a DB_CONFIG file, this file has to be present when creating the database.
-Dieter
-- Dieter Klünter | Systemberatung http://dkluenter.de GPG Key ID:8EF7B6C6 53°37'09,95"N 10°08'02,42"E
--
| Echedey Lorenzo Arencibia |
Thanks Quanah,
I'm going to try your method, hope it works as it seems much faster. Otherwise I should recreate all the directory
Kind Regars
2010/2/11 Quanah Gibson-Mount quanah@zimbra.com
----- Echedey Lorenzo echedey@gmail.com wrote:
I think the best option, as you suggest, is to recreate everything. Is it enough to remove all /var/lib/ldap contents, restart the ldap service,
and
populate all again? My intention is to have 8M entries as max.
Thanks for your help
There is zero need to recreate everything. Dieter is wrong. Simply stop slapd, create the DB_CONFIG file, run db_recover to regenerate the bdb database profile, then start slapd. This has been the standard way to do this since OpenLDAP 2.1. Dieter should know this.
--Quanah
2010/2/11 Dieter Kluenter dieter@dkluenter.de
Echedey Lorenzo echedey@gmail.com writes:
Thanks for your answer,
My /var/lib/ldap does not contain any DB_CONFIG file except __db.00x,
*.bdb and log.000xxx files :(
Should I create it? Where does my Berkeley takes it configuration from? Or maybe it is in another place...
If you have setup a configuration backend, than there is no requirement for a DB_CONFIG file as the appropriate database parameters are in olcDatabase={x}bdb.ldif, something like
olcDbConfig: {0}set_cachesize 0 67108864 1 olcDbConfig: {1}set_lg_regionmax 262144 olcDbConfig: {2}set_lg_bsize 2097152 olcDbConfig: {3}set_flags DB_LOG_AUTOREMOVE
If there is no configuration backend and no DB_CONFIG in the database directory, than you should create this file. These are the default SUSE settings:
,----[ DB_CONFIG ] | set_cachesize 0 15000000 1 | set_lg_regionmax 262144 | set_lg_bsize 2097152 | set_flags DB_LOG_AUTOREMOVE `----
but note that you have to recreate the database, it is not sufficient to just add a DB_CONFIG file, this file has to be present when creating the database.
-Dieter
-- Dieter Klünter | Systemberatung http://dkluenter.de GPG Key ID:8EF7B6C6 53°37'09,95"N 10°08'02,42"E
--
| Echedey Lorenzo Arencibia |
-- Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc
Zimbra :: the leader in open source messaging and collaboration
Quanah Gibson-Mount quanah@zimbra.com writes:
----- Echedey Lorenzo echedey@gmail.com wrote:
I think the best option, as you suggest, is to recreate everything. Is it enough to remove all /var/lib/ldap contents, restart the ldap service, and populate all again? My intention is to have 8M entries as max.
Thanks for your help
There is zero need to recreate everything. Dieter is wrong. Simply stop slapd, create the DB_CONFIG file, run db_recover to regenerate the bdb database profile, then start slapd. This has been the standard way to do this since OpenLDAP 2.1. Dieter should know this.
I have experienced some problems in the past, that's why I prefer a clean recreation.
-Dieter
--On Thursday, February 11, 2010 7:21 PM +0100 Dieter Kluenter dieter@dkluenter.de wrote:
Quanah Gibson-Mount quanah@zimbra.com writes:
----- Echedey Lorenzo echedey@gmail.com wrote:
I think the best option, as you suggest, is to recreate everything. Is it enough to remove all /var/lib/ldap contents, restart the ldap service, and populate all again? My intention is to have 8M entries as max.
Thanks for your help
There is zero need to recreate everything. Dieter is wrong. Simply stop slapd, create the DB_CONFIG file, run db_recover to regenerate the bdb database profile, then start slapd. This has been the standard way to do this since OpenLDAP 2.1. Dieter should know this.
I have experienced some problems in the past, that's why I prefer a clean recreation.
Then you should have collected data and filed an ITS. I've never had a problem in nearly 10 years of configuring and modifying DB_CONFIG files back to 2.1.4 when it's done correctly.
--Quanah
--
Quanah Gibson-Mount Principal Software Engineer Zimbra, Inc -------------------- Zimbra :: the leader in open source messaging and collaboration
openldap-technical@openldap.org