samba configuration via rpc - beyond registry shares

Chetan S cshring at
Thu Jan 4 08:41:24 GMT 2007

On 1/3/07, David Collier-Brown <davec-b at> wrote:

>    As an initial step, one should be able to request the state be
> written out in textual form, so you can use a side-by-side diff
> program to inspect the differences between the registry and the
> smb.conf, and then either commit or abort the changes to both
> the smb.conf and the registry.
This would mean first developing the util to save the metadata (state
and other info ) about an smb.conf and its included files, into a data

>    The latter might be done by evaluating the smb.conf and "pushing"
> the state of it to the registry...
Then would come linking the registry rpc to allow modification of the
parameters and store their values in tdb along with metadata.

>    Think of this as a synchronization problem: one doesn't necessarily
> have a master, one has a way of committing individual changes from
> either to both, and it;s easiest for a Unix person to do that at the
> Samba end.

The idea of cutting off the dependency on smb.conf edits is perhaps
best supported by  Volker's  "config" toggle.

And if the last step (of pushing a smb.conf ) remains manual then
remote configuration via registry would rather be a fancy way of
editing smb.conf  :)

To summarize :
1. Work-up a util like testparm ( m'be extend it ) to save metadata
about parameters and the conf+include files.
2. Use reg api + internal calls to allow an independent "registry"
smb.conf. Here the changes will not be reflected to Samba sessions.
3. Extend the util of step 1 to point the diff between smb.conf and
registry smbconf
4. Create a toggle param in smb.conf to finally enable samba to use
either smb.conf or registry smbconf

Does this sound like a viable approach ?

Chetan S

More information about the samba-technical mailing list