Reference Manual
Release Notes
PDF
Top

OS_Mon
Reference Manual
Version 2.2.5

Expand All
Contract All

Table of Contents

- os_mon (App)
- cpu_sup
  - Top of manual page
  - nprocs/0
  - avg1/0
  - avg5/0
  - avg15/0
  - util/0
  - util/1
- disksup
  - Top of manual page
  - get_disk_data/0
  - get_check_interval/0
  - set_check_interval/1
  - get_almost_full_threshold/0
  - set_almost_full_threshold/1
- memsup
  - Top of manual page
  - get_memory_data/0
  - get_system_memory_data/0
  - get_os_wordsize/0
  - get_check_interval/0
  - set_check_interval/1
  - get_procmem_high_watermark/0
  - set_procmem_high_watermark/1
  - get_sysmem_high_watermark/0
  - set_sysmem_high_watermark/1
  - get_helper_timeout/0
  - set_helper_timeout/1
- os_mon_mib
  - Top of manual page
  - load/1
  - unload/1
- os_sup
  - Top of manual page
  - enable/0
  - enable/2
  - disable/0
  - disable/2
- nteventlog
  - Top of manual page
  - start/2
  - start_link/2
  - stop/0

# os_mon

### APPLICATION

os_mon

### APPLICATION SUMMARY

OS Monitoring Application

### DESCRIPTION

The operating system monitor, OS_Mon, provides the following services:

- cpu_sup CPU load and utilization supervision (Unix)
- disksup Disk supervision(Unix, Windows)
- memsup Memory supervision (Unix, Windows, VxWorks)
- os_sup Interface to OS system messages (Solaris, Windows)

To simplify usage of OS_Mon on distributed Erlang systems, it is not considered an error trying to use a service at a node where it is not available (either because OS_Mon is not running, or because the service is not available for that OS, or because the service is not started). Instead, a warning message is issued via error_logger and a dummy value is returned, which one is specified in the man pages for the respective services.

### Configuration

When OS_Mon is started, by default all services available for the OS, except os_sup, are automatically started. This configuration can be changed using the following application configuration parameters:

start_cpu_sup = bool()

  Specifies if cpu_sup should be started. Defaults to true.

start_disksup = bool()

  Specifies if disksup should be started. Defaults to true.

start_memsup = bool()

  Specifies if memsup should be started. Defaults to true.

start_os_sup = bool()

  Specifies if os_sup should be started. Defaults to false.

Configuration parameters effecting the different OS_Mon services are described in the respective man pages.

See config(4) for information about how to change the value of configuration parameters.

### SNMP MIBs

The following MIBs are defined in OS_Mon:

OTP-OS-MON-MIB

  This MIB contains objects for instrumentation of disk, memory and CPU usage of the nodes in the system.

The MIB is stored in the mibs directory. It is defined in SNMPv2 SMI syntax. An SNMPv1 version of the MIB is delivered in the mibs/v1 directory.

The compiled MIB is located under priv/mibs, and the generated .hrl file under the include directory. To compile a MIB that IMPORTS the OTP-OS-MON-MIB, give the option {il, ["os_mon/priv/mibs"]} to the MIB compiler.

If the MIB should be used in a system, it should be loaded into an agent with a call to os_mon_mib:load(Agent), where Agent is the pid or registered name of an SNMP agent. Use os_mon_mib:unload(Agent) to unload the MIB. The implementation of this MIB uses Mnesia to store a cache with data needed, which implicates that Mnesia must be up and running. The MIB also use functions defined for the OTP-MIB, thus that MIB must be loaded as well.

### See Also

cpu_sup(3), disksup(3), memsup(3), os_sup(3), nteventlog(3), snmp(3).