1disksup(3)                 Erlang Module Definition                 disksup(3)
2
3
4

NAME

6       disksup - A Disk Supervisor Process
7

DESCRIPTION

9       disksup  is  a process which supervises the available disk space in the
10       system. It is part of the OS_Mon application, see os_mon(6).  Available
11       for Unix and Windows.
12
13       Periodically  checks  the  disks. For each disk or partition which uses
14       more  than  a  certain  amount  of  the  available  space,  the   alarm
15       {{disk_almost_full, MountedOn}, []} is set.
16
17         On Unix:
18           All (locally) mounted disks are checked, including the swap disk if
19           it is present.
20
21         On WIN32:
22           All logical drives of type "FIXED_DISK" are checked.
23
24       Alarms are reported to the SASL alarm handler, see alarm_handler(3). To
25       set  an  alarm, alarm_handler:set_alarm(Alarm) is called where Alarm is
26       the alarm specified above.
27
28       The alarms are cleared automatically when the alarm cause is no  longer
29       valid.
30

CONFIGURATION

32       The  following  configuration  parameters  can  be  used  to change the
33       default values for time interval and threshold:
34
35         disk_space_check_interval = int()>0:
36           The time interval, in minutes, for the periodic disk  space  check.
37           The default is 30 minutes.
38
39         disk_almost_full_threshold = float():
40           The threshold, as percentage of total disk space, for how much disk
41           can be utilized before  the  disk_almost_full  alarm  is  set.  The
42           default is 0.80 (80%).
43
44         disksup_posix_only = bool():
45           Specifies  whether the disksup helper process should only use POSIX
46           conformant commands (true) or not. The default  is  false.  Setting
47           this  parameter  to  true can be necessary on embedded systems with
48           stripped-down versions of Unix tools like  df.  The  returned  disk
49           data and alarms can be different when using this option.
50
51           The  parameter  is  ignored  on  platforms that are known to not be
52           posix compatible (Windows and SunOS).
53
54       See config(4) for information about how to change the value of configu‐
55       ration parameters.
56

EXPORTS

58       get_disk_data() -> [DiskData]
59
60              Types:
61
62                 DiskData = {Id, KByte, Capacity}
63                  Id = string()
64                  KByte = int()
65                  Capacity = int()
66
67              Returns the result of the latest disk check. Id is a string that
68              identifies the disk or partition. KByte is the total size of the
69              disk  or partition in kbytes. Capacity is the percentage of disk
70              space used.
71
72              The function is asynchronous in  the  sense  that  it  does  not
73              invoke a disk check, but returns the latest available value.
74
75              Returns [{"none",0,0}] if disksup is not available.
76
77       get_check_interval() -> MS
78
79              Types:
80
81                 MS = int()
82
83              Returns  the  time  interval,  in milliseconds, for the periodic
84              disk space check.
85
86       set_check_interval(Minutes) -> ok
87
88              Types:
89
90                 Minutes = int()>=1
91
92              Changes the time interval, given in minutes,  for  the  periodic
93              disk space check.
94
95              The  change will take effect after the next disk space check and
96              is non-persist. That is, in case  of  a  process  restart,  this
97              value  is forgotten and the default value will be used. See Con‐
98              figuration above.
99
100       get_almost_full_threshold() -> Percent
101
102              Types:
103
104                 Percent = int()
105
106              Returns the threshold, in percent, for disk space utilization.
107
108       set_almost_full_threshold(Float) -> ok
109
110              Types:
111
112                 Float = float(), 0=<Float=<1
113
114              Changes the threshold, given as a float, for disk space utiliza‐
115              tion.
116
117              The change will take effect during the next disk space check and
118              is non-persist. That is, in case  of  a  process  restart,  this
119              value  is forgotten and the default value will be used. See Con‐
120              figuration above.
121

SEE ALSO

123       alarm_handler(3), os_mon(3)
124
125
126
127Ericsson AB                      os_mon 2.4.7                       disksup(3)
Impressum