Announcement

Collapse
No announcement yet.

Check Disk Space Script

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Check Disk Space Script

    We have just installed an enterprise wide scanning program, now we are in the process of management and planning for future growth. The files are stored on a Windows 2003 server.

    Is there any way to run a script that can report the free space and used space, then send an email to myself after the script has ran?

    If there is any programs that would do this would be sufficient as well.

    Any pointers on where to start would be great.

    Thanks in advance.
    MCITP:SA, MCSA 2003, MCP, CCNA, A+, Net+, Security+

  • #2
    Re: Check Disk Space Script

    Hi

    You could try http://www.microsoft.com/technet/scr....mspx?mfr=true .
    There is a great VBS script repository there. I had a quick look in there and there is no script at the moment that does what you are asking for but if you know anything about VBS scripting you could edit them to do what you want, otherwise if you ask them, they might come back with the code for you.

    Hope it helps
    Caesar's cipher - 3

    ZKHQ BRX HYHQWXDOOB GHFLSKHU WKLV BRX ZLOO UHDOLVH LW ZDV D ZDVWH RI WLPH!

    SFX JNRS FC U6 MNGR

    Comment


    • #3
      Re: Check Disk Space Script

      http://www.freesoft411.com/freeware/...e-monitor.html
      ________
      Free Themes
      Last edited by DYasny; 6th March 2011, 19:00.
      Real stupidity always beats Artificial Intelligence (c) Terry Pratchett

      BA (BM), RHCE, MCSE, DCSE, Linux+, Network+

      Comment


      • #4
        Re: Check Disk Space Script

        I'm also looking for something that does exactly this.

        i tried ManageEngine OpManager which seemed promising at first but I can't work out the disk management properly, can't seem to work out what disk it is monitoring as it just seems to show one... also the e-mails aren't coming through to me...

        Also tried an evaulation of MOM where I got some emails coming off to me but can't work out how to set it up so it monitors the disk space so if it gets low then it sends an email - really frustrating and i feel like i'm wasting so much time trying to configure this to do something that I thought was simple... Also surely I thought there would be an easier cheaper alternative just to monitor disk space on a few severs and email back if they get low...
        This is my signature.

        Comment


        • #5
          Re: Check Disk Space Script

          MS System Center Essentials seems to do well with this actually, I feel its got a bit of a nicer interface which makes it a bit easier to use... only problem now is that our servers aren't running SP1 which SCE doesn't seem to like... it'll only send out agents to W2k3SP1 or above, 2000 SP4+ or XP SP1+...
          This is my signature.

          Comment


          • #6
            Re: Check Disk Space Script

            Originally posted by boondock View Post
            We have just installed an enterprise wide scanning program, now we are in the process of management and planning for future growth. The files are stored on a Windows 2003 server.

            Is there any way to run a script that can report the free space and used space, then send an email to myself after the script has ran?

            If there is any programs that would do this would be sufficient as well.

            Any pointers on where to start would be great.

            Thanks in advance.

            Hello,

            I am backing up my servers data on windows xp computers and email to myself a complete report of the backup status.
            part of it is information about the free disk space.

            First, I am using a free Win32 command line SMTP mailer.
            Check: http://sourceforge.net/project/showf...group_id=81910

            You can run a simple batch file to output the information to a text file and then email it using Blat (free smtp mailer)

            Here is an exemple:
            DIR D:\ | FIND /I "BYTES FREE" >>c:\freespace.txt

            c:
            rem ************************************************** *****
            rem *the content of the file LOG files will be mailed here*
            rem ************************************************** *****
            blat c:\freespace.txt -subject "Disk space status" -to <your email address goes there>

            VBS is very powerful, but the old DOS still solves a lot of simple problems.

            Bert
            Last edited by bertv; 25th August 2008, 09:56.

            Comment


            • #7
              Re: Check Disk Space Script

              You could use something simliar to this...just set it up as a scheduled job on the server, and make sure you have IIS with SMTP installed:

              Code:
              Set getFSO = CreateObject("Scripting.FileSystemObject")
              getszDriveLetter = "C:"
              Set getDrive = getFSO.GetDrive(getszDriveLetter)
              getFreeSpace = getDrive.AvailableSpace/1000000
              Set objMessage = CreateObject("CDO.Message")
              i = 1
              
              If getFreeSpace < 2000 Then
              
              objMessage.Subject = "SAN IS BELOW 2 GIGS!!!"
              objMessage.From = "server.com"
              objMessage.To = "youremail.com"
              objMessage.TextBody = "SAN IS BELOW 2 GIGS!!!"
              objMessage.Send
              
              Else
              End If

              Comment

              Working...
              X