How7o
  • Home
  • Tools
  • Prank Screens
  • Learn
  • Blog
  • Contact
Reading: How to List Network Devices on Linux
Share
How7oHow7o
Font ResizerAa
  • OS
Search
  • Home
  • Tools
  • Prank Screens
  • Learn
  • Blog
  • Contact
Follow US
© 2024–2026 How7o. All rights reserved.
How7o > Free Laravel, PHP, WordPress & Server Tutorials > Server Management > How to List Network Devices on Linux
Server Management

How to List Network Devices on Linux

how7o
By how7o
Last updated: May 22, 2026
5 Min Read
List network devices on Linux — ip a and nmcli output side by side
SHARE

To list network devices on Linux, the fastest way is ip a (shows every interface with its addresses and link state) or nmcli dev status (shows NetworkManager-managed connection state). Both work on AlmaLinux, Rocky, RHEL, Debian, Ubuntu, Arch — anywhere with a modern kernel and iproute2 installed.

Contents
  • TL;DR
  • Using ip
  • Using nmcli
  • Just the names
  • Frequently asked questions
  • Related guides
  • References

Last verified: 2026-05-17 on AlmaLinux 9, Ubuntu 22.04, and Fedora 40. Originally published 2022-08-29, rewritten and updated 2026-05-17.

TL;DR

# Every interface, addresses, link state
ip a

# Compact one-line-per-interface view
ip -br link

# NetworkManager view (only on systems with NM installed)
nmcli dev status

# Default-route interface
ip route show default

Using ip

ip a (short for ip address show) is the modern, official command — part of the iproute2 package that every Linux distro ships in the default install:

ip a

Sample output:

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 ...
    inet 127.0.0.1/8 scope host lo
2: enp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 ...
    link/ether 52:54:00:12:34:56 brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.42/24 brd 192.168.1.255 scope global enp3s0

For a more compact view, pass -br (brief):

ip -br link

# lo               UNKNOWN        00:00:00:00:00:00
# enp3s0           UP             52:54:00:12:34:56
# wlp2s0           DOWN           a0:88:b4:11:22:33
List network devices on Linux — ip a, ip -br link, nmcli dev status side by side

Using nmcli

On any system with NetworkManager installed (most desktops, many servers), nmcli dev status gives a higher-level view:

nmcli dev status

# DEVICE   TYPE      STATE        CONNECTION
# enp3s0   ethernet  connected    Wired connection 1
# wlp2s0   wifi      disconnected --
# lo       loopback  unmanaged    --

The advantage over ip a: nmcli knows which connection profile is active, which Wi-Fi network you’re on, and whether NetworkManager is managing the device at all. If you get Error: NetworkManager is not running, your system doesn’t have NetworkManager — that’s fine, just use ip.

Just the names

If a script just needs the list of interface names, the kernel exposes them as directories under /sys/class/net/:

ls /sys/class/net/

# enp3s0  lo  wlp2s0

This is the cleanest, dependency-free way to enumerate interfaces — useful inside containers, minimal Alpine images, or anywhere ip might not be installed.

Frequently asked questions

What’s the difference between ip a and ifconfig?

ip a is part of the iproute2 suite and is the official replacement for the deprecated net-tools commands (ifconfig, route, arp). It shows the same information plus IPv6, multiple addresses per interface, and link-state details. Most distros stopped installing ifconfig by default years ago. Always use ip on modern systems.

What does nmcli dev status show that ip a doesn’t?

nmcli queries NetworkManager, so its output reflects the connection profile (Wi-Fi network names, VPN status, bond/bridge members, whether a device is managed by NetworkManager at all). ip a just shows the kernel-level interface state. On servers without NetworkManager you’ll get an error from nmcli — that’s not a bug, just a sign NetworkManager isn’t installed.

How do I see only physical (not virtual) interfaces?

Filter on the link/ether line. ip -br link gives a compact one-line-per-interface view; pipe to grep -v ' DOWN\|lo' to drop loopback and inactive ones. Or use ls /sys/class/net/ to see every kernel-recognized interface as a directory.

Why does my interface have a weird name like enp0s3 instead of eth0?

That’s predictable network interface names, introduced with systemd. The prefix en = ethernet, p0 = PCI bus 0, s3 = slot 3. The names stay stable across reboots and kernel upgrades, which the old eth0/eth1 scheme didn’t guarantee. To revert to the old naming, add net.ifnames=0 to your kernel command line, but stable names are the better default.

How do I find which interface is the default route?

ip route show default prints the default gateway and the device used to reach it: default via 192.168.1.1 dev enp3s0. That’s the interface your internet traffic leaves through.

Related guides

  • How to Install Docker on AlmaLinux
  • How to Update Ubuntu to the Latest Kernel
  • Change the SSH Welcome Message on an Ubuntu VPS

References

iproute2 reference (ip command): man ip. NetworkManager CLI reference: networkmanager.dev/docs/api/latest/nmcli.html.

TAGGED:Bashconfigurationtroubleshooting

Sign Up For Daily Newsletter

Be keep up! Get the latest breaking news delivered straight to your inbox.
[mc4wp_form]
By signing up, you agree to our Terms of Use and acknowledge the data practices in our Privacy Policy. You may unsubscribe at any time.
Share This Article
Facebook Copy Link Print
Previous Article Nginx 502 with recv() failed 104 connection reset — PHP-FPM timeout and memory tuning Fix Nginx ‘recv() failed (104: Connection reset by peer)’ with FastCGI
Next Article JavaScript check Unicode character — regex, codePointAt, Unicode property escape How to Check if a JavaScript String Contains a Unicode Character
Leave a Comment

Leave a Reply Cancel reply

You must be logged in to post a comment.

FacebookLike
XFollow
PinterestPin
InstagramFollow
Most Popular
Run Laravel queue workers with Supervisor
How to Run Laravel Queue Workers in Production with Supervisor
May 23, 2026
Nginx as a reverse proxy for a Node.js app on Ubuntu
How to Set Up Nginx as a Reverse Proxy for Node.js on Ubuntu
May 23, 2026
Install and configure Redis on Ubuntu for Laravel and WordPress
How to Install and Configure Redis on Ubuntu (for Laravel & WordPress)
May 23, 2026
Harden a fresh Ubuntu VPS with UFW, Fail2Ban, and SSH key auth
How to Harden a Fresh Ubuntu VPS: UFW + Fail2Ban + SSH Key Auth
May 23, 2026
Set up Let's Encrypt SSL with Certbot on Ubuntu
How to Set Up Let’s Encrypt SSL with Certbot on Ubuntu (Apache & Nginx)
May 23, 2026

You Might Also Like

Fix broken cPanel disk quotas with the fixquotas script
Server Management

How to Fix Quotas in cPanel

5 Min Read
MariaDB not starting — six-step triage from logs to stale PID
Server Management

How to Troubleshoot MariaDB Not Starting

8 Min Read
Fix missing PHP Authorization header on Apache and cPanel
Server Management

How to Fix Missing Authorization Header in PHP Requests

5 Min Read
Install the Apache web server on Ubuntu
Server Management

How to Install the Apache Web Server on Ubuntu

7 Min Read
How7o

We provide tips, tricks, and advice for improving websites and doing better search.

Tools

  • Age Calculator
  • Word Counter
  • Image Upscaler
  • Password Generator
  • QR Code Generator
  • See all tools→

Pranks

  • Fake Blue Screen Prank
  • Hacker Typer
  • Fake iMessage Generator
  • Windows XP Crash Prank
  • Windows 11 Update Prank
  • See all prank screens →

Company

  • About Us
  • Blog
  • Contact
  • Privacy Policy
  • Terms of Service
  • Sitemap
© 2024–2026 How7o. All rights reserved.
Welcome Back!

Sign in to your account

Username or Email Address
Password

Lost your password?