[Samba] login script = login.bat

robowarp at gmx.de robowarp at gmx.de
Fri Aug 29 15:09:42 GMT 2003


Hi Sambatistas,
i have samba 3 as pdc running which creates needed *.bat files by
genlogon.pl
on the fly, my Problem was that it seems only to give one parameter
to samba option login script = i.e %u.bat
so i decide to run the combinate from %u.bat %m.bat %G.bat in the login
script
here it is maybe someone needs it, it was made to fit to my needs and not
good tested but works

@echo off
rem by robowarp at gmx.de leave to public as it is , dont think of asking me
rem  created for samba 3 login, the bat files were creted on the fly by
genlogin.pl
rem  this script is only valid for win2000/NT/XP
rem exec bat for logged in machine ( maybe software status or machine data )
echo %COMPUTERNAME%
call %COMPUTERNAME%.bat
rem exec bat for login user
echo %USERNAME%
call %USERNAME%.bat
rem exec bat for different groups
rem ifmember.exe must be in the netlogon share download it at microschrott
ifmember Administrators
if errorlevel 1 call Administrators.bat 
ifmember users
if errorlevel 1 call users.bat

-- 
COMPUTERBILD 15/03: Premium-e-mail-Dienste im Test
--------------------------------------------------
1. GMX TopMail - Platz 1 und Testsieger!
2. GMX ProMail - Platz 2 und Preis-Qualitätssieger!
3. Arcor - 4. web.de - 5. T-Online - 6. freenet.de - 7. daybyday - 8. e-Post




More information about the samba mailing list