How to monitor the size of files in Windows folder?

6,212

Solution 1

@JohnGardeniers is completely right in his comment, and though I don't have enough experience with Progress databases to help, in that regard, I've got a few things up my sleeve you could try.

Oh, and just FYI, your life will be much easier if you can replace/ignore/accidentally destroy your Windows 2000 servers, as a lot of products and solutions that work with Server 2008 and above simply will not work on Windows 2000. Having said that

  1. SNMP.

    • If you have a nice, powerful SNMP monitoring system (Nagios/SolarWinds/Open Manage/etc), you can use it to do this for you, complete with automatic email and/or SMS alerting.

  2. Buy a product to do so for you.

    • Technically, get the company to buy something for you, but you can pick up a lot of decent apps for this for under $100, so when my company's too cheap to do so, I'll often just buy one out of pocket and have a license for me, that I run off a PC or server at my home.

  3. Script something, like in this StackOverflow thread.

    • This might even work for both the Windows 2000 machines and the Server 2008 R2 machines, since it's a batch file/DOS script.

  4. Automate use of the reporting tools in the File Services Role to get regular reports and handle things manually.

    • Pretty sure this will only be an option on Server 2008 R2, but better than nothing.

Solution 2

Another way to look into this problem is, if you have windows 2008 then use power shell and call WMI with domain administrator permission and fetch the information you require and configure mail if size goes out of limit. You can also centrally manage the which servers to look into.

Use Task Schedule to set an interval for the script

Basic google search gave me following link. PowerShell WMI

Hope this will solve your issue.

Share:
6,212

Related videos on Youtube

Zlatko
Author by

Zlatko

Angular dev

Updated on September 18, 2022

Comments

  • Zlatko
    Zlatko almost 2 years

    What are some of good ways to automatically monitor the size of files in a directory and send warning email if they get close to a certain limit on a Windows server?

    I have a Progress DB installation to keep in check, and last week we hit some problems. Apparently, the size of extents has hit 2GB - and Progress won't work past that - we needed to open a new extent.

    I'm coming from a Linux environment, so I don't know what are the usual to monitor this in a Windows environment (or monitoring tools whatsoever).

    I prefer some generic solution, as I have a mixed environment (Windows 2000, Windows Server 2003, Windows Server 2008 R2).

    Thanks in advance for all usable alternative answers.

    • John Gardeniers
      John Gardeniers almost 12 years
      You're tackling this from the wrong angle. Progress should be configured to automatically create new extents when the file size reaches a preset limit. It's been too long since I've done it to remember how.
    • Zlatko
      Zlatko almost 12 years
      I might have to change the progresds devs too, they said there is no way to do it :-)
    • John Gardeniers
      John Gardeniers almost 12 years
      I don't remember the specifics but I do recall this was covered in a Progress course I took, probably about 12 years ago, and made sure it was properly implemented on the system under my care. If in doubt contact Progress themselves.
    • Admin
      Admin over 11 years
      @JohnGardeniers > Progress should be configured to automatically create new extents when the file size reaches a preset limit. It's been too long since I've done it to remember how. Could you please try to remember how is this done and share it with us because I work with Progress for years now and never heard of this feature. Monitoring extents is one thing and it's achiveable, but adding extents automatically.... Do you know how are extents added to Progress database? Are you sure you mean Progress, not Postgresql?
    • John Gardeniers
      John Gardeniers over 11 years
      @vjug, I learned to do it during a Progress course, so presumably you could learn it the same way. I haven't worked with Progress for a very long time and I make no attempt to remember little things like that which I'm extremely unlikely to ever need again. I don't like working with such primitive and troublesome systems and therefore will avoid doing so.
    • Admin
      Admin over 11 years
      @JohnGardeniers > I don't like working with such primitive and troublesome systems > and therefore will avoid doing so. It's your choice what do you use, but it's really not ok to make such comments about something you apparently know so little. > I learned to do it during a Progress course, so presumably you could > learn it the same way. I want to learn but I can't find anyone who claims there's such a thing except you. Can you point me to educators that propagate this? You are the only one who says it's possible (although without any arguments) so I hope you understand why I'd like to
    • Zlatko
      Zlatko over 11 years
      @JohnGardeniers how about to me? I'd like to get this set up.
    • John Gardeniers
      John Gardeniers over 11 years
      @zladuric, if I could remember how, or still had the book that described the procedure, I would have posted it as an answer at the start. All I can do now is to let you know that it can be done because I've done it myself.