1-- 2-- Copyright (c) 2013 Mikolaj Golub <trociny@FreeBSD.org> 3-- All rights reserved. 4-- 5-- Redistribution and use in source and binary forms, with or without 6-- modification, are permitted provided that the following conditions 7-- are met: 8-- 1. Redistributions of source code must retain the above copyright 9-- notice, this list of conditions and the following disclaimer. 10-- 2. Redistributions in binary form must reproduce the above copyright 11-- notice, this list of conditions and the following disclaimer in the 12-- documentation and/or other materials provided with the distribution. 13-- 14-- THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 15-- ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 16-- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 17-- ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 18-- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19-- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20-- OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21-- HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22-- LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23-- OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24-- SUCH DAMAGE. 25-- 26-- $FreeBSD$ 27-- 28 29BEGEMOT-HAST-MIB DEFINITIONS ::= BEGIN 30 31IMPORTS 32 MODULE-IDENTITY, OBJECT-TYPE, NOTIFICATION-TYPE, 33 Counter64, Integer32 34 FROM SNMPv2-SMI 35 TEXTUAL-CONVENTION, RowStatus 36 FROM SNMPv2-TC 37 InterfaceIndex, ifIndex 38 FROM IF-MIB 39 begemot 40 FROM BEGEMOT-MIB; 41 42begemotHast MODULE-IDENTITY 43 LAST-UPDATED "201304130000Z" 44 ORGANIZATION "FreeBSD" 45 CONTACT-INFO 46 " Mikolaj Golub 47 48 Postal: Bluhera 27v 11 49 61146 Kharkiv 50 Ukraine 51 52 Fax: N/A 53 54 E-Mail: trociny@FreeBSD.org" 55 DESCRIPTION 56 "The Begemot MIB for managing HAST." 57 REVISION "201304130000Z" 58 DESCRIPTION 59 "Initial revision." 60 REVISION "201307010000Z" 61 DESCRIPTION 62 "Added hastResourceWorkerPid." 63 ::= { begemot 220 } 64 65begemotHastObjects OBJECT IDENTIFIER ::= { begemotHast 1 } 66 67-- ---------------------------------------------------------- -- 68-- Configuration parameters 69-- ---------------------------------------------------------- -- 70 71hastConfig OBJECT IDENTIFIER ::= { begemotHastObjects 1 } 72 73hastConfigFile OBJECT-TYPE 74 SYNTAX OCTET STRING 75 MAX-ACCESS read-only 76 STATUS current 77 DESCRIPTION 78 "HAST configuration file location." 79 ::= { hastConfig 1 } 80 81-- ---------------------------------------------------------- -- 82-- Resource Table 83-- ---------------------------------------------------------- -- 84hastResourceTable OBJECT-TYPE 85 SYNTAX SEQUENCE OF HastResourceEntry 86 MAX-ACCESS not-accessible 87 STATUS current 88 DESCRIPTION 89 "A table containing information about all HAST resources." 90 ::= { begemotHastObjects 2 } 91 92hastResourceEntry OBJECT-TYPE 93 SYNTAX HastResourceEntry 94 MAX-ACCESS not-accessible 95 STATUS current 96 DESCRIPTION 97 "Table entry that describes one HAST resource." 98 INDEX { hastResourceIndex } 99 ::= { hastResourceTable 1 } 100 101HastResourceEntry ::= SEQUENCE { 102 hastResourceIndex Integer32, 103 hastResourceName OCTET STRING, 104 hastResourceRole INTEGER, 105 hastResourceProvName OCTET STRING, 106 hastResourceLocalPath OCTET STRING, 107 hastResourceExtentSize Integer32, 108 hastResourceKeepDirty Integer32, 109 hastResourceRemoteAddr OCTET STRING, 110 hastResourceSourceAddr OCTET STRING, 111 hastResourceReplication INTEGER, 112 hastResourceStatus INTEGER, 113 hastResourceDirty Counter64, 114 hastResourceReads Counter64, 115 hastResourceWrites Counter64, 116 hastResourceDeletes Counter64, 117 hastResourceFlushes Counter64, 118 hastResourceActivemapUpdates Counter64, 119 hastResourceReadErrors Counter64, 120 hastResourceWriteErrors Counter64, 121 hastResourceDeleteErrors Counter64, 122 hastResourceFlushErrors Counter64, 123 hastResourceWorkerPid INTEGER 124} 125 126hastResourceIndex OBJECT-TYPE 127 SYNTAX Integer32 128 MAX-ACCESS read-only 129 STATUS current 130 DESCRIPTION 131 "Resource index." 132 ::= { hastResourceEntry 1 } 133 134hastResourceName OBJECT-TYPE 135 SYNTAX OCTET STRING 136 MAX-ACCESS read-only 137 STATUS current 138 DESCRIPTION 139 "Resource name." 140 ::= { hastResourceEntry 2 } 141 142hastResourceRole OBJECT-TYPE 143 SYNTAX INTEGER { undef(0), init(1), primary(2), secondary(3) } 144 MAX-ACCESS read-write 145 STATUS current 146 DESCRIPTION 147 "Resource role." 148 ::= { hastResourceEntry 3 } 149 150hastResourceProvName OBJECT-TYPE 151 SYNTAX OCTET STRING 152 MAX-ACCESS read-only 153 STATUS current 154 DESCRIPTION 155 "Resource GEOM provider name that appears as /dev/hast/<name>." 156 ::= { hastResourceEntry 4 } 157 158hastResourceLocalPath OBJECT-TYPE 159 SYNTAX OCTET STRING 160 MAX-ACCESS read-only 161 STATUS current 162 DESCRIPTION 163 "Path to the local component which is used as a backend 164 provider for the resource." 165 ::= { hastResourceEntry 5 } 166 167hastResourceExtentSize OBJECT-TYPE 168 SYNTAX Integer32 169 MAX-ACCESS read-only 170 STATUS current 171 DESCRIPTION 172 "Size of an extent. Extent is a block which is 173 used for synchronization. hastd(8) maintains a 174 map of dirty extents and extent is the smallest 175 region that can be marked as dirty. If any part 176 of an extent is modified, entire extent will be 177 synchronized when nodes connect." 178 ::= { hastResourceEntry 6 } 179 180hastResourceKeepDirty OBJECT-TYPE 181 SYNTAX Integer32 182 MAX-ACCESS read-only 183 STATUS current 184 DESCRIPTION 185 "Maximum number of dirty extents to keep dirty all 186 the time. Most recently used extents are kept 187 dirty to reduce number of metadata updates." 188 ::= { hastResourceEntry 7 } 189 190hastResourceRemoteAddr OBJECT-TYPE 191 SYNTAX OCTET STRING 192 MAX-ACCESS read-only 193 STATUS current 194 DESCRIPTION 195 "Address of the remote hastd(8) daemon for the resource." 196 ::= { hastResourceEntry 8 } 197 198hastResourceSourceAddr OBJECT-TYPE 199 SYNTAX OCTET STRING 200 MAX-ACCESS read-only 201 STATUS current 202 DESCRIPTION 203 "Local address the resource is bound to." 204 ::= { hastResourceEntry 9 } 205 206hastResourceReplication OBJECT-TYPE 207 SYNTAX INTEGER { fullsync(0), memsync(1), async(2) } 208 MAX-ACCESS read-only 209 STATUS current 210 DESCRIPTION 211 "Resource replication mode." 212 ::= { hastResourceEntry 10 } 213 214hastResourceStatus OBJECT-TYPE 215 SYNTAX INTEGER { complete(0), degraded(1) } 216 MAX-ACCESS read-only 217 STATUS current 218 DESCRIPTION 219 "Resource replication status." 220 ::= { hastResourceEntry 11 } 221 222hastResourceDirty OBJECT-TYPE 223 SYNTAX Counter64 224 MAX-ACCESS read-only 225 STATUS current 226 DESCRIPTION 227 "Current number of dirty extents for the resource." 228 ::= { hastResourceEntry 12 } 229 230hastResourceReads OBJECT-TYPE 231 SYNTAX Counter64 232 MAX-ACCESS read-only 233 STATUS current 234 DESCRIPTION 235 "Count of resource local read operations." 236 ::= { hastResourceEntry 13 } 237 238hastResourceWrites OBJECT-TYPE 239 SYNTAX Counter64 240 MAX-ACCESS read-only 241 STATUS current 242 DESCRIPTION 243 "Count of resource local write operations." 244 ::= { hastResourceEntry 14 } 245 246hastResourceDeletes OBJECT-TYPE 247 SYNTAX Counter64 248 MAX-ACCESS read-only 249 STATUS current 250 DESCRIPTION 251 "Count of resource local delete operations." 252 ::= { hastResourceEntry 15 } 253 254hastResourceFlushes OBJECT-TYPE 255 SYNTAX Counter64 256 MAX-ACCESS read-only 257 STATUS current 258 DESCRIPTION 259 "Count of resource local flush operations." 260 ::= { hastResourceEntry 16 } 261 262hastResourceActivemapUpdates OBJECT-TYPE 263 SYNTAX Counter64 264 MAX-ACCESS read-only 265 STATUS current 266 DESCRIPTION 267 "Count of resource local activemap updates." 268 ::= { hastResourceEntry 17 } 269 270hastResourceReadErrors OBJECT-TYPE 271 SYNTAX Counter64 272 MAX-ACCESS read-only 273 STATUS current 274 DESCRIPTION 275 "Count of resource local read operations that failed." 276 ::= { hastResourceEntry 18 } 277 278hastResourceWriteErrors OBJECT-TYPE 279 SYNTAX Counter64 280 MAX-ACCESS read-only 281 STATUS current 282 DESCRIPTION 283 "Count of resource local write operations that failed." 284 ::= { hastResourceEntry 19 } 285 286hastResourceDeleteErrors OBJECT-TYPE 287 SYNTAX Counter64 288 MAX-ACCESS read-only 289 STATUS current 290 DESCRIPTION 291 "Count of resource local delete operations that failed." 292 ::= { hastResourceEntry 20 } 293 294hastResourceFlushErrors OBJECT-TYPE 295 SYNTAX Counter64 296 MAX-ACCESS read-only 297 STATUS current 298 DESCRIPTION 299 "Count of resource local flush operations that failed." 300 ::= { hastResourceEntry 21 } 301 302hastResourceWorkerPid OBJECT-TYPE 303 SYNTAX INTEGER 304 MAX-ACCESS read-only 305 STATUS current 306 DESCRIPTION 307 "Worker process ID." 308 ::= { hastResourceEntry 22 } 309 310END 311