Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

NT4 Server Manager list into text file.

Posted on 2004-05-02
5
Medium Priority
?
2,057 Views
Last Modified: 2013-12-19
how can i export the list of my nt4 PDC server manager into a text file or a CSV file? please it's very important and urgent to me.

Daniel.
0
Comment
Question by:tomerlei
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 85

Expert Comment

by:oBdA
ID: 10972507
Use this script to obtain a list of your domain machines, and add ">Machine.txt" at the end of the command; if necessary, adjust the settings at the beginning to your localized version of NT:

====8<----[ListMachines.cmd]----
@echo off
setlocal
:: *** The name of your domain user group:
set DomainUsers=Domain Users
:: *** The number of the first useless lines of the 'net group "domain users" /domain' command output:
set NetFirst=4
:: *** The last line of the 'net group "domain users" /domain' command output:
set NetLast=The command completed successfully

echo Computeraccounts in %Userdomain%:
for /f "skip=%NetFirst% delims=" %%a in ('net group "%DomainUsers%" /domain') do (
 set Line=%%a
 call :process
)
goto leave

:process
:: *** Get the account names, configured in three columns:
set Account1=%Line:~0,25%
set Account2=%Line:~25,25%
set Account3=%Line:~50,25%
:: *** Avoid processing the "The command completed successfully" line
if /i "%Account1%"=="%NetLast:~0,25%" goto :eof
:: *** Remove spaces
if not "%Account1%"=="" set Account1=%Account1: =%
if not "%Account2%"=="" set Account2=%Account2: =%
if not "%Account3%"=="" set Account3=%Account3: =%
:: *** Write all accounts containing a "$":
if "%Account1%"=="" goto :eof
if not "%Account1%"=="%Account1:$=%" echo %Account1%
if "%Account2%"=="" goto :eof
if not "%Account2%"=="%Account2:$=%" echo %Account2%
if "%Account3%"=="" goto :eof
if not "%Account3%"=="%Account3:$=%" echo %Account3%
goto :eof

:leave
====8<----[ListMachines.cmd]----
0
 
LVL 4

Author Comment

by:tomerlei
ID: 10974886
the script you gave me didn't really work, and from what i got
the command "net group" gives you the status of group in the domain, not the computer accounts, i need the list of the computer accounts that you see on the server manager, not in the user manager.

Thanks in advance,
Daniel Leicht.
0
 
LVL 85

Expert Comment

by:oBdA
ID: 10975390
The command
net group "domain users" /domain
will give you a list of all your domain accounts (assuming that your domain users groups is called "Domain Users"). That includes the computer accounts, which have a "$" at the end of the name. What happens if you enter this in a command window?
0
 
LVL 4

Author Comment

by:tomerlei
ID: 10975878
oh, you were right i accidently thought you ment for the domain name to be there, but still it doesn't give me the computer type (OS) which the server manager gives me.
can you help me with that?
thanks in advance,
Daniel Leicht.
0
 
LVL 85

Accepted Solution

by:
oBdA earned 200 total points
ID: 10977840
For remote checking of the OS version, you can use PsInfo from Sysinternals (http://www.sysinternals.com/ntw2k/freeware/psinfo.shtml).
You can first export the machine list to a text file, then use
for /f %%a in ('type "YourMachines.txt"') do @psinfo.exe \\%a
to get a complete list of machine configurations.
0

Featured Post

New benefit for Premium Members - Upgrade now!

Ready to get started with anonymous questions today? It's easy! Learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A brief overview to explain gateways, default gateways and static routes OR NO - you CANNOT have two default gateways on the same server, PC or other Windows-based network device. In simple terms a gateway is formed when a computer such as a serv…
Ever visit a website where you spotted a really cool looking Font, yet couldn't figure out which font family it belonged to, or how to get a copy of it for your own use? This article explains the process of doing exactly that, as well as showing how…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question