[SOLVED] Mageia 6 config 389-ds

This forum is dedicated to advanced help and support :

Ask here your questions about advanced usage of Mageia. For example you may post here all your questions about network and automated installs, complex server configurations, kernel tuning, creating your own Mageia mirrors, and all tasks likely to be touchy even for skilled users.

[SOLVED] Mageia 6 config 389-ds

Postby borg » Mar 13th, '19, 12:29

I have problem configure 389-ds.
When run script setup-ds-admin.pl return error when Creating directory server:
Code: Select all
[19/03/13:10:02:08] - [Setup] Info Creating directory server . . .
[19/03/13:10:02:16] - [Setup] Info Could not import LDIF file '/root/tmp/ldifaSUHXD.ldif'.  Error: 59648.  Output: importing data ...
[13/Mar/2019:10:02:10.295369058 +0100] slapd_nss_init: chmod failed for file /etc/dirsrv/slapd-ldap1/cert8.db error (2) No such file or directory.
[13/Mar/2019:10:02:10.302394454 +0100] slapd_nss_init: chmod failed for file /etc/dirsrv/slapd-ldap1/key3.db error (2) No such file or directory.
[13/Mar/2019:10:02:10.304457731 +0100] slapd_nss_init: chmod failed for file /etc/dirsrv/slapd-ldap1/secmod.db error (2) No such file or directory.
[13/Mar/2019:10:02:10.322433900 +0100] WARNING: Import is running with nsslapd-db-private-import-mem on; No other process is allowed to access the database
[13/Mar/2019:10:02:10.325411419 +0100] check_and_set_import_cache: pagesize: 4096, pages: 252519, procpages: 4870
[13/Mar/2019:10:02:10.327366972 +0100] WARNING: After allocating import cache 230504KB, the available memory is 779572KB, which is less than the soft limit 1048576KB. You may want to decrease the import cac
he size and rerun import.
[13/Mar/2019:10:02:10.330135857 +0100] Import allocates 230504KB import cache.
[13/Mar/2019:10:02:10.349031316 +0100] import userRoot: Beginning import job...
[13/Mar/2019:10:02:10.351070828 +0100] import userRoot: Index buffering enabled with bucket size 100
[13/Mar/2019:10:02:10.552953077 +0100] import userRoot: Could not open LDIF file "/root/tmp/ldifaSUHXD.ldif", errno 13 (Permission denied)
[13/Mar/2019:10:02:10.654084236 +0100] import userRoot: Thread monitoring returned: -23

[13/Mar/2019:10:02:10.657275535 +0100] import userRoot: Aborting all Import threads...
[13/Mar/2019:10:02:16.165561052 +0100] import userRoot: Import threads aborted.
[13/Mar/2019:10:02:16.168799315 +0100] import userRoot: Closing files...
[13/Mar/2019:10:02:16.174550800 +0100] All database threads now stopped
[13/Mar/2019:10:02:16.177479893 +0100] import userRoot: Import failed.

[19/03/13:10:02:16] - [Setup] Fatal Error: Could not create directory server instance 'ldap1'.
[19/03/13:10:02:16] - [Setup] Fatal Exiting . . .
Log file is '/root/tmp/setupKsCJLW.log'


File /etc/dirsrv/slapd-ldap1/cert8.db and key3.db not exist because certutil generate newer cert9.db and key4.db.
Do you advise me how to configure the directory server?
Last edited by borg on Mar 14th, '19, 18:22, edited 1 time in total.
Resistance is futile! Open your source code.
borg
 
Posts: 4
Joined: Mar 5th, '15, 12:46

Re: Mageia 6 config 389-ds

Postby doktor5000 » Mar 14th, '19, 16:19

borg wrote:[13/Mar/2019:10:02:10.552953077 +0100] import userRoot: Could not open LDIF file "/root/tmp/ldifaSUHXD.ldif", errno 13 (Permission denied)


I believe this is why it fails. Although it would help if you add some context information, including the full comand for setup-ds-admin.pl you used or the documentation you're following.
Although I don't know 389 ds myself, I believe you should first run setup-ds.pl instead.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 14660
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Mageia 6 config 389-ds

Postby borg » Mar 14th, '19, 18:21

certutil creates sqlite database by default (cert9.db and key4.db)
To set legacy database type as the default type for the certutil, set the NSS_DEFAULT_DB_TYPE environment variable to dbm:
Code: Select all
export NSS_DEFAULT_DB_TYPE="dbm"

Default command:
Code: Select all
certutil -N -d /home/user

Command for the newer database:
Code: Select all
certutil -N -d sql:/home/user

Command for the legacy database:
Code: Select all
certutil -N -d dbm:/home/user


problem is environment variable TMPDIR=/root/tmp
Code: Select all
[14/Mar/2019:13:36:08.262246151 +0100] import userRoot: Could not open LDIF file "/root/tmp/ldifmXrL6r.ldif", errno 13 (Permission denied)


problem solved:
Code: Select all
export NSS_DEFAULT_DB_TYPE="dbm"
export TMPDIR=/tmp
setup-ds-admin.pl
Last edited by borg on Mar 15th, '19, 12:51, edited 1 time in total.
Resistance is futile! Open your source code.
borg
 
Posts: 4
Joined: Mar 5th, '15, 12:46

Re: Mageia 6 config 389-ds

Postby doktor5000 » Mar 14th, '19, 18:52

borg wrote:problem solved:
Code: Select all
export NSS_DEFAULT_DB_TYPE="dbm"
export TMPDIR=/tmp
setup-ds-admin.pl



You may want to report this as a bug so that it may get fixed. Check https://wiki.mageia.org/en/How_to_report_a_bug_properly
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 14660
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany


Return to Advanced support

Who is online

Users browsing this forum: No registered users and 1 guest