4.15 FolderSize

Use this Knowledge Script to monitor the size of folders containing files that match a set of criteria. For example, you can monitor for folders over 100 MB that contain MPG or JPG files, and you can further refine your criteria to only include MPG or JPG files over a particular size. This script raises an event if the size of any folder exceeds the threshold you specify.

4.15.1 Resource Object

Misc Device folder

4.15.2 Default Schedule

The default schedule for this script is Every 24 hours.

4.15.3 Setting Parameter Values

Set the following parameters as needed:

Description

How to Set It

Event Notification

Raise event if threshold is exceeded?

Select Yes to raise an event if the size of a folder containing files matching your criteria exceeds the threshold you specify. The default is Yes.

Severity - Exceeded threshold

Set the event severity level, from 1 to 40, to indicate the importance of an event in which the folder size exceeds the threshold. The default is 11 (yellow event indicator).

Raise event if a folder cannot be accessed?

Select Yes to raise an event if the folder you specify in the Root folder to begin the search parameter does not exist or cannot be accessed because the account under which the NetIQ Client Resource Monitor service (NetIQmc) is running does not have permission to open the folder.

The default is unselected.

Severity - Folder not accessible

Set the event severity level, from 1 to 40, to indicate the importance of an event in which the specified folder does not exist or cannot be accessed. The default is 25 (blue event indicator).

Severity - Job failure

Set the event severity level, from 1 to 40, to indicate the importance of an event in which the FolderSize job fails. The default is 5 (red event indicator).

Data Collection

Collect folder count data?

Select Yes to collect data for charts and reports. If enabled, data collection returns the number of folders whose file size exceeds the threshold. The default is unselected.

Monitoring

Logical drive letter(s) to search

Type a comma-separated list, with no spaces, of the letters representing the logical drives you want to search. For example: C,D.

Root folder to begin the search

Type the path to the folder on each drive in which you want to begin searching. For example, enter Documents and Settings\Administrator\My Documents to begin searching in the My Documents folder.

The default is users.

File name(s), can use * and ? wildcards

Type the filenames to search for. Use the * wildcard to represent any number of characters; use the ? wildcard to represent any single character. The default is *.* (all files).

You can enter only one filename here, but with the use of wildcards, you can search for multiple files.

Search subfolders?

Select Yes to search any subfolders of the root folder in which your search begins. The default is Yes.

Folder size threshold

Specify the number of units that define the folder size. The type of units is set in the Folder size scale parameter. The default is 10.

Folder size scale

Specify the type of unit that defines the folder size (for example, kilobytes). The default is megabytes.

Folder size operator

Specify the operator that defines the folder size (for example, less than 10 megabytes). The default is greater than.

File Filters

File Attributes Filter

File attribute operator

Select the operator (AND or OR) to apply to the criteria in the File Attributes Filter parameters. For example, instruct the script to search for files that have the Archive attribute AND the Hidden attribute. The default is OR.

Archive attribute

Select Yes to search for files that have the Archive attribute. The default is unselected.

Hidden attribute

Select Yes to search for files that have the Hidden attribute. The default is unselected.

Read-only attribute

Select Yes to search for files that have the Read-only attribute. The default is unselected.

System attribute

Select Yes to search for files that have the System attribute. The default is unselected.

Date Modified Filter

Apply date modified filter?

Select Yes to apply a search filter that considers the date on which a file was modified. The default is unselected.

Select time range

Click Browse [...] to set a specific or sliding date/time range for the date on which files were modified. The default is a sliding range of 1 Day with the End now option selected.

A specific date/time range defines a specific start and end date and time, for example:

1/1/2004 12:00 AM to 1/31/2004 11:59 PM.

A sliding date/time range defines a time range relative to the start time of the Knowledge Script job. For example, a sliding date/time range of 1 Day extends from 12:00 AM of the previous day to 11:59 PM of the previous day (the entire 24-hour period of the day prior to the day the script runs).

The End now option for the sliding date/time range extends the time range up to the start time of the Knowledge Script job. For example, if the job runs at 3:00 PM with a sliding range of 1 Day, then the time range covered is 12:00 AM of the previous day to 3:00 PM of the current day.

File Size Filter

Apply file size filter?

Select Yes to apply a search filter that considers the size of a file. The default is unselected.

File size

Specify the number of units that define the file size. The type of units are set in the File size scale parameter. The default is 5.

File size scale

Specify the type of unit that defines the file size (for example, kilobytes). The default is megabytes.

File size operator

Specify the operator that defines the file size (for example, less than 5 megabytes). The default is greater than.