SNMPPS(1)

πŸ’– SNMPPS(1) β€” the Net-SNMP glow-up πŸ’–

okay bestie, sit down, hydrate, because we're about to look at the process table of a whole other machine and it's giving remote ps energy. this is the snmpps page from Net-SNMP, and yes, there's a snmptop situation too. iykyk.


✨ NAME ✨

snmpps β€” display process table on a network entity via SNMP


🌸 SYNOPSIS 🌸

snmpps [COMMON OPTIONS] [-Cp] [-Ca] [-C n | m | t ] AGENT

snmptop [COMMON OPTIONS] [-Cp] [-Ca] [-C n | m | t ] AGENT

πŸ¦‹ DESCRIPTION πŸ¦‹

so snmpps is literally just a networked version of a simple ps command. no cap. it peeks at the processes on the remote machine by examining the HOST-RESOURCES-MIB's hrSWRunTable and the hrSWRunPerfTable. that's the whole vibe.

AGENT identifies a target SNMP agent, which is instrumented to monitor the given objects. at its simplest, the AGENT specification will consist of a hostname or an IPv4 address. in this situation, the command will attempt communication with the agent, using UDP/IPv4 to port 161 of the given target host. 🫢 if you want the full list of the possible formats for AGENT, go read the snmpcmd(1) manual page. it's all in there, fr fr.

snmptop emulates the top command using SNMP. the way that it works while running is: the keyboard inputs of 'c', 'n', 'm', 't' switch sorting between cpu, pid, memory, or total runtime. typing 'i' toggles hiding idle processes, while 'o' toggles hiding Os processes. typing 'a' toggles display of hrSWRunParameters, 'p' toggles display of hrSWRunPath. interactive icon behavior, honestly. πŸ’…


✨ OPTIONS ✨

🌈 COMMON OPTIONS

bestie please go see snmpcmd(1) for a list of possible values for COMMON OPTIONS as well as their descriptions. i'm not gonna reinvent that wheel, that's a whole other page. πŸŽ€

πŸ’œ the -C girlies

  • -Cp β€” Show hrSWRunPath in addition to hrSWRunName
  • -Ca β€” Show hrSWRunParameters in addition to hrSWRunName
  • -Ct β€” Sort display by total CPU usage
  • -Cm β€” Sort display by memory usage
  • -Cn β€” Sort display numeric by PID

⭐ EXAMPLES ⭐

the moment you've all been waiting for, the demo run:

% snmpps -v 2c -c public localhost

Index Type Status     Memory         CPU Command
    1 Appl   Wait     1.00MB        1.29 init
  554 Appl   Wait   364.00kB        0.03 udevd
 1813 Appl    Run     6.73MB        0.41 snmpd
 1833 Appl   Wait     1.27MB        3.49 rsyslogd
 1871 Appl   Wait   496.00kB       47.92 irqbalance
 1890 Appl   Wait   648.00kB        0.62 rpcbind
 2121 Appl   Wait     1.89MB        0.00 bash
 2150 Appl   Wait     3.49MB        0.16 vim
 2185 Appl   Wait   556.00kB        0.00 sleep

look at that table. the columns. the alignment. the irqbalance at 47.92 CPU being the absolute main character of this machine. obsessed. πŸ”₯


πŸŽ€ SEE ALSO πŸŽ€


lowkey reminder that everything literal here β€” the option names, the file names, the MIB tables, the keyboard keys β€” is exact, so copy it character for character and you'll be fine. πŸ™ˆ

and that's the page, bestie. this was snmpps from Net-SNMP, version V5.9.5.2, dated 04 Nov 2013 β€” an absolute vintage icon, and yes she still slays. go run her on your localhost and tell me what bash is doing. bye ily πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from