自定义通用物联网网关的MIB结构的参考

文章目录

说明

参考代码

bash 复制代码
--
-- IOTGATEWAY-MIB.my
-- MIB generated by MG-SOFT Visual MIB Builder Version 6.0  Build 88
-- Tuesday, December 19, 2023 at 20:04:38
--

	IOTGATEWAY-MIB DEFINITIONS ::= BEGIN
 
		IMPORTS
			OBJECT-GROUP, NOTIFICATION-GROUP			
				FROM SNMPv2-CONF			
			enterprises, TimeTicks, IpAddress, Integer32, Gauge32, 
			Counter32, OBJECT-TYPE, MODULE-IDENTITY, OBJECT-IDENTITY, NOTIFICATION-TYPE			
				FROM SNMPv2-SMI;
	
	
		-- 1.3.6.1.4.1.99999.1.1
		iotGateway MODULE-IDENTITY 
			LAST-UPDATED "202312061422Z"		-- December 06, 2023 at 14:22 GMT
			ORGANIZATION 
				"yangzhou"
			CONTACT-INFO 
				"Contact Information"
			DESCRIPTION 
				"MIB for managing IoT Gateway devices."
			REVISION "202312061425Z"		-- December 06, 2023 at 14:25 GMT
			DESCRIPTION 
				"Initial version."
			::= { iotGatewayMIB 1 }

		
	
--
-- Node definitions
--
	
		-- 1.3.6.1.4.1.99999
		yangzhouzhang OBJECT IDENTIFIER ::= { enterprises 99999 }

		
		-- 1.3.6.1.4.1.99999.1
		iotGatewayMIB OBJECT IDENTIFIER ::= { yangzhouzhang 1 }

		
		-- 1.3.6.1.4.1.99999.1.3
		deviceInfoGroup OBJECT IDENTIFIER ::= { iotGatewayMIB 3 }

		
		-- 1.3.6.1.4.1.99999.1.3.1
		deviceModel OBJECT-TYPE
			SYNTAX OCTET STRING
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"The model identifier for the IoT Gateway."
			::= { deviceInfoGroup 1 }

		
		-- 1.3.6.1.4.1.99999.1.3.2
		deviceName OBJECT-TYPE
			SYNTAX OCTET STRING (SIZE (0..255))
			MAX-ACCESS read-write
			STATUS current
			DESCRIPTION
				"Name of the gateway device"
			::= { deviceInfoGroup 2 }

		
		-- 1.3.6.1.4.1.99999.1.3.4
		serialNumber OBJECT-TYPE
			SYNTAX OCTET STRING
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"The serial number of the IoT Gateway."
			::= { deviceInfoGroup 4 }

		
		-- 1.3.6.1.4.1.99999.1.3.5
		firmwareVersion OBJECT-TYPE
			SYNTAX OCTET STRING
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Description."
			::= { deviceInfoGroup 5 }

		
		-- 1.3.6.1.4.1.99999.1.3.6
		uptime OBJECT-TYPE
			SYNTAX TimeTicks
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"The time since the IoT Gateway last restarted."
			::= { deviceInfoGroup 6 }

		
		-- 1.3.6.1.4.1.99999.1.3.7
		devInfoGroup OBJECT-GROUP
			OBJECTS { deviceModel, deviceName, serialNumber, firmwareVersion, uptime
				 }
			STATUS current
			DESCRIPTION 
				"Description."
			::= { deviceInfoGroup 7 }

		
		-- 1.3.6.1.4.1.99999.1.5
		networkConfigGroup OBJECT IDENTIFIER ::= { iotGatewayMIB 5 }

		
		-- 1.3.6.1.4.1.99999.1.5.1
		ipAddress OBJECT-TYPE
			SYNTAX IpAddress
			MAX-ACCESS read-write
			STATUS current
			DESCRIPTION
				"IP address of the gateway"
			::= { networkConfigGroup 1 }

		
		-- 1.3.6.1.4.1.99999.1.5.2
		subnetMask OBJECT-TYPE
			SYNTAX IpAddress
			MAX-ACCESS read-write
			STATUS current
			DESCRIPTION
				"Subnet mask of the gateway"
			::= { networkConfigGroup 2 }

		
		-- 1.3.6.1.4.1.99999.1.5.3
		defaultGateway OBJECT-TYPE
			SYNTAX IpAddress
			MAX-ACCESS read-write
			STATUS current
			DESCRIPTION
				"Default gateway IP address"
			::= { networkConfigGroup 3 }

		
		-- 1.3.6.1.4.1.99999.1.5.4
		dnsServers OBJECT-TYPE
			SYNTAX OCTET STRING (SIZE (0..255))
			MAX-ACCESS read-write
			STATUS current
			DESCRIPTION
				"List of DNS server IP addresses"
			::= { networkConfigGroup 4 }

		
		-- 1.3.6.1.4.1.99999.1.5.5
		ntpServer OBJECT-TYPE
			SYNTAX IpAddress
			MAX-ACCESS read-write
			STATUS current
			DESCRIPTION
				"NTP server IP address"
			::= { networkConfigGroup 5 }

		
		-- 1.3.6.1.4.1.99999.1.5.6
		netConfigGroup OBJECT-GROUP
			OBJECTS { ipAddress, subnetMask, defaultGateway, dnsServers, ntpServer
				 }
			STATUS current
			DESCRIPTION 
				"Description."
			::= { networkConfigGroup 6 }

		
		-- 1.3.6.1.4.1.99999.1.8
		devicePerformanceGroup OBJECT IDENTIFIER ::= { iotGatewayMIB 8 }

		
		-- 1.3.6.1.4.1.99999.1.8.1
		dataThroughput OBJECT-TYPE
			SYNTAX Integer32
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Data throughput in bytes per second"
			::= { devicePerformanceGroup 1 }

		
		-- 1.3.6.1.4.1.99999.1.8.2
		packetLossRate OBJECT-TYPE
			SYNTAX Integer32 (0..100)
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Packet loss rate in percentage"
			::= { devicePerformanceGroup 2 }

		
		-- 1.3.6.1.4.1.99999.1.8.3
		responseTime OBJECT-TYPE
			SYNTAX Integer32
			UNITS "milliseconds"
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Response time in milliseconds"
			::= { devicePerformanceGroup 3 }

		
		-- 1.3.6.1.4.1.99999.1.8.4
		deviceTemperature OBJECT-TYPE
			SYNTAX Integer32 (-50..100)
			UNITS "degrees Celsiu"
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Device temperature in degrees Celsius"
			::= { devicePerformanceGroup 4 }

		
		-- 1.3.6.1.4.1.99999.1.8.5
		devPerformanceGroup OBJECT-GROUP
			OBJECTS { dataThroughput, packetLossRate, responseTime, deviceTemperature }
			STATUS current
			DESCRIPTION 
				"Description."
			::= { devicePerformanceGroup 5 }

		
		-- 1.3.6.1.4.1.99999.1.11
		eventsAndAlarmsGroup OBJECT IDENTIFIER ::= { iotGatewayMIB 11 }

		
		-- 1.3.6.1.4.1.99999.1.11.2
		currentActiveAlarms OBJECT-TYPE
			SYNTAX Gauge32
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Number of current active alarms"
			::= { eventsAndAlarmsGroup 2 }

		
		-- 1.3.6.1.4.1.99999.1.11.3
		historicalAlarmsRecord OBJECT-TYPE
			SYNTAX OCTET STRING
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Historical alarms record"
			::= { eventsAndAlarmsGroup 3 }

		
		-- 1.3.6.1.4.1.99999.1.11.4
		eventLog OBJECT-TYPE
			SYNTAX OCTET STRING
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Event log"
			::= { eventsAndAlarmsGroup 4 }

		
		-- 1.3.6.1.4.1.99999.1.11.5
		evAndAlaGroup OBJECT-GROUP
			OBJECTS { eventLog, historicalAlarmsRecord, currentActiveAlarms }
			STATUS current
			DESCRIPTION 
				"Description."
			::= { eventsAndAlarmsGroup 5 }

		
		-- 1.3.6.1.4.1.99999.1.12
		connectedDevicesGroup OBJECT IDENTIFIER ::= { iotGatewayMIB 12 }

		
		-- 1.3.6.1.4.1.99999.1.12.1
		connectedDevicesTable OBJECT-TYPE
			SYNTAX SEQUENCE OF ConnectedDevicesEntry
			MAX-ACCESS not-accessible
			STATUS current
			DESCRIPTION
				"Table of connected devices information"
			::= { connectedDevicesGroup 1 }

		
		-- 1.3.6.1.4.1.99999.1.12.1.1
		connectedDevicesEntry OBJECT-TYPE
			SYNTAX ConnectedDevicesEntry
			MAX-ACCESS not-accessible
			STATUS current
			DESCRIPTION
				"Connected device entry"
			INDEX { deviceId }
			::= { connectedDevicesTable 1 }

		
		ConnectedDevicesEntry ::=
			SEQUENCE { 
				connectedDevicesCount
					Counter32,
				deviceId
					Integer32,
				deviceStatus
					OCTET STRING,
				networkStats
					OCTET STRING
			 }

		-- 1.3.6.1.4.1.99999.1.12.1.1.1
		connectedDevicesCount OBJECT-TYPE
			SYNTAX Counter32
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Description."
			::= { connectedDevicesEntry 1 }

		
		-- 1.3.6.1.4.1.99999.1.12.1.1.2
		deviceId OBJECT-TYPE
			SYNTAX Integer32 (1..25535)
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Device ID"
			::= { connectedDevicesEntry 2 }

		
		-- 1.3.6.1.4.1.99999.1.12.1.1.3
		deviceStatus OBJECT-TYPE
			SYNTAX OCTET STRING (SIZE (0..255))
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Device status information"
			::= { connectedDevicesEntry 3 }

		
		-- 1.3.6.1.4.1.99999.1.12.1.1.4
		networkStats OBJECT-TYPE
			SYNTAX OCTET STRING
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Description."
			::= { connectedDevicesEntry 4 }

		
		-- 1.3.6.1.4.1.99999.1.12.2
		connDevicesGrouup OBJECT-GROUP
			OBJECTS { connectedDevicesCount, deviceId, deviceStatus, networkStats }
			STATUS current
			DESCRIPTION 
				"Description."
			::= { connectedDevicesGroup 2 }

		
		-- 1.3.6.1.4.1.99999.1.13
		deviceStatusGroup OBJECT IDENTIFIER ::= { iotGatewayMIB 13 }

		
		-- 1.3.6.1.4.1.99999.1.13.1
		deviceStatusTable OBJECT-TYPE
			SYNTAX SEQUENCE OF DeviceStatusEntry
			MAX-ACCESS not-accessible
			STATUS current
			DESCRIPTION
				"Table of device status information"
			::= { deviceStatusGroup 1 }

		
		-- 1.3.6.1.4.1.99999.1.13.1.1
		deviceStatusEntry OBJECT-TYPE
			SYNTAX DeviceStatusEntry
			MAX-ACCESS not-accessible
			STATUS current
			DESCRIPTION
				"Device status entry"
			INDEX { deviceStatusIndex }
			::= { deviceStatusTable 1 }

		
		DeviceStatusEntry ::=
			SEQUENCE { 
				deviceStatusIndex
					Integer32,
				cpuUtilization
					Integer32,
				memoryUtilization
					Integer32,
				storageUtilization
					Integer32,
				statusDescription
					OCTET STRING
			 }

		-- 1.3.6.1.4.1.99999.1.13.1.1.1
		deviceStatusIndex OBJECT-TYPE
			SYNTAX Integer32 (1..100)
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Index for device status entry"
			::= { deviceStatusEntry 1 }

		
		-- 1.3.6.1.4.1.99999.1.13.1.1.2
		cpuUtilization OBJECT-TYPE
			SYNTAX Integer32 (0..100)
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"CPU utilization percentage"
			::= { deviceStatusEntry 2 }

		
		-- 1.3.6.1.4.1.99999.1.13.1.1.3
		memoryUtilization OBJECT-TYPE
			SYNTAX Integer32 (0..100)
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Memory utilization percentage"
			::= { deviceStatusEntry 3 }

		
		-- 1.3.6.1.4.1.99999.1.13.1.1.4
		storageUtilization OBJECT-TYPE
			SYNTAX Integer32 (0..100)
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Storage utilization percentage"
			::= { deviceStatusEntry 4 }

		
		-- 1.3.6.1.4.1.99999.1.13.1.1.6
		statusDescription OBJECT-TYPE
			SYNTAX OCTET STRING (SIZE (0..255))
			MAX-ACCESS read-only
			STATUS current
			DESCRIPTION
				"Description of the device status"
			::= { deviceStatusEntry 6 }

		
		-- 1.3.6.1.4.1.99999.1.13.2
		devStatusGroup OBJECT-GROUP
			OBJECTS { cpuUtilization, memoryUtilization, storageUtilization, statusDescription, deviceStatusIndex
				 }
			STATUS current
			DESCRIPTION 
				"Description."
			::= { deviceStatusGroup 2 }

		
		-- 1.3.6.1.4.1.99999.1.14
		iotGatewayTrapGroup OBJECT IDENTIFIER ::= { iotGatewayMIB 14 }

		
		-- 1.3.6.1.4.1.99999.1.14.1
		iotGatewayTraps OBJECT-IDENTITY
			STATUS current
			DESCRIPTION 
				"Description."
			::= { iotGatewayTrapGroup 1 }

		
		-- 1.3.6.1.4.1.99999.1.14.1.1
		iotGatewayHighCpuUsage NOTIFICATION-TYPE
			OBJECTS { cpuUtilization }
			STATUS current
			DESCRIPTION 
				"This trap is sent when the CPU usage exceeds a predefined threshold."
			::= { iotGatewayTraps 1 }

		
		-- 1.3.6.1.4.1.99999.1.14.3
		iotTrapGroup NOTIFICATION-GROUP
			NOTIFICATIONS { iotGatewayHighCpuUsage }
			STATUS current
			DESCRIPTION 
				"Description."
			::= { iotGatewayTrapGroup 3 }

		
	
	END

--
-- IOTGATEWAY-MIB.my
--

开源项目地址

相关推荐
数字新视界4 小时前
2026模块化机房选型指南:行业市场发展趋势、占有率与竞争梯队分析报告解析
大数据·人工智能·物联网·数据中心·微模块机房·模块化机房·冷通道
Fibocom广和通6 小时前
MiFi选型的轻量化新解:广和通推出超紧凑5G RedCap MiFi PCBA
物联网·5g·redcap·wi-fi 6·mru3a0-cn·mifi
CET中电技术11 小时前
CET中电技术物联网电表电表介绍:从通信协议到电能质量监测的完整选型路径
物联网
CET中电技术11 小时前
预付费电表计费系统是什么?云综能Lite如何重构水电费管理?
人工智能·物联网·重构
jonyleek13 小时前
JVS物模型复用机制:实现硬件设备批量继承的实践方法
物联网·设备管理·设备接入·技术教程·物模型·jvs·批量继承
码上上岸14 小时前
基于stm32的智能荷兰豆生长舱监控系统
stm32·单片机·嵌入式硬件·物联网
serene9415 小时前
功能强大的Modbus从站模拟器使用说明
物联网·上位机·modbus协议·从站仿真器·从站模拟器·modbus开发工具
会周易的程序员15 小时前
告别 matiec 与 Docker:aiDgePLC Editor 全面拥抱 STVM 字节码编译
物联网·网关·electron·软plc·iec61131·stvm·open plc
沐欣工作室_lvyiyi16 小时前
基于物联网的智慧路灯监控系统设计(论文+源码)
单片机·物联网·智能路灯
QYRdata16 小时前
权威数据披露:物联网边缘框架2026-2032年复合增长率达9.2%,增长动能凸显
物联网