etop(3)

πŸ“¦
version 29.0.6 Β· 2 versions
, in nixos 26.05, nixpkgs unstable, ubuntu stonking

✨ etop πŸ’…

okay bestie, so this is etop β€” it's the Erlang module definition situation, and honestly it's giving iconic. buckle up πŸŽ€


🌸 NAME 🌸

etop β€” Erlang Top is a tool for presenting information about Erlang processes, and it's basically the same vibe as what "top" shows you in UNIX. same energy, different node πŸ¦‹


🫢 DESCRIPTION 🫢

You start Erlang Top with the provided scripts etop. That kicks off a hidden Erlang node that connects to the node you actually wanna measure. The node getting measured is specified with option -node. 🎯

Now listen β€” if the measured node has a different cookie than the default cookie for whoever's invoking the script, you gotta spell the cookie out explicitly with option -setcookie. no cookie, no connection, iykyk 😭

Under Windows, the batch file etop.bat can be used. Windows girlies, we see you 🫢

When you run the etop script, you can pass config parameters as command-line options, like:

etop -node testnode@myhost -setcookie MyCookie

The following configuration parameters exist for the tool πŸ‘‡

  • node β€” the measured node.
    • Value: atom/0
    • Mandatory ⚠️ (not optional, bestie, you NEED it)
  • setcookie β€” cookie to use for the etop node. Must be same as the cookie on the measured node. πŸͺ
    • Value: atom/0
  • lines β€” number of lines (processes) to display.
    • Value: integer/0
    • Default: 10
  • interval β€” time interval (in seconds) between each update of the display. ⏰
    • Value: integer/0
    • Default: 5
  • accumulate β€” if true, the execution time and reductions are accumulated.
    • Value: boolean/0
    • Default: false
  • sort β€” identifies what information to sort by. πŸ”€
    • Value: runtime | reductions | memory | msg_q
    • Default: runtime (reductions if tracing=off)
  • tracing β€” etop uses the Erlang trace facility, and thus no other tracing is possible on the measured node while etop is running, unless this option is set to off. Also helpful if the etop tracing causes too high load on the measured node. With tracing off, runtime is not measured. πŸ’€
    • Value: on | off
    • Default: on

For details about Erlang Top, see the User's Guide. πŸ“–


πŸ”₯ FUNCTIONS πŸ”₯

  • config(Key, Value) -> ok | {error, Reason}
when
    Key :: lines | interval | accumulate | sort,
    Value :: term(),
    Reason :: term().

Changes the configuration parameters of the tool during runtime, mid-session, no restart needed. The allowed parameters are lines, interval, accumulate, and sort. glow-up your display on the fly ✨

  • dump(File) -> ok | {error, Reason}
when File :: file:filename_all(), Reason :: term().

Dumps the current display to a text file. screenshot but for text, periodt πŸ“Έ

  • help() -> ok.

Displays the help of etop and its options. when you're lost, just ask πŸ₯Ί

  • start() -> ok.

Starts etop. Notice that etop is preferably started with the etop script. like yes you can do it this way but the script is the main character πŸ‘‘

  • start(Options) -> ok
when
    Options :: [{Key, Value}],
    Key :: atom(),
    Value :: term().

Starts etop. To view the possible options, use help/0. 🧚

  • stop() -> stop | not_started.

Terminates etop. bye bestie πŸ’œ


ngl, remember that whole tracing caveat β€” no other tracing on the measured node while etop is running unless you set it to off, and with tracing off you literally don't get runtime measured. fr fr, no cap. ⚠️

okay and that's the whole page, mwah πŸ’‹ this was written by Ericsson AB and it's from observer 2.19 β€” etop(3), slay, go forth and measure ur processes πŸ¦‹πŸ’–

πŸ“¦ where this page comes from