[Samba] Logon Script

Paul Soulek soulek at frontiernet.net
Fri Aug 23 13:47:01 GMT 2002

I volunteer at a school, where we recently installed Linux on a server,
and we run SAMBA. I have a logon script, that makes use of the "net use"
command in Windows to map the network drives when a user logs on.

Here is what it looks like (from memory, I'm not at school now)

net use h: \\SERVERNAME\**USERNAME**
net use s: \\SERVERNAME\dropbox
net use r: \\SERVERNAME\public_folder

I can get the last two commands to work, but how can I get Windows to
give me the username as a variable? I tried %U (which is the Linux
variable), but what would I insert? Each user has their own home share
that I want to map. Thank you!

Paul in Minnesota

More information about the samba mailing list