--- a/agent/snmp_agent.c	2025-02-21 15:09:04.525454927 +0800
+++ b/agent/snmp_agent.c	2025-02-21 15:09:41.491072065 +0800
@@ -3582,10 +3582,24 @@ netsnmp_timeval_uptime(struct timeval *
 u_long
 netsnmp_get_agent_uptime(void)
 {
-    struct timeval  now;
-    gettimeofday(&now, NULL);
+    u_long res = 0L;
+    FILE *fp = fopen("/proc/uptime","r");
+    
+    if(fp == NULL)
+    {
+        snmp_log(LOG_ERR,"open /proc/uptime failed");
+        return res;
+    }
+    double uptime;
+    if(fscanf(fp,"%lf",&uptime) != 1)
+    {
+        snmp_log(LOG_ERR, "read /proc/uptime failed");
+        fclose(fp);
+        return res;
+    }
+    fclose(fp);
 
-    return netsnmp_timeval_uptime(&now);
+    return (u_long)(uptime * 100);
 }
 
 
