Variable MACHINE.SID

Pablo Alcaraz pabloa at mbasystems.com.ar
Mon Aug 5 13:07:02 GMT 2002


I put a "private dir" statement in the global section but testparm gave 
me a 'unknown parameter encountered'.  :-(

Anyway I wish to use alternatively 2 smb.conf definitions file in the 
same machine using security=domain. I can't and I suspect a problem with 
secrets.tdb stored host password are buzzing when I use the other 
smb.conf configuration file.

Please CC

Regards

Pablo

On Sun, 4 Aug 2002, Steve Langasek wrote:

>/ On Mon, Aug 05, 2002 at 03:31:54AM +0930, Richard Sharpe wrote:
/>/ > On Sun, 4 Aug 2002, Pablo Alcaraz wrote:
/>/ 
/>/ > > I wish that a box can run alternatively 2 samba server configuration 
/>/ > > (smb_a y smb_b).
/>/ 
/>/ > > For this I have 2 smb.conf files (smb.conf.a and smb.conf.b). When I 
/>/ > > need smb_a I rename smb.conf.a => smb.conf and restart samba. The same 
/>/ > > thing for smb_b.
/>/ 
/>/ > > The problem is that my configuration set 'server = domain' and one 
/>/ > > configuration run ok inside of domain and the other does not run (samba 
/>/ > > ask for manual login).
/>/ 
/>/ > > I suspect that the problem is MACHINE.SID. I think I need 2 different 
/>/ > > MACHINE.SID files. Is that correct?
/>/ 
/>/ > > Can I use samba %L variable to indicate a differente MACHINE.SID?
/>/ 
/>/ > There is no way to control where that goes, I believe ...
/>/ 
/>/ > > Does the MACHINE.SID file dependent of the hardware of the server?
/>/ 
/>/ > If Samba finds an existing MACHINE.SID, I believe it uses that. You cannot 
/>/ > have two system on the network with the same machine SID. However, I do 
/>/ > not believe there is a parameter that allows you to control where Samba 
/>/ > will look for this stuff. 
/>/ 
/>/ passdb/machine_sid.c:
/>/         /* check for an old MACHINE.SID file for backwards compatibility */
/>/         asprintf(&fname, "%s/MACHINE.SID", lp_private_dir());
/>/ 
/>/ so adjusting the setting of 'private dir' in smb.conf should do it. 
/>/ (This will also work for versions of Samba that use secrets.tdb, which is
/>/ also found relative to 'private dir'.)
/
I guess I should have looked in the code :-)

Regards
-----
Richard Sharpe, rsharpe at ns.aus.com <mailto:rsharpe at ns.aus.com>, rsharpe at samba.org <mailto:rsharpe at samba.org>, 
sharpe at ethereal.com <mailto:sharpe at ethereal.com>









More information about the samba-technical mailing list