Page 1 of 1 1
Topic Options
#56273 - 2001-06-04 11:17 PM User Account Updates
TexasBrownsFan Offline
Fresh Scripter

Registered: 2001-02-07
Posts: 36
Loc: Fort Worth , TX, USA
We need to add a new drive to our server because it does not have any space left on it. We have also decided to move all Users Drives to this new Drive. Currently all user Shares are setup as standard shares. We have decided the best thing to do is when we move these drives is to create hidden shares. I have written the scripts to create the new folders copy all data remove the old shares and create the new ones.


My question is, does anyone know of away to update the User Account information to point to the new Hidden Share?

Thanks

Top
#56274 - 2001-06-06 12:56 AM Re: User Account Updates
Anonymous
Unregistered


You can use ADDUSERS.EXE in the ResKit Sup. 4.
Top
#56275 - 2001-06-05 04:25 PM Re: User Account Updates
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
sfg
_________________________
!

download KiXnet

Top
#56276 - 2001-06-05 04:31 PM Re: User Account Updates
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
You should use logonscript for mapping the users homdrive (in kix32 use x: "\\srvr\users_homedrive$") so you don't have to care about where the users profile points...
I've used it on some 3000 users allready and allmost everyones profile points to the default z:
small peace of script that checks what server the drive is on and all your servers can share user homedrives.
and with that you can change the location on the fly by just moving the folder and share...
easiest way!
I quess I don't have to say that I'm kix-fanatic and I really don't like the addusers app...

------------------
Lonkero

The weardest there is!

_________________________
!

download KiXnet

Top
#56277 - 2001-06-05 04:44 PM Re: User Account Updates
TexasBrownsFan Offline
Fresh Scripter

Registered: 2001-02-07
Posts: 36
Loc: Fort Worth , TX, USA
We do use the logon script to map drives, put in the profiles section in user manager, there is a home directory option, that is what we need to update.

I checked the addusers.exe command, and it appears that you can only add new users with this, what i am looking to do is update existing users. Anyone have any thoughs

[This message has been edited by bsockel (edited 05 June 2001).]

Top
#56278 - 2001-06-06 02:16 PM Re: User Account Updates
Anonymous
Unregistered


Hello !

May be the "net user /[option]" :

net user username /homedir athname


take a look to this :
http://support.microsoft.com/support/kb/articles/Q251/3/94.ASP

PhilV

Top
#56279 - 2001-06-06 05:35 PM Re: User Account Updates
Jack Lothian Offline
MM club member
*****

Registered: 1999-10-22
Posts: 1169
Loc: Ottawa,Ontario, Canada
Phil's suggestion might be what you need. Look up the NET command in this file:

C:\WINNT\system32\ntcmds.hlp


I did this once & I found it to be a pain. (Maybe there isan easy way I didn't think of.) Some suggestions that you probably already know. To handle batch control of ownership you will need to use xcacls from the NT4 Res Kit and to handle batch assigning of shares you will need rmtshare from the same Res Kit. You will probably need Showmbs from the same Res Kit to generate your list of users for the batch files. Watch out how you copy the shares too. The so-called shares created by the user manager are pseudo-shares not true shares. Access is controlled through ownership and not through share permissions. Some copying strategies will not work because administrators do not have ownership access. Taking ownership will lock the users out of their directories. You might use use Scopy from the resource kit but that might generate copies you can not touch without fixing ownership with xcacls.

Here is a portion of a sample batch file we use to create users. It creates the individual hidden shares as well. You could modify it to use the FOR command to loop through user lists generated by showmbs. Just take the parts you want.

@echo off
REM command file to create user accounts
REM needs NT Server 4.0 Resource Kit
REM parameters Userid, password, full name, user directory, group, server, comment
NET USER %1 %2 /add
NET USER %1 /scriptpath:LOGON.BAT /passwordchg:no /passwordreq:yes
NET USER %1 /times:M-F,7AM-7PM
NET USER %1 /fullname:%3 /comment:%7
NET GROUP %5 %1 /ADD
MD %4\%1
XCACLS.EXE %4\%1 /t /c /g administrator:fo;fo webmaster:f;f %1:f;f /y
NET USER %1 /homedir:%4\%1
RMTSHARE \\%6\%1$=%4\%1 /grant %1:f users:1 /remark:%3
RMTSHARE \\%6\%1$ /grant administrators:f
RMTSHARE \\%6\%1$ /grant %1:f

I think there is a simpler way of just moving the shares. Just copy them with Scopy from the resource kit and then go into the server registry and do a change all on share info. Then run NET USER for all user ID to update the user directory. Of course, they will still be pseudo-shares not real shares.

_________________________
Jack

Top
#56280 - 2001-06-08 03:58 AM Re: User Account Updates
dbortunk Offline
Fresh Scripter

Registered: 2001-05-18
Posts: 36
Loc: USA
buy a product like dameware www.dameware.com. Will save you a lot of time
Top
#56281 - 2001-06-20 08:54 PM Re: User Account Updates
rick_coughlin Offline
Fresh Scripter

Registered: 2000-11-15
Posts: 7
Loc: Gaithersburg, MD, USA
The Home Directory field in the user manager just sets an evironment variable if you are using the Local Path option. I'm guessing that is what you have selected since you said you are mapping the drive via your script.

code:

IF %OS% = "Windows_NT"
SET "HOMEDRIVE=H:"
ENDIF

This will reset that variable. Now, you can go back and at your leisure either change it in the User Manager or just remove it.

Rick

Top
Page 1 of 1 1


Moderator:  Glenn Barnas, NTDOC, Arend_, Jochen, Radimus, Allen, ShaneEP, Ruud van Velsen, Mart 
Hop to:
Shout Box

Who's Online
1 registered (Allen) and 1198 anonymous users online.
Newest Members
M_Moore, BeeEm, min_seow, Audio, Hoschi
17883 Registered Users

Generated in 0.059 seconds in which 0.027 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org