search cancel

UIM - dirscan probe - Details how it works

book

Article ID: 130288

calendar_today

Updated On:

Products

DX Unified Infrastructure Management (Nimsoft / UIM)

Issue/Introduction

The dirscan probe monitors files in specific directories. Alarms can be sent on number of files, age of files, and space used by files. The probe is configured by defining one or more profiles. Each of these profiles can monitor a particular directory,

  • checking that the directory exists,
  • checking that particular files or file types are located in the directory, and
  • checking that the size and age of the files do not exceed expected values

The probe can also check if one or more specific files have changed. Alarm messages are generated when the files found are not as expected. (When conditions specified under dirscan Configuration are not met). Some search properties may also be transmitted as quality of service messages.

Environment

Any release

Resolution

The following diagram outlines the process to configure the dirscan probe to monitor a directory.
 

All probe-related software required as well as versions, e.g., PowerShell, .Net etc.


The dirscan probe requires the following software environment:

  • Nimsoft Monitor Server 5.1.1 or later
  • Nimsoft Robot 3.00 or later
  • Java Virtual Machine 1.6 or later (typically installed with NMS 5.0 or above)

Metric details




Monitor Name


Units


Description

QOS_DIR_AGE Seconds Age of oldest matching file
QOS_DIR_EXISTS Boolean Directory exists
QOS_DIR_NUMBER Files Number of matching files
QOS_DIR_RESPONSE_TIME Bytes per second File Response
QOS_DIR_SPACE Kilobytes Space used by matching files
QOS_FILE_INTEGRITY Boolean File Integrity Check



We use _stat/stat call to optain the necessary information like whether dir exist or not and if it exists what’s its age.



For getting list /finding a sub file we uses readdir And   _findfirst/ _findnext like calls on unix and windows like platforms.


For RESPONSE_TIME we use following calculations
 
Start time = current time (T1)
Read N bytes from file
End time = current time (T2)
RT = End time - Start time
 
QOS_DIR_RESPONSE_TIME = (RT)/1000               UNIT à sec
QOS_DIR_RESPONSE_TIME = (N*1000)/RT           UNIT à bytes per sec
 

Raw Configuration parameters and their descriptions (exposed as well as any hidden)


General Tab
 
The General tab allows you to modify the general probe parameters.
The fields in the window are explained as follows:
 

 
 
Check interval (seconds)
Indicates the time interval at which the defined directories are scanned. You can reduce this interval to generate alarms faster (as next interval takes lesser time) but it increases the system load. You can also increase this interval to reduce the system load but it generates alarms later (as next interval takes more time).
 
Default message level
Indicates the default message level for alarm messages. This value can be overridden in each alarm condition.
 
Log Level
Sets the level of details written to the log file. Log as little as possible during normal operation to minimize disk consumption, and increase the amount of detail when debugging.
 
Log Size
Sets the size of the probe’s log file to which probe-internal log messages are written. The default size is 100 KB. When this size is reached, the contents of the file are cleared.
 
Run as user
Specifies a valid user name and password to allow access to required files and directories. Note that the user name also must include the Windows domain name (<domain name>/<user name>).
 
 

 
 
Schedule Tab
 
The Schedules tab enables you to run the profile on specific date and time. Use this option, if you do NOT want to use the Check interval time (as specified in the Setup tab). For example, run the profile to monitor only on Wednesday mornings at 8:00 A.M.
 

 

 
New Schedule Window
The fields in the window are explained as follows:
 
Name
Specifies a name for the schedule.
 
Range
Specifies the time duration for which the alarms/QoS should be generated.
 
Pattern
Specifies the pattern in which the alarms/QoS are generated. Select a pattern (Secondly,
Minutely, Hourly, Daily…) and then specify the value at which the pattern is repeated.
 
Restrict To
Specifies whether to generate alarms or QoS only for a day or within a time frame on specific days.
 

User (level of access required for connection and data collection)



Probe utility commands and their descriptions


Gen_MD5
Generate MD5 signature
 
set_freq
sets the interval to provided value
 
get_platform_info
Gives value ‘1’ in case of windows os otherwise ‘0’ value is returned.
 
get_freq
Gives current probe interval value
 
list_directory
Provides comple list of files/dirs with details present in given directory path
 
list_drives
Gives list of drives present in system
 
list_match_files
Provides comple list of files with details present in given directory path having name , that matches with provided pattern.
 
list_profiles
Provides list of profiles with details
 
loglevel
Updates loglevel with the given value
 
test_start
Creates a quick profile with the entered details and returns a ‘ID’.’iD is later required in test_end to end the test profile.
 
test_end
End the test profile corrosponding  to the entered ‘ID’ and provides details . ‘ID’ is same as returned by test_start
 
test_scan
Provides quick statistics for the entered detais