1. You are viewing our forum as a guest. For full access please Register. WindowsBBS.com is completely free, paid for by advertisers and donations.

script to log disk capacity information

Discussion in 'Windows Server System' started by Ludwig, 2006/07/15.

  1. 2006/07/15
    Ludwig

    Ludwig Well-Known Member Thread Starter

    Joined:
    2002/01/07
    Messages:
    146
    Likes Received:
    0
    For many many years my good ol' batch file has worked - since '97 in fact. It "NET USE "-ed to each server's disk and logged used (DIRUSE cmd ex NT Resource kit) and free (DOS cmd 'dir'). The sum was a good approximation to "volume size" ie capacity.

    Now most of our systems have mounted drives, so these don't work for me. Manually connecting to each server (80+) using Computer Management from our Windows Terminal Services server and writing down CAPACITY & FREE figures is just not practical.

    I experimented with MSINFO32, but that only reports on volumes with drive letters assigned. Most of our key volumes are in one of our Storage Area Networks and are only mounted into an existing drive & thus have no drive letter assigned (as not needed), so that won't help now either.

    I haven't yet got into scripting, and a product like MOM would require some time to implement. Would anyone know where I could get a starter script I could use that I set up to race around our system and log current capacity info (vol size, free or used, or all 3). I can quickly & easily code up a list of servers, and if necessary drive letters / mount point names, to pass to a "DO FOREVER UNTIL <none left>" loop run in a scheduled task.

    Any & all help appreciated.
     
    Last edited: 2006/07/15
  2. 2006/07/15
    sorinso

    sorinso Inactive

    Joined:
    2003/10/27
    Messages:
    65
    Likes Received:
    0
    Microsoft's Technet is the answer...

    Hi, Ludwig.
    I suggest you start a search in Microsoft's Technet site, in the Script Repository. It has a lot of scripts ready to use. Of course, there are a lot of other resources on the Web, but I always check the Technet first.
    For instance, here is a script that returns the free space on every disk in the server. You will need to customize it for your purposes, but it is a good start.

    Good luck,

    Sorin.
     

  3. to hide this advert.

  4. 2006/07/18
    Ludwig

    Ludwig Well-Known Member Thread Starter

    Joined:
    2002/01/07
    Messages:
    146
    Likes Received:
    0
    Scripts on MS site

    Thanks for the links. I'll have a look thru where you suggest to see if the ones listed under mount points will do what I'd like (e.g. list them; then recursively extract the info for each).
     
  5. 2006/07/18
    sorinso

    sorinso Inactive

    Joined:
    2003/10/27
    Messages:
    65
    Likes Received:
    0
    Good luck

    I hope the stuff there will help.
    And it will be nice if you'll let us know the results.
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.