[Samba] Help ! Logon script doesn't work on XP
robert at ruegner.org
Fri Apr 9 23:37:41 GMT 2004
M. Vancl schrieb:
> I have very strange problem:
> I had created logon script (bat file dynamically generated by root peexec)
> and tested it successfully on Win98 workstation.
> Now I'm testing it on XP wkst., but the same (created by the same method)
> script is during logon not executed.
> What is absolutely mysterious for me ? The script is really read by
> workstation durin logon - I saw it in network traffic (caught by tcpdump and
> displayed by ethereal).
> Here is copy of current script (of course - every line o file ends with
> --- snip ---
> @echo off
> set CLIENT=prog01t
> set USER=p01861
> set SERVER=sambaii
> set SMBPID=24631
> set ARCH=WinXP
> copy /b z:\logon.bat %TEMP%\logon.bat
> --- snip ---
> After logon there is no file %TEMP%\logon.bat.
> Next, when I manually do "net use z: \\sambaii\netlogon" and execute my
> logon script from there, everything is done by my wishes...
> Does have anybody some idea ?
> Thanks for any advice
> M. Vancl
hi, what is this with copy etc, place you bat file ( must be written in
dos editor ) in a netlogon share on samba , make it readable and it will
executed, for sure you can create the scipt on the fly with perl as
prexec to that share ( example in the samba source ) but after that ( if
you have the right parameter in smb.conf the script will be executed by
the win client automaticly ....no need for net use and copy it to the
client ,after all some win versions need diffrent syntax with bat files
i think your special failure depend on user rights on the win machine ,
xp as multiuser system want to have admin rights to execute your bat ,
check your event log
More information about the samba