PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : Samba SID ??



skydriver
10.07.03, 15:47
Hossa,

ich hab versucht via LDAP einen User in die DB zu addn der in der ObjectClass
"sambaSamAccount" ist.

jetz bekomm ich die fehlermeldung das diese objectClass das attribute "sambaSID" benoetigt.

nun ist meine frage, wo ich diese sambaSID fuer den jeweiligen user auslesen kann?



gruß
skydriver

mamue
10.07.03, 17:47
Warum fügst Du die Accounts nicht mit smbpasswd ein? Mit samba3beta2 geht das hervorragend, sofern bereits ein posixAccount angelegt ist.

mamue

skydriver
10.07.03, 19:51
ich will nen PDC ueber Samba laufen lassn ... was soweit schon laeuft.

LDAP brauch ich halt, damit ich ne zentrale-userverwaltung hab
und da will er fuer den DB-Eintrag halt die sambaSID des jeweiligen users haben.

deswegen muesste ich wissn wo diese abgespeichert wird...


ich hab zwar was im inet gefunden das da so ne datei names machine.SID erstellt werden soll, nur is das net der fall ... und meine configs stimmen...

btw samba-version is 3.0.0beta2 und OpenLDAP2.1.9

mamue
11.07.03, 08:41
wenn Du passwd backend = ldapsam:... angegeben hast, fügt smbpasswd die Acoounts in den ldap ein.

mamue

skydriver
11.07.03, 09:14
in die smb.conf oda wo kommt des rein?


btw

cd /usr/local/samba/bin
./pdbedit -Lv <username>

so bekommt ma nen ueberblicken ueber den user und dort steht auch seine user SID und die gruppen SID ;)

skydriver
11.07.03, 09:18
jo smb.conf ... hab grad n bsp-file gefunden


thx

skydriver
11.07.03, 09:27
habs des jetz in die smb.conf reingeschrieben und mal nen test gemacht .. nur bekomm ich da jetz n fehler ausgegeben

---- snip ----
[root@linux bin]# ./smbpasswd -a smbtest2 -e
fetch_ldap_pw: neither ldap secret retrieved!
ldap_connect_system: Failed to retrieve password from secrets.tdb
Connection to LDAP Server failed for the 1 try!
smbldap_search_suffix: Problem during the LDAP search: (unknown) (Invalid credentials)
New SMB password:
Retype new SMB password:
fetch_ldap_pw: neither ldap secret retrieved!
ldap_connect_system: Failed to retrieve password from secrets.tdb
Connection to LDAP Server failed for the 1 try!
smbldap_search_suffix: Problem during the LDAP search: (unknown) (Invalid credentials)
fetch_ldap_pw: neither ldap secret retrieved!
ldap_connect_system: Failed to retrieve password from secrets.tdb
Connection to LDAP Server failed for the 1 try!
ldapsam_search_one_group: Problem during the LDAP search: LDAP error: (unknown) (Invalid credentials)fetch_ldap_pw: neither ldap secret retrieved!
ldap_connect_system: Failed to retrieve password from secrets.tdb
Connection to LDAP Server failed for the 1 try!
smbldap_search_suffix: Problem during the LDAP search: (unknown) (Invalid credentials)
Failed to add entry for user smbtest2.
Failed to modify password entry for user smbtest2
[root@linux bin]#

---- snip ----


woran koennte das liegen?

mamue
11.07.03, 09:57
Hast Du samba das ldap-admin passwort gegeben (/path/mySamba/smbpasswd -w passwort)?

mamue

skydriver
11.07.03, 10:27
hehe natuerlich nicht *gg*

danke ;)

skydriver
11.07.03, 10:53
so, ein weiteres prob

ich wollte jetz einen maschinen-account anlegen, damit ich meine WS in der Domain mit der entsprechenden sufix anmelden kann.

---- snip ----

[root@linux bin]# ./pdbedit -a -m mobil6$
failed to bind to server with dn= Error: Invalid credentials

Connection to LDAP Server failed for the 1 try!
LDAP search failed: Invalid credentials
Unable to open passdb
failed to bind to server with dn= Error: Invalid credentials

Connection to LDAP Server failed for the 1 try!
smbldap_search_suffix: Problem during the LDAP search: (unknown) (Invalid credentials)
Unable to add machine! (does it already exist?)
[root@linux bin]#

---- snip ----

nein, er existiert noch nicht.

ausschnitt aus dem SLAPd-Logfile

---- snip ----

Jul 11 09:51:15 linux slapd[5097]: daemon: conn=66 fd=11 connection from IP=127.0.0.1:32895 (IP=0.0.0.0:389) accepted.
Jul 11 09:51:15 linux slapd[5097]: conn=66 op=0 BIND dn="" method=128
Jul 11 09:51:15 linux slapd[5097]: conn=66 op=0 RESULT tag=97 err=49 text=
Jul 11 09:51:15 linux slapd[5097]: daemon: conn=67 fd=13 connection from IP=127.0.0.1:32896 (IP=0.0.0.0:389) accepted.
Jul 11 09:51:15 linux slapd[5097]: conn=66 op=1 UNBIND
Jul 11 09:51:15 linux slapd[5097]: conn=66 fd=11 closed
Jul 11 09:51:15 linux slapd[5097]: conn=67 op=0 BIND dn="" method=128
Jul 11 09:51:15 linux slapd[5097]: conn=67 op=0 RESULT tag=97 err=0 text=
Jul 11 09:51:15 linux slapd[5097]: conn=67 op=1 SRCH base="dc=example,dc=com" scope=2 filter="(&(objectClass=posixAccount)(ui
d=mobil6$))"
Jul 11 09:51:15 linux slapd[5097]: conn=67 op=1 RESULT tag=101 err=32 text=
Jul 11 09:51:15 linux slapd[5097]: daemon: conn=68 fd=11 connection from IP=127.0.0.1:32897 (IP=0.0.0.0:389) accepted.
Jul 11 09:51:15 linux slapd[5097]: conn=68 op=0 BIND dn="" method=128
Jul 11 09:51:15 linux slapd[5097]: conn=68 op=0 RESULT tag=97 err=49 text=
Jul 11 09:51:15 linux slapd[5097]: conn=67 fd=13 closed
Jul 11 09:51:15 linux slapd[5097]: conn=68 op=1 UNBIND
Jul 11 09:51:16 linux slapd[5097]: conn=68 fd=11 closed

---- snip ----

dort sieht man, dass er was von "dc=example,dc=com" will, was natuerlich net stimmt weils des garnet gibt ...

woher bezieht der seine info's im dem dc=**** , eigendlich doch aus der smb.conf aba da is ja der richtige string drinne

wie umgeh ich des, oda wie add ich richtig nen maschinen-account?

skydriver
11.07.03, 15:07
ok, der fehler lag an dem abgleich sambauser -> LDAP

in der smb.conf

passdb backend = ldapsam:ldap://localhost:389

mamue
11.07.03, 18:14
Vergiss ", guest" nicht:
passdb backend = ldapsam:ldap://localhost:389, guest

mamue