In the Linux ecosystem, network management is a critical task that ensures seamless connectivity to wired, wireless, and virtual networks. Two popular tools for this purpose are NMCLI (NetworkManager Command-Line Interface) and WICD (Wireless Interface Connection Daemon). While both aim to simplify network configuration, they differ significantly in design, features, and use cases. NMCLI is the command-line front-end for NetworkManager, a robust, modern network management suite preinstalled on most mainstream Linux distributions (e.g., Ubuntu, Fedora, Debian). It excels at handling dynamic networks, VPNs, mobile broadband, and complex setups. WICD, by contrast, is a lightweight, older tool designed for simplicity and minimal resource usage. It was once a favorite for lightweight desktops (e.g., LXDE, Xfce) and older hardware but has seen reduced development in recent years. This blog compares NMCLI and WICD across fundamentals, usage, best practices, and scenarios to help you choose the right tool for your needs.
Table of Contents
- Fundamental Concepts
- Installation
- Usage Methods
- Common Practices
- Best Practices
- Feature Comparison Table
- Conclusion
- References
Fundamental Concepts
What is NetworkManager (NMCLI)?
NetworkManager is a daemon that manages network interfaces and connections dynamically. It replaces traditional static configuration tools (e.g., /etc/network/interfaces) with a unified system that auto-detects and configures networks. NMCLI is its command-line interface, enabling scriptable, headless network management.
Key Features:
- Supports WiFi (802.11), Ethernet, VPN (OpenVPN, WireGuard), mobile broadband (4G/5G), and bonds/bridges.
- Integrates with systemd, Polkit (for permissions), and desktop environments (via GUI tools like
nm-applet). - Persistent connection profiles (stored in
/etc/NetworkManager/system-connections/). - Active development and broad distro support.
What is WICD?
WICD (Wireless Interface Connection Daemon) is a lightweight alternative to NetworkManager, focused on simplicity and minimalism. It was created to address perceived bloat in early NetworkManager versions but has since fallen out of mainstream use due to limited updates.
Key Features:
- Supports WiFi and Ethernet (basic VPN support via plugins).
- Lightweight: Uses fewer system resources (RAM/CPU) than NetworkManager.
- Curses-based GUI (
wicd-curses) and CLI (wicd-cli) for configuration. - Minimal dependencies (no systemd hard dependency).
Installation
Installing NMCLI/NetworkManager
NMCLI is part of the networkmanager package, preinstalled on most modern Linux distributions. To ensure it’s installed:
Debian/Ubuntu:
sudo apt update && sudo apt install network-manager
Fedora/RHEL:
sudo dnf install NetworkManager
Arch Linux:
sudo pacman -S networkmanager
Start and enable the service:
sudo systemctl enable --now NetworkManager
Installing WICD
WICD is less common today, but available in some distro repositories. Note: It may conflict with NetworkManager, so disable NetworkManager first:
sudo systemctl disable --now NetworkManager
Debian/Ubuntu (older versions or via PPA):
sudo apt install wicd wicd-curses # May require third-party PPAs on newer Ubuntu
Fedora (unofficial repos):
WICD is not in official Fedora repos. Use COPR or compile from source.
Arch Linux (AUR):
yay -S wicd # Or use another AUR helper
Start WICD:
sudo systemctl enable --now wicd
Usage Methods
NMCLI: Common Commands and Workflows
NMCLI is powerful for scripting and headless management. Below are key workflows:
1. Check Network Status
View overall network status and device connectivity:
nmcli general status # Shows NetworkManager state, hostname, etc.
nmcli device status # Lists devices (e.g., wlan0, eth0) and their status
2. List and Connect to WiFi Networks
Scan for nearby WiFi networks and connect to one:
nmcli device wifi list # Scan for WiFi (add --rescan yes to refresh)
nmcli device wifi connect "MySSID" password "MyPassword" # Connect to a network
To connect to a hidden SSID:
nmcli device wifi connect "HiddenSSID" password "MyPassword" hidden yes
3. Manage Connection Profiles
NetworkManager uses “connection profiles” to store settings (e.g., IP, DNS). List, modify, or delete profiles:
nmcli connection show # List all saved profiles
nmcli connection show "MySSID" # Show details of a specific profile
nmcli connection modify "MySSID" ipv4.dns "8.8.8.8,8.8.4.4" # Set custom DNS
nmcli connection delete "OldSSID" # Delete a profile
4. Configure Ethernet
Connect to a wired network (usually auto-detected, but manual setup if needed):
nmcli connection add type ethernet con-name "Wired" ifname eth0 # Create profile
nmcli connection up "Wired" # Activate the profile
5. Manage VPNs
With plugins like network-manager-openvpn, NMCLI handles VPNs:
nmcli connection import type openvpn file /path/to/vpn.ovpn # Import VPN profile
nmcli connection up "MyVPN" # Connect to VPN
WICD: CLI and Curses Interface
WICD prioritizes simplicity, with a user-friendly curses interface and basic CLI.
1. Curses Interface (Recommended for Beginners)
Launch the interactive curses GUI:
wicd-curses
Workflow:
- Use arrow keys to navigate.
- Press
Rto rescan for networks. - Select a network and press
Enterto configure. - Enter the password (for WiFi) and press
F10to connect. - Use
Cto configure advanced settings (e.g., static IP).
2. CLI Commands
List available networks:
wicd-cli -l # Shows SSID, signal strength, encryption
Connect to a network (replace N with the network index from -l):
wicd-cli -c -n N # -c = connect, -n = network index
Disconnect:
wicd-cli -d
Common Practices
When to Use NMCLI/NetworkManager
- Dynamic Networks: Laptops or devices switching between WiFi, Ethernet, and mobile broadband.
- Complex Setups: VPNs, bonds, bridges, or VLANs.
- Headless Systems: Servers or Raspberry Pi-like devices managed via SSH.
- Modern Distros: Ubuntu, Fedora, or Debian (where NetworkManager is preinstalled and supported).
When to Use WICD
- Older Hardware: Low-spec systems (e.g., 256MB RAM) where resource usage matters.
- Lightweight Desktops: LXDE, Fluxbox, or Xfce with minimal overhead.
- Simplicity: Users preferring a no-frills interface over advanced features.
- Legacy Systems: Older Linux distributions where NetworkManager is buggy or unavailable.
Best Practices
For NMCLI/NetworkManager
- Use Connection Profiles: Avoid editing
/etc/network/interfacesor/etc/systemd/network/files directly—let NetworkManager manage profiles. - Secure Passwords: Never hardcode WiFi/VPN passwords in scripts. Use
nmcli’s interactive mode or store credentials in encrypted keyrings. - Troubleshoot with Logs: Check
journalctl -u NetworkManagerfor connection issues. - Disable When Unneeded: On servers with static IPs, disable NetworkManager and use
systemd-networkdfor simplicity.
For WICD
- Avoid Conflicts: Ensure NetworkManager,
systemd-networkd, ordhcpcdare disabled to prevent overlapping network control. - Backup Configs: WICD stores settings in
/etc/wicd/—back up this directory before reconfiguring. - Limit to Basic Use Cases: Avoid WICD for VPNs or modern WiFi standards (e.g., WPA3); it lacks up-to-date support.
- Monitor for Bugs: Since WICD is rarely updated, test on a non-critical system first.
Feature Comparison Table
| Feature | NMCLI/NetworkManager | WICD |
|---|---|---|
| Supported Networks | WiFi (WPA3), Ethernet, VPN, mobile broadband, bonds | WiFi (WPA2), Ethernet (basic VPN via plugins) |
| Resource Usage | Moderate (≈10-20MB RAM) | Light (≈2-5MB RAM) |
| Interfaces | CLI (nmcli), GUI (nm-applet), TUI (nmtui) | CLI (wicd-cli), TUI (wicd-curses) |
| Active Development | Yes (regular updates) | No (last stable release: 2016) |
| Distro Support | Preinstalled on most mainstream distros | Limited (AUR, old repos, PPAs) |
| Scripting | Powerful (JSON output, profile management) | Basic (limited CLI options) |
| Security | WPA3, MAC randomization, encrypted keyrings | WPA2 (no WPA3), plaintext password storage |
Conclusion
NMCLI/NetworkManager is the clear choice for most modern Linux users. It offers robust features, active development, and seamless integration with mainstream distributions, making it ideal for dynamic, complex, or headless environments.
WICD, while lightweight, is best reserved for legacy hardware or users prioritizing minimalism over features. Its lack of updates and limited support for modern standards (e.g., WPA3) make it unsuitable for most production use cases.
Ultimately, choose NMCLI for flexibility and modernity, and WICD only if you have specific constraints like very low system resources.