samba config registry rpc - proposal

Chetan D Shringarpure chetan.sh at in.ibm.com
Wed Sep 20 11:29:17 GMT 2006


Hi All,

I am currently working on making Samba 3 configurable via registry rpc 
with two targets in mind.

A short term target : to add means in Samba 3 to add and delete shares in 
registry via rpc. For simplicity I would call them registry shares.

The long term target is to make the entire scope of Samba parameters / 
configuration accessible via registry rpc.

Here is a breakdown for the short term target : 
================================
1. Add hooks in the registry to allow creation of new "registry" shares in 
the registry hence samba.
2. Extend the net util to invoke these hooks to create / delete new 
registry shares.
3. Add hooks in the registry to allow listing of these registry shares.
4. Export the usershares and smb.conf shares as a legacy subkey 
5. Create a separate hive for samba config with either smbconf.tdb as 
backend or libelektra.

So in effect it should be possible to create / delete shares via registry 
using regedit from windows end and net util from the linux end.

The end result should look something as below : (please excuse the ascii 
graphics)

Subkey structure :
HKLM -\
          --- Samba-\
                          --- regshares -\
                                                --- share name
                          --- legacy -\
                                          --- usershares
                                          --- smb.conf shares

For the share name subkey the "value" pane would contain the parameters 
and their values.

Advantages of this solution :
=================
It should allow an admin to create / delete new shares in samba via the 
regedit (windows) or using any utility which can invoke the registry rpc. 
Later this can be extended to allow configuration of Samba itself via 
registry.
Also there is a possibility to allow per share configuration access levels 
if the registry model is followed.

My questions :
=========
1. Is this idea worth following ?
2. Should the registry interface instead use the usershare api internally 
instead ?
3. Is it a good idea to store the info "registry" shares in tdb ? Or is 
libelektra instead a better option ?

Looking for suggestions and direction. :)


best regards,

Chetan Shringarpure
IBM India Pvt. Ltd.


More information about the samba-technical mailing list