Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

User List

Status
Not open for further replies.

deej

Vendor
Dec 9, 1999
10
EU
We currently have a domain with approx 2000 users who reside at different sites. The only way to distinguish where they are located is by prefixing the description with a 3 character reference ie SAM..Samlesbury.<br>We would like to list/print the users in User Mgr for the relevant sites....Please help!!!!<br>We have looked thru the resource kit but to no avail.
 
You can build a script to process the output of the &quot;net user&quot; command to dump a list of users into a text file but that doesn't give descriptions.&nbsp;&nbsp;WE build location and dept into the username itself so they naturally group together when you do a list.&nbsp;&nbsp;Unfortunately your users are already set up.&nbsp;&nbsp;There is a lot of information available on stuff like this at <A HREF=" TARGET="_new"> may have a freeware tool for dumping name and description that you could process the output of.<br><br>To maybe be of some use or get you started here's a userlist tool I developed simply using the Windows Batch language:<br><FONT FACE=monospace><br>@echo off<br>rem -----------------------------------------------------------------------------------<br>rem UserList.BAT - Generate a list of all user IDs for a domain.<br>rem <br>rem&nbsp;&nbsp;&nbsp;This file parses the output of the &quot;net user&quot; command into a single column list<br>rem&nbsp;&nbsp;&nbsp;of all users for a domain, discarding the header and trailers.<br>rem -----------------------------------------------------------------------------------<br>echo Processing user list, Please wait....<br><br>set LISTFILE=UserList.txt<br><br>if exist %LISTFILE% del %LISTFILE%<br>goto PROCESS<br><br>:FINISH<br>echo Processing Complete.&nbsp;&nbsp;Output is in the file [%LISTFILE%]<br>goto :EOF<br><br>:pROCESS<br>for /f &quot;Skip=6 Tokens=1,2,3&quot; %%i in ('net user /domain') do call :CHECKEND %%i %%j %%k<br>goto :EOF<br><br>:CHECKEND<br>if &quot;%1&quot;==&quot;The&quot; goto :FINISH<br><br>echo %1 &gt;&gt; %LISTFILE%<br>if &quot;%2&quot; NEQ &quot;&quot; echo %2 &gt;&gt; %LISTFILE%<br>if &quot;%3&quot; NEQ &quot;&quot; echo %3 &gt;&gt; %LISTFILE%<br>rem -----------------------------------------------------------------------------------<br></font><br><br> <p> Jeff<br><a href=mailto: masterracker@hotmail.com> masterracker@hotmail.com</a><br><a href= > </a><br> Of all the things I've lost in life, I miss my mind the most ...
 
More info:<br><br>There is a public domain program called SHOWMBRS that can display ID and description.<br><br>Check out <A HREF=" TARGET="_new"> Tip #754 where you can donload the utility and a batch file that uses it to generate a report. <p> Jeff<br><a href=mailto: masterracker@hotmail.com> masterracker@hotmail.com</a><br><a href= > </a><br> Of all the things I've lost in life, I miss my mind the most ...
 
I found that DUMPSEC application is good.
You can dump from any specified machine, whether it be server or not. You can dump users, groups, shares and a variety of other things.
reports saveable in CSV format for formatting in Excel.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top