Monitoring and managing filesystems
The PATROL for Linux enables you to monitor all filesystems in a network. The NUK_FileSystem application monitors the filesystems mounted on a system for information such as
- Disk space
- Number of kilobytes available
- Number of kilobytes used
- Percentage of space used
- i-nodes
- Percentage of i-nodes used
- Number of i-nodes available
The application also lets you manage a monitored filesystem within BMC PATROL. Some of the tasks that you can perform are
- Synchronize information stored in the filesystem cache and disk
By default, the NUK_FileSystem application discovers and monitors all the disks mounted on the system. You can use menu commands to select which filesystems are monitored and which are not.
Monitoring filesystems
The NUK_FileSystem application class enables you to select which filesystems BMC PATROL monitors. With this feature, you can exclude monitoring test systems and other filesystems that are not vital to your company's day-to-day activities.
the action attempts to remove from /tmp files that are 30 days or older.
Automating filesystem cleanup
Before you begin
- You must be root to run this command.
- For a given NUK_FileSystem instance, the Capacity parameter must be active.
- This recovery action applies to all filesystem types except NFS, CD-ROM, and proc.
To set up automatic filesystem cleanup
- Access the Computer application menu.
- Select Configure Recovery Actions.
BMC PATROL displays the Register Recovery Actions dialog box, which lists all available recovery action. - Select the FilesystemCleanup recovery action and click Accept.
BMC PATROL displays the Recovery Actions Instance dialog box. This recovery action applies to all NUK_FileSystem instances. - Select the only item in the list and click Edit.
BMC PATROL displays the Edit Recovery Action dialog box.
Edit Recovery Action Dialog Box - Select the mode of the recovery action by clicking the corresponding radio button.
- Run Unattended—runs the recovery action automatically, without prompting you
- Run Attended—prompts you before running the recovery action, and does nothing if you do not respond within the user-defined time-out period
Do Not Execute—does not perform the recovery action; this mode is the default setting
- Click ACCEPT.
BMC PATROL closes the Edit Recovery Actions dialog box and displays the Recovery Action Instances dialog box. - Click Close.
BMC PATROL closes the Recovery Action Instances dialog box and displays the Registered Recovery Actions dialog box. - Click Close.
BMC PATROL closes the Registered Recovery Actions dialog box and enables the recovery action based on the options that you chose.
Managing filesystems using PATROL
The NUK_FileSystem application class enables you to manage filesystems from within BMC PATROL. With this feature, you can mount and unmount systems either automatically or manually. It also gives you the ability to synchronize filesystem tables and find and remove files.
Synchronizing the file system cache with disk
This task describes how to write the information stored in the file system memory buffer (cache) to the disk immediately rather than wait for the system to write it at a specified interval. This action synchronizes the information in the file system cache with the information stored on the disk.
To Write Information in the File System Memory to Disk
On the file system for which you want to search for files, perform the following steps.
- Access the NUK_FileSystem application menu.
- Select Maintenance > Sync. PATROL writes the memory buffer to disk.
Selecting filesystems to monitor
By default, BMC PATROL monitors all filesystems. This task describes how to determine which filesystems BMC PATROL excludes from monitoring and how to resume monitoring filesystems that have been excluded. It also describes how to deny a filesystem from persistent monitoring.
Before you begin
- The exclusion list feature supports regular expressions. To stop monitoring large numbers of filesystems that have uniform names, use regular expressions.
- The exclusion list feature excludes filesystems by type. You can stop monitoring all NFS systems, CD-ROM systems, process control (proc) subsystems, and any other custom system.
- The persistent monitoring denial feature denies filesystems by category. You can deny persistent monitoring of all NFS systems, CD-ROM systems, process control (proc) subsystems, and any other custom system.
- You can monitor a filesystem that has a dash in its name.
- To perform this task, you must be in developer mode. If you attempt to stop monitoring a filesystem when in operator mode, PATROL displays the following error message in the system output window.
To stop monitoring filesystems
On any filesystem, perform the following steps.
- Access the NUK_FileSystem application menu.
- Select Edit FILESYSTEM Exclusion List.
BMC PATROL opens the FILESYSTEM Exclusion List dialog box, which contains two list boxes: Monitored Filesystems and Excluded Filesystems.
FILESYSTEM Exclusion List Dialog Box - Either i n the Excluded Filesystems list box, select the filesystem that you want to monitor or in the Monitored Filesystems list box, select the filesystem that you want to exclude from monitoring.
If you want to stop monitoring one of the following filesystem types, select the corresponding check box.
If you want to deny persistence monitoring of a filesystem types, select the corresponding check box.
- Click Apply.
Based on your selections in step 3 and step 4, BMC PATROL adds the filesystems to the respective list box and then either removes or inserts the filesystem icons from the BMC PATROL Object Hierarchy. - Repeat step 3 through step 6 for each filesystem that you want to exclude. Then click Done.
To use regular expression to stop filesystem monitoring
On any filesystem, perform the following steps.
- Access the NUK_FileSystem application menu.
- Select Edit FILESYSTEM Exclusion List.
- On the FILESYSTEM Exclusion List dialog box (the following figure), in the Regular Expression to Exclude Filesystems text box, enter a regular expression that contains the filesystem name you want to exclude.
- Click Apply.
Based on the regular expression used, BMC PATROL adds the filesystems to list of Excluded Filesystems and removes the filesystem instances from the BMC PATROL Object Hierarchy. - Click Done.
Stopping persistent monitoring of deleted or unmounted file systems
PATROL enables you to stop persistent monitoring of deleted or unmounted file systems including all NFS systems, CD-ROM systems, process control (proc) subsystems, and custom file systems.
It automatically discovers the presence of mounted file systems and also issues an alert on the FileSystem Mount Status (MountStatus) if a discovered file system is later unmounted. This feature is not optional and cannot be turned off.
In some situations, however, you may want to unmount a discovered file system and cancel any alerts that the PATROL would subsequently issue, or you may want to exclude a file system from being monitored in the first place. In such cases, you can use one of the following options to prevent a file system from being monitored.
To stop persistent monitoring by using the application menu
- Access the NUK_FileSystem application menu.
- Select Stop Monitoring.
PATROL enables you to include the name of the file system to the FILESYSTEM exclusion list. This command prevents the file system from being monitored regardless of the file system is mounted.
To stop persistent monitoring by using the pconfig variable
Edit the /NUK/NUK_FileSystem_Container/moniList variable to remove the file system name from the variable. This option only applies to previously discovered file systems that are no longer available. The moniList variable maintains a list of persistently monitored instances based on the file system category and the custom file system tokens. The variable fsCategory provides the category of the file system instance and the variable /NUK/NUK_FileSystem_Container/nonPersistCUSTTokens provides the custom file system tokens for which persistent monitoring should be denied.
Stopping the monitoring of a file system
This task describes how to stop monitoring a single file system.
Before You Begin
To perform this task, you must be in developer mode. If you attempt to stop monitoring a file system when in operator mode, PATROL displays the following error message in the system output window.
FILESYSTEM: Only Development Console can filter an instance
To Stop Monitoring a Single File System
On the file system that you do not want to monitor, perform the following steps.
- Access the NUK_FileSystem application menu.
- Select Stop Monitoring.
PATROL removes the icon for the file system from the PATROL Object Hierarchy and stops monitoring the selected system. To resume monitoring of the file system, see Selecting filesystems to monitor.