Skip to content

Latest commit

 

History

History
92 lines (68 loc) · 3.38 KB

nf-snmp-snmpsvcgetuptime.md

File metadata and controls

92 lines (68 loc) · 3.38 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NF:snmp.SnmpSvcGetUptime
SnmpSvcGetUptime function (snmp.h)
The SnmpSvcGetUptime function retrieves the number of centiseconds that the SNMP service has been running. This function is an element of the SNMP Utility API.
SnmpSvcGetUptime
SnmpSvcGetUptime function [SNMP]
_snmp_snmpsvcgetuptime
snmp.snmpsvcgetuptime
snmp/SnmpSvcGetUptime
snmp\snmpsvcgetuptime.htm
SNMP
46702e39-3ea2-471c-9281-3cd7dcae9c9c
12/05/2018
SnmpSvcGetUptime, SnmpSvcGetUptime function [SNMP], _snmp_snmpsvcgetuptime, snmp.snmpsvcgetuptime, snmp/SnmpSvcGetUptime
snmp.h
Windows
Windows 2000 Professional [desktop apps only]
Windows 2000 Server [desktop apps only]
Snmpapi.lib
Snmpapi.dll
Windows
19H1
SnmpSvcGetUptime
snmp/SnmpSvcGetUptime
c++
APIRef
kbSyntax
DllExport
Snmpapi.dll
SnmpSvcGetUptime

SnmpSvcGetUptime function

-description

[SNMP is available for use in the operating systems specified in the Requirements section. It may be altered or unavailable in subsequent versions. Instead, use Windows Remote Management, which is the Microsoft implementation of WS-Man.]

The SnmpSvcGetUptime function retrieves the number of centiseconds that the SNMP service has been running. This function is an element of the SNMP Utility API.

-returns

The function returns a DWORD value that is the number of centiseconds the SNMP service has been running.

-remarks

An extension agent should call the SnmpSvcGetUptime function only if the extension agent DLL is loaded within the address space of the SNMP service.

The SNMP extension agent DLL is encouraged to use the SnmpSvcGetUptime function to retrieve the number of centiseconds that the SNMP service has been running. Extension agents should use SnmpSvcGetUptime rather than calculate the uptime using the dwUptimeReference parameter. The service passes this parameter to the extension agent as the result of a call to the SnmpExtensionInit function. Because the dwUptimeReference parameter stores the elapsed time as a DWORD value in milliseconds, the time can wrap to zero and reflect an inaccurate time interval.

An extension agent that sends traps must initialize the timeStamp parameter to the SnmpExtensionTrap function with the value returned by a call to the SnmpSvcGetUptime function.

-see-also

SNMP Functions

Simple Network Management Protocol (SNMP) Overview

SnmpExtensionInit

SnmpExtensionTrap