Jean-Jacques Moulis a �crit :

On Mon, 07 Mar 2005 09:57:47 +0000 Clement DIEBOLD <[EMAIL PROTECTED]> wrote:

CD> >CD> >>>> Then, if I put :
CD> >CD> >> @echo off
CD> >CD> >> echo "Script de demarrage"
CD> >CD> >> net use T: \\PDC\temp /PERSISTENT:NO
CD> >CD> >>
CD> >CD> >> Then, if the PDC becomes down, this script wouldn't work and i must CD> >CD> >> be there to change the name of the server in the script.
CD> >CD> >>
CD> >CD> >> So, what should I do ??
CD> >CD> >>
CD> >CD> >> Thanks for the responses.
CD> >CD> >>
CD> >CD> > Any idea ??
CD> >CD> >
CD> >CD> > Thanks
CD> >CD> CD> >CD> Nobody :(
CD> >
CD> > A preexec script on the BDC netlogon share could modify the logon script
CD> >according to the availability of the PDC.
CD> > CD> >
CD> Can you give me an example of the preexec script please?


in smb.conf
......
[netlogon]
.....
       browseable = no
       public = no
       root preexec = search_for_life_signs
....


search_for_life_signs:

#! /bin/sh
if ping PDC > /dev/null 2>&1 ; then
cp epitaph_for_the_PDC LOGON.BAT
fi


Even if you are located at a place with such mournful connotation I don't think your PDC will expire so often.


This idea of a preexec script is not that good after all
Instead of a preexec script you should run a cron job on the BDC that make the 
LOGON.BAT
change when the PDC is unavailable.

You should also have a better check than ping, perhaps something with smbclient.
The check should also allow for some transient failures of the PDC.
The change should be oneway, I suppose, you probably want to know where the most
recent data is.







CD> -- CD> Cl�ment DIEBOLD
CD> Service Informatique
CD> LMARC Universit� de Franche-Comt�
CD> 24, chemin de l'Epitaphe
CD> 25000 Besan�on
CD> Tel : 03 81 66 60 53
CD> Fax : 03 81 66 67 00


OK, but know how to change the
  logon home = \\%L\%U
  logon path = \\%L\Profiles\%U
in my smb.conf when the PDC is down?

Thanks for your answers.

--
Cl�ment DIEBOLD
Service Informatique
LMARC Universit� de Franche-Comt�
24, chemin de l'Epitaphe
25000 Besan�on
Tel : 03 81 66 60 53
Fax : 03 81 66 67 00
--

--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/listinfo/samba

Reply via email to