The sysctl() system call can get or set the state of the system, the FreeBSD kernel exposes the parameters for sysctl() as objects of a Management information Base (MIB).
sysctltui is a Text User Interface sysctl MIB explorer. It allow to view a parameter's properties and get or set its value. The first version 0.0.1 is out.
Getting Started
# pkg install sysctlmibinfo2 bsddialog % git clone https://gitlab.com/alfix/sysctltui.git % cd sysctltui % make % ./sysctltui
The utility provides three windows: a main one with the tree, one to view information about the parameter, and one to set a new value.
Main Window:
Parameter Properties:
Set Value:
Usage
% ./sysctltui -h usage: sysctltui [-h|v] sysctltui [-d|V] [-f] [-e <label>] [-l <label>] [-i <indent>] [-s <label>] -d Show parameter descriptions in the main window. -e <label> Set prefix for nodes with expandable subtree. -f Display full parameter names in the main window. -h Show this help message and exit. -i <indent> Set the visual depth of subtrees. -l <label> Set prefix for leaf nodes. -s <label> Set prefix for nodes with expanded subtrees. -V Display parameter values in the main window. -v Show version and exit.
Tip, layout similar to sysctl or sysutils/nsysctl:
[n]sysctl | sysctltui |
---|---|
% [n]sysctl -a | % sysctltui -fV -i 0 |
% [n]sysctl -an | % sysctltui -f -i 0 |
% [n]sysctl -ad | % sysctltui -fd -i 0 |
sysctltui is still in its early stages; it is currently at version 0.0.1. It provides some functionality similar to nsysctl and sysctlview, but many features still need to be implemented.
TODO list:
- Add: [View] menu: Rebuild Tree, Expande Tree, Collapse Tree, Show desc, Show Value, Clear screen.
- Add: kelvin format.
- Add: Opaque(s).
- Improve: sort children.
- Add: /etc/sysctl.conf and /boot/loader.conf.
Suggestions, feedback, and new ideas are welcome.
Top comments (0)