[Samba] The Recycled PIDs Fix
Volker.Lendecke at SerNet.DE
Fri Jan 20 06:38:30 MST 2012
On Fri, Jan 20, 2012 at 04:38:21AM -0700, Manoj Dahal wrote:
> This is regarding your fix on recycled PIDs. I am an NCP
> developer from Novell and we use libsmbsharemodes library
> from Samba for Cross Protocols Locks between NCP, Samba
> and others. I have few queries regarding your fix.
> In your fix, you have added a new field called 'unique_id'
> in the server_id structure
> and we need to pass this in our call to samba share mode
> APIs e.g. create_share_mode_entry().
> Also, you have introduced server
> registration/de-registration which is associated with
> 'unqiue_id'. If we use these new APIs
> then in which library from Samba do we need to link to?
> Or without calling serverid_register() can we directly
> pass any 'unique_id'
> while calling to create_share_mode_entry() and in that
> case whether this and other share mode APIs will work
If you pass a random unique_id, the share mode entry will be
wiped once smbd reads it. You have to invent a unique_id,
fill a struct server_id with it and call serverid_register()
before using it. serverid_deregister() will remove that
registration again. Unfortunately we don't provide an API
to that functionality via libsmbsharemodes. It's not rocket
science, and I would be happy to relicense my contribution
to serverid.c under LGPL for inclusion into
libsmbsharemodes. The problem there is that serverid.c is
based on dbwrap for clustering, which libsmbsharemodes is
not. So you will have to rewrite significant portions of
serverid.c to directly open the tdb file.
With best regards,
SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
http://www.sernet.de, mailto:kontakt at sernet.de
More information about the samba