logon script

John Malmberg wb8tyw at qsl.net
Tue Feb 19 05:06:21 GMT 2002


"Tom Bradley-Watson" <tom#mediatel.com.au> wrote:
> 
> This seems quite simple but I just can't seem to get it working.
> 
> In my global config I am using the following logon script which is working
> fine.
> 
> Logon Script = Logon.bat
> 
> I then created a logon scripts for each group stored in directories named
> after each department group in the netlogon share.
> 
> Logon script = %G\Logon.bat
> 
> For some reason this does not work...
> Can anyone help, I am out of ideas but I bet it's really simple..
> 
> Cheers Tom

I never tested logon scripts, so I do not know how well they would work.

What I would check for is any messages in the smbd.log file, possibly 
increasing the error level.

I am not directly familiar what %G translates to in macro expansion 
either.  May be the log will tell.

According to some of the discussions on the UNIX Samba groups, not all 
macro expansions are available at all times.  This is because the 
context needed for the expansion may not yet be known by the smbd program.

The other thing that I notice is that in the first case you are not 
specifying a complete path name, so SAMBA must be filling in the rest 
from somewhere.  When you add the %G to that, it may change the way the 
filename is put together.  The UNIX to VMS translation routines may not 
be getting it right.

What version of Samba and what version of OpenVMS are you running?

Can you try a test version of logon.bat that logs the value of P1?, then 
you can try:

Logon Script = Logon.bat "%G"

This should at least tell you if %G is being translated properly.

There are some security concerns about using logon scripts, so make sure 
that they are properly protected and tested.

-John
wb8tyw at qsl.network
Personal Opinion Only





More information about the samba-vms mailing list