[windows2000] Re: delete multiple profiles

  • From: "Robert K Coffman Jr - Info From Data Corporation" <bcoffman@xxxxxxxxxxxxxxxx>
  • To: <windows2000@xxxxxxxxxxxxx>
  • Date: Thu, 12 May 2005 09:03:16 -0400

I use the following on NT 4 TSE.  I don't know about using with W2k, XP or
2003 - I think you need something beyond this.  At the very least you would
need to fix the path to the profiles, but I think there are registry
implications on those OSs that NT4 didn't have.  The rename part of this
script verifies the profile is not in use, so it doesn't try to delete it.
Parameters are servername and profilename.  I call this from another script
that passes the server/profile names.  How you populate that is a different
animal.  My solution is an ugly script that uses exporter and Access to
build a script with all domain userids.
 
echo off
echo %1
if not exist \\%1\c$\wtsrv\profiles\%2 goto done
if not exist \\%1\c$\wtsrv\profiles\z1clnpro.zyx goto noprob
rmdir \\%1\c$\wtsrv\profiles\z1clnpro.zyx /S /Q
:noprob
rename \\%1\c$\wtsrv\profiles\%2 z1clnpro.zyx
if exist \\%1\c$\wtsrv\profiles\%2 goto done
rmdir \\%1\c$\wtsrv\profiles\z1clnpro.zyx /S /Q
:done
 
 
 

-----Original Message-----
From: windows2000-bounce@xxxxxxxxxxxxx
[mailto:windows2000-bounce@xxxxxxxxxxxxx] On Behalf Of Herchenbach, Jim
Sent: Thursday, May 12, 2005 8:41 AM
To: windows2000@xxxxxxxxxxxxx
Subject: [windows2000] delete multiple profiles


I help out at our local school and every year we go through and delete all
the profiles off each networked machine one at a time.  Can this be
automated or can multiple profiles be deleted all at once?  batch file or
command line?  Windows 2000 and Xp pro machines on windows 2000 server
network.
 
JIM HERCHENBACH
RVW Inc.
 
 


Other related posts: