Link to home
Start Free TrialLog in
Avatar of g000se
g000seFlag for United States of America

asked on

Gather disk space and other info from Windows 2000 servers

Is there a program available that is free that I can use to gather disk space and other info from mulitiple Windows 2000 servers?  Or is there a command that I can run as a batch file?  Please help.  Thanks.
Avatar of g000se
g000se
Flag of United States of America image

ASKER

Append:  I want to run the program or command without having to log on to each server console to pull the information.
Avatar of Lee W, MVP
WINMSD

And you can script a tremendous amount with batch files.
Avatar of g000se

ASKER

what is winmsd?
Windows Microsoft Diagnostics

Run WINMSD in a command prompt.  For switch info, winmsd /?

You can script it to report to a text file for every system.
SOLUTION
Avatar of kfullarton
kfullarton

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Check this out.
http://sydi.sourceforge.net/

You need to make sure that WMI is on the servers, but after that it makes it a breeze.

Simon.
Avatar of g000se

ASKER

Thanks for the links.  There is lots of info.  What should I keep in mind when scripting?  What is the purpose of scripting, is it like automating things or pulling information???  Would scripting benefit me in the long run as a Network Admin.?  Sorry for the bizillion questions.  
What's the point of scripting?  Scripting automates things that otherwise would be tedious and repeatitive.  For example, I once had to WEEKLY recreate a directory structure, modify the folder permissions so only very specific people could access each folder (each folder different from the next) and backup the previous week's data.  For 100+ folders.  This would be a HUGE pain to have to do manually AND would you really want to go to work each Saturday night at midnight to do it?  I was able to script this procedure to work off a delimited text file that someone exported from excel, then scheduled a task to run every saturday at midnight.  Never had to touch it again.

Scripting if GREAT.  Any time you think you might need to do something repeatitive to one machine - or a lot of machines, it's DEFINITELY worth knowing!
Avatar of g000se

ASKER

Thanks leew. May I see a sample script you created.
Avatar of g000se

ASKER

I was viewing some sample scripts on http://www.microsoft.com/technet/scriptcenter/scripts/os/monitor/osmovb03.mspx
and I noticed that most of the sample scripts dont' support the windows 2000 environment.  Can I still tweak the script to run on the Windows 2000 environment?  I guess if there is a will there is a way to accomplish it.  I am also going to purchase the "Microsoft® Windows® Scripting Self-Paced Learning Guide".  New skills will be aquired after I am done with this stuff.
That particular script was for a job I no longer work at.  But if you review my question history, mostly in the DOS section of this site, I have helped many people with scripts.  Even asked a question myself on a script that's fairly long.

The link you inquire about is a vbscript - nothing wrong with VB scripts, but my expertise is in batch scripting.  And MOST of the time, using various tools and utilities, you can do the same thing in a batch script you can in a vbscript using less code.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of g000se

ASKER

My head is spinning from the different types of scripting.  So scripting is initiated through a batch file, is there any other means?
There is batch scripting, which is available to ALL Windows Operating Systems AND DOS (though commands and compatibilities may vary).

There is KixStart Scripting (not used much anymore from what I've seen), VbScripting, and there can be other types of scripting.  It doesn't have to start in a batch file.  

Just like there are different programming languages, there are different scripting languages/methods.
Avatar of g000se

ASKER

Thanks for all your help!
Avatar of g000se

ASKER

How would one start a VbScript?
Use vbscripting language in a text file.  Then name the file something.VBS - the VBS should tell Windows it's a vbscript file and execute it as such.
And you can combine things too.   You can create a batch script that uses one or more vbscripts, calling them as any other program.

And just to be clear, batch programming is using a few basic features of a command prompt (detecting errors and such) and executing commands in sequence.  These commands could be anything.  A windows program, a command line utility, another script, anything that can otherwise run on a PC.
Avatar of g000se

ASKER

It's starting to make sense now after reviewing the info listed here and online.  I created this to monitor print job status.  Here is the sample text:  
--------------
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
 & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set Admin = objWMIService.ExecQuery _
 ("SELECT * FROM Win32_PrintJob")
Wscript.Echo "Print Queue, Job ID, Owner, Total Pages"
For Each objPrintJob in Admin
 strPrinter = Split(objPrintJob.Name,",",-1,1)
 Wscript.Echo strPrinter(0) & ", " & _
 objPrintJob.JobID & ", " & objPrintJob.Owner & ", " _
 & objPrintJob.TotalPages
Next

------------------

I will then add the extension .vbs to execute the script.  Can you verify this script listed above, all I did was change the name of the printer to match one on the network?   Admin is the name of the printer.  I have created batch files in the pass to assign users rights to folders on the network using xcacls.  The learning curve is getting better.
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of g000se

ASKER

This helps.  Thanks for the clarificatioin.
Avatar of g000se

ASKER

here is my batch file I have created and it works:

REM srvinfo- Resource kit
REM srvinfo \\%1 | find "$"

REM the output from this line will be something like

REM C$      NTFS        4095       451      3644
REM D$      NTFS        7413      5411      2002

REM drive  filesys     totsize    free      used

srvinfo \\server1 | find "$"
srvinfo \\server2 | find "$"
srvinfo \\server3 | find "$"
srvinfo \\server4 | find "$"
srvinfo \\server5 | find "$"
srvinfo \\server6 | find "$"
srvinfo \\server7 | find "$"
srvinfo \\server8 | find "$"

Pause