CTDB -- manually setting winbind uid with wbinfo

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

CTDB -- manually setting winbind uid with wbinfo

Bob Cregan
Hi
         We have a ctdb cluster setup as follows

ctdb version -- surprisingly difficult to determine. I think it is
1.0.99 (dragged from a include file somewhere, I forget where exactly ).
If anyone can tell me how to determine this proberly then I would be
pleased to know.

samba version 3.5.8

I was hoping to be able to set the UID to SID mapping manually using the
following procedure.

get the SID:

wbinfo -n domain\\<username>
S-1-5-21-1117850145-XXXXXXXX-XXXXXXX-220398 SID_USER (1)

Then set the SID to map to a desired UID rather than the random one chosen

[root@filer01-ph ctdb]# wbinfo
--set-uid-mapping=198000,S-1-5-21-1117850145-XXXXXXXX-XXXXXXX-220398
Could not create or modify uid to sid mapping
[root@filer01-ph ctdb]

I have tried deleting the old mapping beforehand and clearing the cache

[root@filer01-ph ctdb]# wbinfo -i <domain>\\<username>
<username>:*:100000:100002::/home/<domain>/<username>:/bin/false
[root@filer01-ph ctdb]

[root@filer01-ph ctdb]# net cache flush
[root@filer01-ph ctdb]# net cache list
[root@filer01-ph ctdb]#

[root@filer01-ph ctdb]# wbinfo
--remove-uid-mapping=100000,S-1-5-21-1117850145-XXXXXXXX-XXXXXXX-220398
Could not remove uid to sid mapping
[root@filer01-ph ctdb]#

[root@filer01-ph ctdb]# wbinfo
--set-uid-mapping=198000,S-1-5-21-1117850145-XXXXXXXX-XXXXXXX-220398
Could not create or modify uid to sid mapping
[root@filer01-ph ctdb]


Is this a bug or am I misunderstanding how the SID to UID mapping works.

Relevant bits of the smb.conf are below


Thanks

Bob

         usershare allow guests = No
         idmap uid = 100000-200000
         idmap gid = 100000-200000
         winbind rpc only = yes
         winbind enum users = yes
         winbind enum groups = yes
         client use spnego = yes
         client ntlmv2 auth = yes
         encrypt passwords = yes
         winbind use default domain = yes
         winbind refresh tickets = yes
         restrict anonymous = 2
         template homedir = /home/%D/%U
         template shell = /bin/false




--
Bob Cregan
Senior Storage Systems Administrator
ACRC
Bristol University
Tel:     +44 (0) 117 331 4421
Mobile: +44 (0) 7712388129

--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba
Reply | Threaded
Open this post in threaded view
|

Re: CTDB -- manually setting winbind uid with wbinfo

koutsane
Hi Bob,

I was wondering if you were able to manually update/create the UID / GID mappings with wbinfo --set-uid-mapping ?

I am also using CTDB samba and being able to manually set / update the IdMap would save me a lot of time in a DR situation.

Thank-you and best regards,

Evan