42 Lightweight Python CLI Tools for Linux Sysadmins — No Heavy Monitoring Stack Required
As a Linux sysadmin, I got tired of installing heavy monitoring stacks just to answer simple questions:
- What is using all the memory?
- Which services failed?
- Are there zombie processes?
- Is swap pressure hurting performance?
- Are my firewall rules sane?
- Is SSH configured securely?
So I built something different:
42 lightweight, zero-dependency Python CLI tools for Linux system administration,
monitoring, auditing, and troubleshooting.
Every tool is focused on one task.
Every tool installs with a single pip install.
Every tool outputs clean, actionable reports.
No bloated agents. No giant dashboards. No dependency chains.
Just practical tools that work.
Why I Built This
Most monitoring stacks are excellent at scale, but they often feel like overkill when you just want to inspect a server quickly,
audit a system, or troubleshoot a problem from the command line.
I wanted tools that were:
- Lightweight
- Fast to install
- Easy to understand
- Scriptable
- Safe by default
That led to a simple philosophy.
Design Philosophy
1. Zero external dependencies
Everything is built using the Python standard library only.
That means:
- no C extensions
- no long dependency trees
- no extra system packages
- no “works on my machine” surprises
If the machine has Python 3.7+, the tools work.
2. One tool, one job
Instead of building one huge all-in-one package, I split everything into focused utilities.
That makes each package:
- easier to install
- easier to understand
- easier to script
- easier to trust
3. CLI + Python API
Each tool works both from the command line and as a Python import.
So you can use them interactively or integrate them into your own scripts and automation.
4. Audit mode with severity levels
Every tool can flag findings with severity levels like:
criticalwarninginfo
That makes the output immediately useful for audits, CI checks, and operational reviews.
5. JSON output
Need to pipe results into your monitoring stack, SIEM, or custom automation?
No problem.
Every tool supports structured output for machine-readable workflows.
Install Everything at Once
If you want the full collection, install the meta-package:
pip install dargslan-toolkit
Then run:
dargslan
to see all available commands.
The Full Collection
System Monitoring & Performance
dargslan-sysinfo — System Information
Get a complete system overview: CPU, memory, disk, network interfaces, kernel version, and uptime in one command.
pip install dargslan-sysinfo
dargslan-sysinfo report
dargslan-process-monitor — Process Monitor
Find zombie processes, track resource-heavy processes, and get per-process CPU/memory breakdown.
pip install dargslan-process-monitor
dargslan-proc report
dargslan-memory-profiler — Memory Profiler
Per-process RSS analysis, swap usage tracking, memory grouped by application name, and shared memory segment listing.
pip install dargslan-memory-profiler
dargslan-memprof report
dargslan-memprof top -n 20
dargslan-memprof grouped
dargslan-swap-analyzer — Swap Analyzer
Per-process swap usage breakdown, swappiness analysis, and memory pressure detection.
pip install dargslan-swap-analyzer
dargslan-swap report
dargslan-cgroup-monitor — Cgroup Resource Monitor
Monitor CPU, memory, and I/O limits for containers and system slices. Supports cgroups v1 and v2.
pip install dargslan-cgroup-monitor
dargslan-cgroup report
dargslan-cgroup containers
dargslan-disk-benchmark — Disk I/O Benchmark
Measure sequential read/write speed, random IOPS, and write latency with P50/P95/P99 percentiles.
pip install dargslan-disk-benchmark
dargslan-diskbench report -s 100
dargslan-diskbench latency
dargslan-bandwidth-monitor — Bandwidth Monitor
Real-time network interface throughput monitoring with per-interface statistics.
pip install dargslan-bandwidth-monitor
dargslan-bw report
Networking & DNS
dargslan-net-scanner — Network Scanner
Lightweight ping sweep and port scanning without an nmap dependency.
pip install dargslan-net-scanner
dargslan-netscan scan 192.168.1.0/24
dargslan-port-monitor — Port Monitor
Track listening ports, identify exposed services, and detect unexpected listeners.
pip install dargslan-port-monitor
dargslan-port report
dargslan-tcp-monitor — TCP Connection Monitor
Track connection states (ESTABLISHED, TIME_WAIT, CLOSE_WAIT), per-IP statistics, and detect connection abuse.
pip install dargslan-tcp-monitor
dargslan-tcp report
dargslan-tcp states
dargslan-tcp per-ip
dargslan-dns-check — DNS Record Checker
Check A, MX, NS, TXT records and verify DNS propagation across multiple nameservers.
pip install dargslan-dns-check
dargslan-dnscheck check example.com
dargslan-dns-resolver — DNS Resolver Tester
Compare resolver performance (Google, Cloudflare, Quad9), test DNSSEC validation, and diagnose resolution issues.
pip install dargslan-dns-resolver
dargslan-dns compare 8.8.8.8 1.1.1.1 9.9.9.9
dargslan-dns dnssec google.com
dargslan-ip-geo — IP Geolocation
IP geolocation lookup with WHOIS data, reverse DNS, and ISP identification.
pip install dargslan-ip-geo
dargslan-ipgeo lookup 8.8.8.8
Security & Hardening
dargslan-security-scan — Security Scanner
Comprehensive Linux security scan: SSH config, SUID files, kernel parameters, with a numeric security score.
pip install dargslan-security-scan
dargslan-secscan report
dargslan-firewall-audit — Firewall Auditor
Audit iptables and nftables rules for security weaknesses and misconfigurations.
pip install dargslan-firewall-audit
dargslan-fwaudit report
dargslan-iptables-export — Firewall Rule Exporter
Export iptables/nftables rules to readable, JSON, and CSV formats for documentation and compliance.
pip install dargslan-iptables-export
dargslan-iptexp readable -o firewall-rules.txt
dargslan-iptexp csv -o rules.csv
dargslan-ssh-audit — SSH Configuration Auditor
Audit SSH server configuration: cipher suites, key exchange algorithms, and authentication policies.
pip install dargslan-ssh-audit
dargslan-sshaudit report
dargslan-user-audit — User Account Auditor
Find empty passwords, duplicate UIDs, unauthorized sudo access, and inactive accounts.
pip install dargslan-user-audit
dargslan-useraudit report
dargslan-kernel-check — Kernel Parameter Checker
Audit sysctl kernel parameters for security hardening with a security score and recommendations.
pip install dargslan-kernel-check
dargslan-kernelchk report
dargslan-cert-manager — SSL/TLS Certificate Manager
Track certificate expiry across all your servers and local files. Bulk check with alerting thresholds.
pip install dargslan-cert-manager
dargslan-cert check example.com api.example.com
dargslan-cert local
dargslan-ssl-checker — SSL/TLS Checker
Quick SSL certificate expiry and security configuration check for any hostname.
pip install dargslan-ssl-checker
dargslan-sslchk check example.com
dargslan-git-audit — Git Repository Auditor
Scan Git repositories for accidentally committed secrets, API keys, large files, and security leaks.
pip install dargslan-git-audit
dargslan-gitaudit scan /path/to/repo
dargslan-grub-check — GRUB Bootloader Checker
Audit boot entries, installed kernels, UEFI/Secure Boot status, and GRUB password protection.
pip install dargslan-grub-check
dargslan-grub report
dargslan-grub kernels
Services & Configuration
dargslan-service-monitor — Systemd Service Monitor
Track failed systemd units, enabled/disabled services, and service health status.
pip install dargslan-service-monitor
dargslan-svcmon report
dargslan-systemd-timer — Systemd Timer Manager
List, audit, and compare systemd timers with cron jobs.
pip install dargslan-systemd-timer
dargslan-timer report
dargslan-systemd-analyze — Boot Time Analyzer
Find slow services, view the critical boot chain, and optimize Linux startup time.
pip install dargslan-systemd-analyze
dargslan-boottime blame
dargslan-boottime chain
dargslan-cron-audit — Crontab Auditor
Audit crontab entries for security issues, syntax errors, and schedule conflicts.
pip install dargslan-cron-audit
dargslan-cronaudit report
dargslan-nginx-analyzer — Nginx Config Analyzer
Audit Nginx server blocks, SSL configuration, security headers, and reverse proxy settings.
pip install dargslan-nginx-analyzer
dargslan-nginx report
dargslan-apache-analyzer — Apache Config Analyzer
Audit Apache VirtualHosts, SSL settings, module configuration, and security headers.
pip install dargslan-apache-analyzer
dargslan-apache report
Logs & Maintenance
dargslan-log-parser — Log File Parser
Parse and analyze syslog, auth.log, nginx, and Apache access/error logs with pattern matching.
pip install dargslan-log-parser
dargslan-logparse analyze /var/log/syslog
dargslan-log-rotate — Log Rotation Analyzer
Audit logrotate configuration, find large unrotated logs, and check rotation health.
pip install dargslan-log-rotate
dargslan-logrot report
dargslan-journald-analyzer — Journal Log Analyzer
Find boot errors, OOM kills, failed units, and security events in systemd journal.
pip install dargslan-journald-analyzer
dargslan-journal report
dargslan-journal oom
dargslan-journal security
Storage & Filesystems
dargslan-disk-cleaner — Disk Cleaner
Find large files, analyze disk usage by directory, and clean temporary files.
pip install dargslan-disk-cleaner
dargslan-diskclean report
dargslan-backup-monitor — Backup Monitor
Check backup freshness, verify integrity, and monitor backup job status.
pip install dargslan-backup-monitor
dargslan-backup report
dargslan-lvm-check — LVM Volume Checker
Audit PV, VG, LV status, thin pool usage, and snapshot health.
pip install dargslan-lvm-check
dargslan-lvm report
dargslan-lvm thin
dargslan-lvm snapshots
dargslan-nfs-health — NFS Health Checker
Detect stale NFS mounts, measure I/O latency, audit exports, and run throughput tests.
pip install dargslan-nfs-health
dargslan-nfs report
dargslan-nfs throughput -m /mnt/share
Containers & Databases
dargslan-docker-health — Docker Health Checker
Check Docker container health, resource usage, and configuration issues.
pip install dargslan-docker-health
dargslan-docker report
dargslan-container-audit — Container Security Auditor
Audit Docker/Podman containers for privileged mode, root user, excessive capabilities, and security misconfigurations.
pip install dargslan-container-audit
dargslan-contaudit report
dargslan-mysql-health — MySQL/MariaDB Health Checker
Monitor connections, slow queries, replication status, and buffer pool usage.
pip install dargslan-mysql-health
dargslan-mysql report
dargslan-postgres-health — PostgreSQL Health Checker
Monitor connections, table bloat, vacuum status, locks, and replication lag.
pip install dargslan-postgres-health
dargslan-pghealth report
dargslan-redis-health — Redis Health Checker
Monitor memory usage, persistence status, replication health, and slow log.
pip install dargslan-redis-health
dargslan-redis report
dargslan-package-audit — Package Auditor
Find outdated, orphaned, and security-vulnerable packages on Debian/Ubuntu and RHEL/CentOS.
pip install dargslan-package-audit
dargslan-pkgaudit report
The Meta-Package
Don’t want to install tools one by one?
Install everything in a single command:
pip install dargslan-toolkit
This meta-package pulls in the full collection, so you can explore the entire toolkit and keep the commands available
on any Linux box with Python 3.7+.
My Recommendations: Which Tools to Install First
For a Quick Server Health Check
pip install dargslan-sysinfo dargslan-memory-profiler dargslan-disk-cleaner
These three immediately show you CPU, memory, and disk status.
For Security Hardening
pip install dargslan-security-scan dargslan-user-audit dargslan-ssh-audit dargslan-kernel-check
Run these on every new server. The security scanner gives you a numeric score and concrete recommendations.
For Container Environments
pip install dargslan-docker-health dargslan-container-audit dargslan-cgroup-monitor
Essential for Docker and container-heavy Linux environments.
For Web Server Administration
pip install dargslan-nginx-analyzer dargslan-cert-manager dargslan-log-parser
Audit web server config, monitor SSL certificate expiry, and analyze logs.
For Database Administrators
pip install dargslan-postgres-health dargslan-mysql-health dargslan-redis-health dargslan-disk-benchmark
A practical bundle for database health monitoring plus storage benchmarking.
For Network Troubleshooting
pip install dargslan-tcp-monitor dargslan-dns-resolver dargslan-net-scanner dargslan-port-monitor
Track TCP connections, compare DNS resolver performance, and scan your network quickly.
For Compliance & Documentation
pip install dargslan-iptables-export dargslan-git-audit dargslan-grub-check
Export firewall rules, scan repositories for leaked secrets, and audit boot security.
Read-Only by Default
One design choice I care about a lot is safety.
Almost every tool is read-only by default and only inspects system state.
The one notable exception is:
-
dargslan-disk-benchmark— which writes temporary test files for benchmarking
That makes the toolkit practical for production audits, troubleshooting sessions, and scripted checks.
Built for Humans and Automation
These tools are designed for two use cases at the same time:
Human-friendly CLI output
When you're SSH'd into a server at 2 AM, you want readable output that gets to the point.
Machine-friendly structured output
When you're integrating into pipelines, health checks, automation, or monitoring systems, JSON output gives you flexibility.
That means the same tool can be used:
- by a sysadmin on the terminal
- inside a cron job
- in CI/CD
- in compliance workflows
- inside larger monitoring automation
What’s Next
I’m continuing to expand the collection.
Planned additions include:
-
dargslan-k8s-health— Kubernetes cluster health checker -
dargslan-zfs-check— ZFS pool and dataset health monitor -
dargslan-wireguard-audit— WireGuard VPN configuration auditor
If you have ideas for additional Linux admin tools, I’d love to hear them.
Links
-
All tools on PyPI: search for
dargslanon pypi.org -
Meta-package:
dargslan-toolkit - Free cheat sheets: dargslan.com/cheat-sheets
- Linux & DevOps eBooks: dargslan.com/books
- Blog & tutorials: dargslan.com/blog
Final Thoughts
Linux sysadmins do not always need a full monitoring platform.
Sometimes the right answer is a lightweight, zero-dependency CLI tool that does one thing well and gives you a useful report immediately.
That’s exactly why I built this toolkit.
If that sounds useful, start with:
pip install dargslan-toolkit
Or install only the tools that match your workflow.
If you find the project useful, share it with your team.
Top comments (1)
Some comments may only be visible to logged-in visitors. Sign in to view all comments.