Log inUsernamePassword
Log me on automatically each visit    
Register
Register
Log in to check your private messages
Log in to check your private messages
SMS Forum Index » SMS User Support

Post new topic   Reply to topic
OpenLDAP question
View previous topic :: View next topic  
Author Message
toothandnail
Member


Joined: 17 Mar 2011
Posts: 63
Location: Oxfordshire, UK

PostPosted: Sun Apr 03, 2011 1:57 pm    Post subject: OpenLDAP question Reply with quote

Sorry, more dumb questions. I'm too used to packages like SME which hide a lot of the configuration. Lots of learning still to do....

I noticed while exploring Webmin that it was complaining about being unable to log into the OpenLDAP server due to an encrypted password. I couldn't find any reference to the password for the OpenLDAP server, but I did find this in the Wiki:

Code:
ldapadd  -f  /etc/openldap/sms.ldif  -x  -D  cn=Manager,dc=[yourhostname],dc=[yourdomain]  -w  toor


as something that should be run after first boot. Is this still a requirement, or is there some other way of settting or changing the OpenLDAP password?

Paul.
Back to top
View user's profile Send private message
gerasimos_h
Site Admin


Joined: 09 Aug 2007
Posts: 1752
Location: Greece

PostPosted: Sun Apr 03, 2011 2:27 pm    Post subject: Reply with quote

Password is toor also stated as
PHPLdapAdmin: toor
in default passwords.
You can change it through webmin or with slappasswd as described in Securing and Optimizing SMS
You can edit module config of webmin/ldap server and add the ldap password.

When running netconfig or netconfig-lcd, it edit /etc/openldap/sms.ldif and replace sms.org with your hostname.domain, but netconfig run at installation so slapd isn't running so can't flush db and recreate it, that's why the ldapadd command.
So either skip netconfig and run netconfig-lcd after your first boot or import database manually with ldapadd.

netconfig replace sms.org with your new hostname.domain
netconfig-lcd replace your current hostname.domain with your new hostname.domain

gerasimos_h

_________________
Superb! Mini Server Project Manager
http://sms.it-ccs.com
Back to top
View user's profile Send private message Visit poster's website
janekX
Junior Member


Joined: 17 Apr 2011
Posts: 5

PostPosted: Sun Apr 17, 2011 5:48 pm    Post subject: catastrophic disaster Reply with quote

have changed passwd in PHPMyAdmin
then have changed passwd by slappasswd and placed it into slapd.conf
and i did use the netconfig-lcd

...still can't use ldap, looks like need to study openldap doc
Back to top
View user's profile Send private message
gerasimos_h
Site Admin


Joined: 09 Aug 2007
Posts: 1752
Location: Greece

PostPosted: Sun Apr 17, 2011 9:48 pm    Post subject: Reply with quote

I believe you mean phpldapadmin and not phpmyadmin.
Once you log in in phpldapadmin change the password for
cn=Manager and uid=administrator
The password in slapd.conf has to do with ldap and other programs, but
you need to alter the password for cn=Manager in phpldapadmin too.
and of course restart openldap
Code:
/etc/rc.d/rc.openldap restart


gerasimos_h

_________________
Superb! Mini Server Project Manager
http://sms.it-ccs.com
Back to top
View user's profile Send private message Visit poster's website
janekX
Junior Member


Joined: 17 Apr 2011
Posts: 5

PostPosted: Mon Apr 18, 2011 11:00 pm    Post subject: Reply with quote

gerasimos_h wrote:
I believe you mean phpldapadmin and not phpmyadmin.
Once you log in in phpldapadmin change the password for
cn=Manager and uid=administrator
The password in slapd.conf has to do with ldap and other programs, but
you need to alter the password for cn=Manager in phpldapadmin too.
and of course restart openldap
Code:
/etc/rc.d/rc.openldap restart


gerasimos_h


pardon me, i have changed passwd in Webmin,
then I did follow ur steps,
of course i restarted the openldap server,
when I log-in into phpLDAPadmin
it says on left hand side: dc=...,dc=... -doesn't exits, create..
the hyper link refers to javascript:document.create_base_form_1.submit()
-but nothing happens when I'm clicking on it..

so, now I'm completely confused, I have no clue what and where
better of, to start it since beginning my self
Back to top
View user's profile Send private message
janekX
Junior Member


Joined: 17 Apr 2011
Posts: 5

PostPosted: Tue Apr 19, 2011 12:15 am    Post subject: Reply with quote

did read some text from openldap doc
so I have found that I have to enter passwd in Webmin LdapServerConfiguration
::Password for root user, so I see LDAP Users and Groups but can't
add user or group:
Failed to save group : Failed to add group to LDAP database : objectClass: value #1 invalid per syntax
-with Samba group=Yes, and without :
Failed to save group : Failed to add group to LDAP database : no global superior knowledge

as toothandnail said...lots of learning still...

don't want to spam here, b.r.
Back to top
View user's profile Send private message
gerasimos_h
Site Admin


Joined: 09 Aug 2007
Posts: 1752
Location: Greece

PostPosted: Tue Apr 19, 2011 8:52 am    Post subject: Reply with quote

janekX wrote:
when I log-in into phpLDAPadmin
it says on left hand side: dc=...,dc=... -doesn't exits, create..

If info is missing your ldap db is empty, use

Code:
ldapadd  -f  /etc/openldap/sms.ldif  -x  -D  cn=Manager,dc=[yourhostname],dc=[yourdomain]  -w  [yourpassword]

to create the initial database.
If ldap is running by pressing create.. in phpldapadmin it should create the top directory and then you can import your sms.ldif.

gerasimos_h

_________________
Superb! Mini Server Project Manager
http://sms.it-ccs.com
Back to top
View user's profile Send private message Visit poster's website
janekX
Junior Member


Joined: 17 Apr 2011
Posts: 5

PostPosted: Tue Apr 19, 2011 10:22 pm    Post subject: Reply with quote

really strange, nothing happens when I click create... ldap is running

when I use
ldapadd -f /etc/openldap/sms.ldif -x -D cn=Manager,dc=[yourhostname],dc=[yourdomain] -w [yourpassword]
it says:
ldap_add: Naming violation (64)
additional info: value of single-valued naming attribute 'dc' conflicts with value present in entry
i will try from beginning..but need to learn/rad about those things from openldap
doc,
Back to top
View user's profile Send private message
janekX
Junior Member


Joined: 17 Apr 2011
Posts: 5

PostPosted: Tue Apr 19, 2011 10:28 pm    Post subject: Reply with quote

janekX wrote:
really strange, nothing happens when I click create... ldap is running

when I use
ldapadd -f /etc/openldap/sms.ldif -x -D cn=Manager,dc=[yourhostname],dc=[yourdomain] -w [yourpassword]
it says:
ldap_add: Naming violation (64)
additional info: value of single-valued naming attribute 'dc' conflicts with value present in entry
i will try from beginning..but need to learn/rad about those things from openldap
doc,


Webmin->New administration password->Set to..
let's me to create Root DN...look fine so far Wink
thx _4 ur time, b.r.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    SMS Forum Index » SMS User Support All times are GMT + 2 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

SMS - Superb! Mini Server Project © 2016
Powered by phpBB © 2001, 2002 phpBB Group
iCGstation v1.0 Template By Ray © 2003, 2004 iOptional