| 1 | % Nagios Installation and Configuration |
|---|
| 2 | % |
|---|
| 3 | |
|---|
| 4 | # Introduction |
|---|
| 5 | |
|---|
| 6 | ## Goals |
|---|
| 7 | |
|---|
| 8 | * Optional exercises for Nagios |
|---|
| 9 | |
|---|
| 10 | ## Notes |
|---|
| 11 | |
|---|
| 12 | * Commands preceded with "$" imply that you should execute the command as |
|---|
| 13 | a general user - not as root. |
|---|
| 14 | * Commands preceded with "#" imply that you should be working as root. |
|---|
| 15 | * Commands with more specific command lines (e.g. "rtrX>" or "mysql>") |
|---|
| 16 | imply that you are executing commands on remote equipment, or within |
|---|
| 17 | another program. |
|---|
| 18 | |
|---|
| 19 | # Exercises |
|---|
| 20 | |
|---|
| 21 | |
|---|
| 22 | |
|---|
| 23 | # PART IX - Optional Exercises |
|---|
| 24 | |
|---|
| 25 | ## 1. Check that nagios is Running |
|---|
| 26 | |
|---|
| 27 | As opposed to just checking that a web server is running on the classroom PCs, |
|---|
| 28 | you could also check that t |
|---|
| 29 | he nagios3 service is available, by requesting the |
|---|
| 30 | /nagios3/ path. This means passing extra options to the check_http plugin. |
|---|
| 31 | |
|---|
| 32 | For a description of the available options, type this: |
|---|
| 33 | |
|---|
| 34 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 35 | # /usr/lib/nagios/plugins/check_http (short help) |
|---|
| 36 | # /usr/lib/nagios/plugins/check_http --help (detailed help) |
|---|
| 37 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 38 | |
|---|
| 39 | and of course you can browse the online nagios documentation or google |
|---|
| 40 | for information on check_http. You can even run the plugin by hand to |
|---|
| 41 | perform a one-shot service check: |
|---|
| 42 | |
|---|
| 43 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 44 | # /usr/lib/nagios/plugins/check_http -H localhost -u /nagios3/ |
|---|
| 45 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 46 | |
|---|
| 47 | So the goal is to configure nagios to call check_http in this way. |
|---|
| 48 | |
|---|
| 49 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 50 | {hint, /etc/nagios-plugins/config/http.cfg) |
|---|
| 51 | |
|---|
| 52 | define command{ |
|---|
| 53 | command_name check_http_url |
|---|
| 54 | command_line /usr/lib/nagios/plugins/check_http -H '$HOSTADDRESS$' -u '$ARG1$' |
|---|
| 55 | } |
|---|
| 56 | |
|---|
| 57 | (hint, /etc/nagios3/conf.d/services_nagios2.cfg_ |
|---|
| 58 | |
|---|
| 59 | define service { |
|---|
| 60 | hostgroup_name nagios-servers |
|---|
| 61 | service_description NAGIOS |
|---|
| 62 | check_command check_http_url!/nagios3/ |
|---|
| 63 | use generic-service |
|---|
| 64 | } |
|---|
| 65 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 66 | |
|---|
| 67 | and of course you'll need to create a hostgroup called nagios-servers to |
|---|
| 68 | link to this service check. (hint, /etc/nagios3/conf.d/hostgroups_nagios2.cfg) |
|---|
| 69 | |
|---|
| 70 | Once you have done this, check that Nagios warns you about failing |
|---|
| 71 | authentication (because it's trying to fetch the page without providing |
|---|
| 72 | the username/password). There's an extra parameter you can pass to |
|---|
| 73 | check_http to provide that info, so we need to define a new command |
|---|
| 74 | with an additional argument: |
|---|
| 75 | |
|---|
| 76 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 77 | define command{ |
|---|
| 78 | command_name check_http_url_auth |
|---|
| 79 | command_line /usr/lib/nagios/plugins/check_http -H '$HOSTADDRESS$' -u '$ARG1$' -a '$ARG2$' |
|---|
| 80 | } |
|---|
| 81 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 82 | |
|---|
| 83 | And you invoke it: |
|---|
| 84 | |
|---|
| 85 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 86 | check_command check_http_url_auth!/nagios3/!nagiosadmin:password |
|---|
| 87 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 88 | |
|---|
| 89 | WARNING: in the tradition of "Debian Knows Best", their definition of the |
|---|
| 90 | check_http command in /etc/nagios-plugins/config/http.cfg |
|---|
| 91 | is *not* the same as that recommended in the nagios3 documentation. |
|---|
| 92 | It is missing $ARG1$, so any parameters to pass to check_http are |
|---|
| 93 | ignored. So you might think you are monitoring /nagios3/ but actually |
|---|
| 94 | you are monitoring root! |
|---|
| 95 | |
|---|
| 96 | This is why we had to make a new command definition "check_http_url". |
|---|
| 97 | You could make a more specific one like "check_nagios", or you could |
|---|
| 98 | modify the Ubuntu check_http definition to fit the standard usage. |
|---|
| 99 | |
|---|
| 100 | |
|---|
| 101 | ## 2. Check that SNMP is running on the classroom NOC |
|---|
| 102 | |
|---|
| 103 | |
|---|
| 104 | This exercise will not work if you did not complete the installation of additional |
|---|
| 105 | SNMP MIBs at the start of the week and configure /etc/snmp/snmp.conf properly. Please refer to the original snmp exercises if you are unsure. |
|---|
| 106 | |
|---|
| 107 | First you will need to add in the appropriate service check for SNMP in the file |
|---|
| 108 | /etc/nagios3/conf.d/services_nagios2.cfg. This is where Nagios is impressive. There |
|---|
| 109 | are hundreds, if not thousands, of service checks available via the various Nagios |
|---|
| 110 | sites on the web. You can see what plugins are installed by Ubuntu in the nagios3 |
|---|
| 111 | package that we've installed by looking in the following directory: |
|---|
| 112 | |
|---|
| 113 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 114 | # ls /usr/lib/nagios/plugins |
|---|
| 115 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 116 | |
|---|
| 117 | As you'll see there is already a check_snmp plugin available to us. If you are |
|---|
| 118 | interested in the options the plugin takes you can execute the plugin from the |
|---|
| 119 | command line by typing: |
|---|
| 120 | |
|---|
| 121 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 122 | # /usr/lib/nagios/plugins/check_snmp (short help) |
|---|
| 123 | # /usr/lib/nagios/plugins/check_snmp --help (detailed help) |
|---|
| 124 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 125 | |
|---|
| 126 | to see what options are available, etc. You can use the check_snmp plugin and |
|---|
| 127 | Nagios to create very complex or specific system checks. |
|---|
| 128 | |
|---|
| 129 | Now to see all the various service/host checks that have been created using the |
|---|
| 130 | check_snmp plugin you can look in /etc/nagios-plugins/config/snmp.cfg. You will |
|---|
| 131 | see that there are a lot of preconfigured checks using snmp, including: |
|---|
| 132 | |
|---|
| 133 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 134 | snmp_load |
|---|
| 135 | snmp_cpustats |
|---|
| 136 | snmp_procname |
|---|
| 137 | snmp_disk |
|---|
| 138 | snmp_mem |
|---|
| 139 | snmp_swap |
|---|
| 140 | snmp_procs |
|---|
| 141 | snmp_users |
|---|
| 142 | snmp_mem2 |
|---|
| 143 | snmp_swap2 |
|---|
| 144 | snmp_mem3 |
|---|
| 145 | snmp_swap3 |
|---|
| 146 | snmp_disk2 |
|---|
| 147 | snmp_tcpopen |
|---|
| 148 | snmp_tcpstats |
|---|
| 149 | snmp_bgpstate |
|---|
| 150 | check_netapp_uptime |
|---|
| 151 | check_netapp_cupuload |
|---|
| 152 | check_netapp_numdisks |
|---|
| 153 | check_compaq_thermalCondition |
|---|
| 154 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 155 | |
|---|
| 156 | And, even better, you can create additional service checks quite easily. |
|---|
| 157 | For the case of verifying that snmpd (the SNMP service on Linux) is running we |
|---|
| 158 | need to ask SNMP a question. If we don't get an answer, then Nagios can assume |
|---|
| 159 | that the SNMP service is down on that host. When you use service checks such as |
|---|
| 160 | check_http, check_ssh and check_telnet this is what they are doing as well. |
|---|
| 161 | |
|---|
| 162 | In our case, let's create a new service check and call it "check_system". This |
|---|
| 163 | service check will connect with the specified host, use the private community |
|---|
| 164 | string we have defined in class and ask a question of snmp on that host - in this |
|---|
| 165 | case we'll ask about the System Description, or the OID "sysDescr.0" - |
|---|
| 166 | |
|---|
| 167 | To do this start by editing the file /etc/nagios-plugins/config/snmp.cfg: |
|---|
| 168 | |
|---|
| 169 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 170 | # editor /etc/nagios-plugins/config/snmp.cfg |
|---|
| 171 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 172 | |
|---|
| 173 | At the top (or the bottom, your choice) add the following entry to the file: |
|---|
| 174 | |
|---|
| 175 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 176 | # 'check_system' command definition |
|---|
| 177 | define command{ |
|---|
| 178 | command_name check_system |
|---|
| 179 | command_line /usr/lib/nagios/plugins/check_snmp -H '$HOSTADDRESS$' -C '$ARG1$' -o sysDescr.0 |
|---|
| 180 | } |
|---|
| 181 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 182 | |
|---|
| 183 | COPY and PASTE this. Do not type this by hand and make sure that the command_line line |
|---|
| 184 | does not wrap. |
|---|
| 185 | |
|---|
| 186 | Note that "command_line" is a single line. If you copy and paste in |
|---|
| 187 | your editor, the line may not wrap properly and you may have to manually |
|---|
| 188 | "join" the two lines so they are one. |
|---|
| 189 | |
|---|
| 190 | Now you need to edit the file /etc/nagios3/conf.d/services_nagios2.cfg and add |
|---|
| 191 | in this service check. We'll run this check against all our servers in the |
|---|
| 192 | classroom, or the hostgroup "debian-servers" |
|---|
| 193 | |
|---|
| 194 | Edit the file /etc/nagios3/conf.d/services_nagios2.cfg |
|---|
| 195 | |
|---|
| 196 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 197 | # editor /etc/nagios3/conf.d/services_nagios2.cfg |
|---|
| 198 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 199 | |
|---|
| 200 | At the bottom of the file add the following definition: |
|---|
| 201 | |
|---|
| 202 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 203 | # check that snmp is up on all servers |
|---|
| 204 | define service { |
|---|
| 205 | hostgroup_name snmp-servers |
|---|
| 206 | service_description SNMP |
|---|
| 207 | check_command check_system!xxxxxx |
|---|
| 208 | use generic-service |
|---|
| 209 | notification_interval 0 ; set > 0 if you want to be renotified |
|---|
| 210 | } |
|---|
| 211 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 212 | |
|---|
| 213 | The "xxxxxx" is the community string previously (or to be) defined in class. |
|---|
| 214 | |
|---|
| 215 | Note that we have included our own community string here vs. hard-coding |
|---|
| 216 | it in the snmp.cfg file earlier. You must change the "xxxxx" to be the snmp |
|---|
| 217 | community string given in class or this check will not work. |
|---|
| 218 | |
|---|
| 219 | Now we must create the "snmp-servers" group in our hostgroups_nagios2.cfg file. |
|---|
| 220 | Edit the file /etc/nagios3/conf.d/hostgroups_nagios2.cfg and go to the end of the |
|---|
| 221 | file. Add in the following hostgroup definition: |
|---|
| 222 | |
|---|
| 223 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 224 | # A list of snmp-enabled devices on which we wish to run the snmp service check |
|---|
| 225 | define hostgroup { |
|---|
| 226 | hostgroup_name snmp-servers |
|---|
| 227 | alias snmp servers |
|---|
| 228 | members noc,localhost,pc1,pc2,pc3,pc4...pc36,rtr1,rtr2,rtr3...rtr9 |
|---|
| 229 | } |
|---|
| 230 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 231 | |
|---|
| 232 | Note that for "members" you can add in all PCs and routers as they should all |
|---|
| 233 | have snmp up and running at this time. Remember to EXCLUDE our pc and use |
|---|
| 234 | localhost instead. |
|---|
| 235 | |
|---|
| 236 | Now verify that your changes are correct and restart Nagios. |
|---|
| 237 | |
|---|
| 238 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 239 | # service nagios3 restart |
|---|
| 240 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 241 | |
|---|
| 242 | **** Defect / Bug in Ubuntu 12.04 LTS *** |
|---|
| 243 | |
|---|
| 244 | The net-snmp 5.6.x package appears to not install one of the IANA mibs (IANAifType-MIB). |
|---|
| 245 | This causes a MIB error, which, in turn causes the snmp check plugin to fail. To fix |
|---|
| 246 | this problem do the following (as root): |
|---|
| 247 | |
|---|
| 248 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 249 | # cd /usr/share/mibs |
|---|
| 250 | # wget http://www.iana.org/assignments/ianaiftype-mib/ianaiftype-mib |
|---|
| 251 | # mv ianaiftype-mib ianaiftype-mib.my |
|---|
| 252 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 253 | |
|---|
| 254 | And, now you can continue. |
|---|
| 255 | |
|---|
| 256 | If you click on the Service Detail menu choice in web interface you should see |
|---|
| 257 | the SNMP check appear for the noc host, or for any other hosts you may have |
|---|
| 258 | included on the "members" line above. |
|---|
| 259 | |
|---|
| 260 | |
|---|
| 261 | ## 3. Check other settings using SNMP |
|---|
| 262 | |
|---|
| 263 | The real purpose for check_snmp is to poll devices for their status. It can |
|---|
| 264 | be used, for example, to check that power supplies and fans are functioning |
|---|
| 265 | normally. |
|---|
| 266 | |
|---|
| 267 | In order to do this, you will need to find the OID(s) of interest and the |
|---|
| 268 | values which you want to be alerted on for warning and critical status. |
|---|
| 269 | |
|---|
| 270 | The following example checks the power supply status of a Netgear 72xx |
|---|
| 271 | series switch with dual power supplies running 8.x firmware. Nagios doesn't |
|---|
| 272 | care which file each definition goes in, but some locations are suggested. |
|---|
| 273 | |
|---|
| 274 | ~~~ |
|---|
| 275 | # This could go in your switches.cfg or in services_nagios2.cfg |
|---|
| 276 | |
|---|
| 277 | define service { |
|---|
| 278 | hostgroup_name netgear72xx-8x-switches |
|---|
| 279 | service_description PSUs |
|---|
| 280 | check_command check_netgear72xx_8x_power_dual!<community> |
|---|
| 281 | use generic-service |
|---|
| 282 | } |
|---|
| 283 | |
|---|
| 284 | # This could go in /etc/nagios-plugins/config/netgear-8x.cfg |
|---|
| 285 | |
|---|
| 286 | define command{ |
|---|
| 287 | command_name check_netgear72xx_8x_power_dual |
|---|
| 288 | command_line /usr/lib/nagios/plugins/check_snmp -H '$HOSTADDRESS$' \ |
|---|
| 289 | -o .1.3.6.1.4.1.4526.10.43.1.7.1.3.0,.1.3.6.1.4.1.4526.10.43.1.7.1.3.1 \ |
|---|
| 290 | -C '$ARG1$' -u 'PSU1,PSU2' -w @5:5,@5:5 -c @2:2,@2:2 -l "PSU status " |
|---|
| 291 | } |
|---|
| 292 | ~~~ |
|---|
| 293 | |
|---|
| 294 | You'd also create a hostgroup "netgear72xx-8x-switches" and make the switches |
|---|
| 295 | members of this group, so that Nagios runs this check on those devices. |
|---|
| 296 | |
|---|
| 297 | Notice that the `-o` option contains the two OIDs we want to poll, and the |
|---|
| 298 | `-w` and `-c` options give the values to check for. This makes use of a |
|---|
| 299 | feature of check_snmp that is not well documented: |
|---|
| 300 | |
|---|
| 301 | * `-w <x>:<y>` gives a warning if the value is *not* between x and y |
|---|
| 302 | * `-w @<x>:<y>` gives a warning if the value *is* between x and y |
|---|
| 303 | |
|---|
| 304 | The [MIB](http://www.downloads.netgear.com/files/GDC/GSM7224V2/gsm72xxv2-8.0.1.29-mibs.tar.bz2) |
|---|
| 305 | (fastpath_boxservices.my) contains the following definitions: |
|---|
| 306 | |
|---|
| 307 | ~~~ |
|---|
| 308 | boxServicesPowSupplyItemState OBJECT-TYPE |
|---|
| 309 | SYNTAX INTEGER { |
|---|
| 310 | operational(1), |
|---|
| 311 | failed(2), |
|---|
| 312 | powering(3), |
|---|
| 313 | notpowering(4), |
|---|
| 314 | notpresent(5) |
|---|
| 315 | } |
|---|
| 316 | MAX-ACCESS read-only |
|---|
| 317 | STATUS current |
|---|
| 318 | DESCRIPTION |
|---|
| 319 | "The status of power supply" |
|---|
| 320 | ::= { boxServicesPowSuppliesEntry 3 } |
|---|
| 321 | ~~~ |
|---|
| 322 | |
|---|
| 323 | Therefore, we get a warning if the status is `notpresent(5)`, and a critical |
|---|
| 324 | error if the status is `failed(2)`. |
|---|
| 325 | |
|---|
| 326 | Note: `notpowering(4)` means that the PSU is good but the device is being |
|---|
| 327 | powered by the other PSU. This is not an error. |
|---|
| 328 | |
|---|
| 329 | You should be able to adapt this recipe to other types of equipment, and for |
|---|
| 330 | checking fan status and temperature, by adjusting the OIDs and values |
|---|
| 331 | appropriately. |
|---|
| 332 | |
|---|
| 333 | The OID .1.3.6.1.4.1.4526.10.43.1.7.1.3 comes from: |
|---|
| 334 | |
|---|
| 335 | ~~~ |
|---|
| 336 | netgear OBJECT IDENTIFIER ::= { enterprises 4526 } |
|---|
| 337 | |
|---|
| 338 | ng7000managedswitch OBJECT IDENTIFIER ::= { netgear 10 } |
|---|
| 339 | |
|---|
| 340 | fastPathBoxServices MODULE-IDENTITY |
|---|
| 341 | LAST-UPDATED "200802220000Z" -- 22 Feb 2008 12:00:00 GMT |
|---|
| 342 | ORGANIZATION "Netgear" |
|---|
| 343 | CONTACT-INFO |
|---|
| 344 | ""... |
|---|
| 345 | ::= { ng7000managedswitch 43 } |
|---|
| 346 | |
|---|
| 347 | boxServicesGroup OBJECT IDENTIFIER ::= { fastPathBoxServices 1 } |
|---|
| 348 | |
|---|
| 349 | boxServicesPowSuppliesTable OBJECT-TYPE |
|---|
| 350 | SYNTAX SEQUENCE OF BoxServicesPowSuppliesEntry |
|---|
| 351 | MAX-ACCESS not-accessible |
|---|
| 352 | STATUS current |
|---|
| 353 | DESCRIPTION |
|---|
| 354 | "Power supply" |
|---|
| 355 | ::= { boxServicesGroup 7 } |
|---|
| 356 | |
|---|
| 357 | boxServicesPowSuppliesEntry OBJECT-TYPE |
|---|
| 358 | SYNTAX BoxServicesPowSuppliesEntry |
|---|
| 359 | MAX-ACCESS not-accessible |
|---|
| 360 | STATUS current |
|---|
| 361 | DESCRIPTION |
|---|
| 362 | "Box Services Power Supply Entry" |
|---|
| 363 | INDEX { boxServicesPowSupplyIndex } |
|---|
| 364 | ::= { boxServicesPowSuppliesTable 1 } |
|---|
| 365 | |
|---|
| 366 | BoxServicesPowSuppliesEntry ::= SEQUENCE { |
|---|
| 367 | boxServicesPowSupplyIndex |
|---|
| 368 | Integer32, |
|---|
| 369 | boxServicesPowSupplyItemType |
|---|
| 370 | INTEGER, |
|---|
| 371 | boxServicesPowSupplyItemState |
|---|
| 372 | INTEGER |
|---|
| 373 | } |
|---|
| 374 | |
|---|
| 375 | boxServicesPowSupplyIndex OBJECT-TYPE |
|---|
| 376 | SYNTAX Integer32 (0..2147483647) |
|---|
| 377 | MAX-ACCESS read-only |
|---|
| 378 | STATUS current |
|---|
| 379 | DESCRIPTION |
|---|
| 380 | "Unique index of power supply table entry" |
|---|
| 381 | ::= { boxServicesPowSuppliesEntry 1 } |
|---|
| 382 | ~~~ |
|---|
| 383 | |
|---|
| 384 | A device with only one power supply connected reports under |
|---|
| 385 | `FASTPATH-BOXSERVICES-PRIVATE-MIB::boxServicesPowSuppliesTable`: |
|---|
| 386 | |
|---|
| 387 | ~~~ |
|---|
| 388 | .1.3.6.1.4.1.4526.10.43.1.7.1.1.0 = INTEGER: 0 |
|---|
| 389 | .1.3.6.1.4.1.4526.10.43.1.7.1.1.1 = INTEGER: 1 |
|---|
| 390 | .1.3.6.1.4.1.4526.10.43.1.7.1.2.0 = INTEGER: fixed(1) |
|---|
| 391 | .1.3.6.1.4.1.4526.10.43.1.7.1.2.1 = INTEGER: removable(2) |
|---|
| 392 | .1.3.6.1.4.1.4526.10.43.1.7.1.3.0 = INTEGER: operational(1) |
|---|
| 393 | .1.3.6.1.4.1.4526.10.43.1.7.1.3.1 = INTEGER: notpresent(5) |
|---|
| 394 | ~~~ |
|---|
| 395 | |
|---|
| 396 | or with translation of OIDs: |
|---|
| 397 | |
|---|
| 398 | ~~~ |
|---|
| 399 | FASTPATH-BOXSERVICES-PRIVATE-MIB::boxServicesPowSupplyIndex.0 = INTEGER: 0 |
|---|
| 400 | FASTPATH-BOXSERVICES-PRIVATE-MIB::boxServicesPowSupplyIndex.1 = INTEGER: 1 |
|---|
| 401 | FASTPATH-BOXSERVICES-PRIVATE-MIB::boxServicesPowSupplyItemType.0 = INTEGER: fixed(1) |
|---|
| 402 | FASTPATH-BOXSERVICES-PRIVATE-MIB::boxServicesPowSupplyItemType.1 = INTEGER: removable(2) |
|---|
| 403 | FASTPATH-BOXSERVICES-PRIVATE-MIB::boxServicesPowSupplyItemState.0 = INTEGER: operational(1) |
|---|
| 404 | FASTPATH-BOXSERVICES-PRIVATE-MIB::boxServicesPowSupplyItemState.1 = INTEGER: notpresent(5) |
|---|
| 405 | ~~~ |
|---|
| 406 | |
|---|