Discussion Locked

Login Script Trouble

0 helpful
7 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

We are currently migrating our server from Netware to NT . We have a mix of NT 4.0 and Windows 2000 workstations. We need the login script to create three mappings(1-department Drive,2-application Drive,3-user folder). The login script is below. Theonly problem we have had is with the user directory mapping. The SUBST command mapping would not work on the 2000 machines, and the net use s: \\rockland_pdc\users\%username% only works on 2000 machines. Any Ideas? We tried using the IF %OS% command with no luck.
******************************************
@echo off
REM Drive Mappings*****
net use * /delete /y
echo Application mapping
NET USE M: \\Rockland_pdc\apps

echo Department mapping
NET USE G: \\Rockland_pdc\Department

if "%os%" == "windows_nt" goto nt4

echo Default User mapping WIN 2000*********
net use s: \\rockland_pdc\users\%username%

:nt4
echo Default User mapping Win NT***********
NET USE R: \\Rockland_pdc\USERS
SUBST U: R:\%username%
NET USE R: /DELETEEnd Script

7 replies

by erikdr

The 'problem' is known, but with all 32-bit Windows varieties we use the following solution:
define this directory as their homedirectory in User Manager (or in W2K in ADS) and in the same tool define the driveletter (R: in your case) for this dir.They'll be mapped to their own subfolder and never see the \USERS root.

Works like a charm here for over 3 years and >20,000 users.

At your service,

- The Netherlands

by syscokid

Yes, if you create a home directory in User Manager for Domains, you won't have to map it in a login script.

You may find, however, that you will have to create a share for each user in Server Manager. (End it with a $ to make it a hidden share). Then connect the drive letter to \\rockland_pdc\sharename$.

If you have a large number of users and want to automate the process of creating user shares, look at :

http://support.microsoft.com/support/kb/articles/Q168/9/18.ASP

(Sometimes when I copy and paste URL's it looks ok to me but once the answer is posted, an extraneous space will have crept in. Make sure you delete any extraneous spaces or the page won't load).

by vagab0nd

You can also use Kixtart scripts from NT Resource Kit. It work great on both NT and 2000 the same as 9x. There's also a great help in RK so you shouldn't have problems with it.

This discussion is closed to new replies.