Skip to content

Linux route Guide

Mattscreative edited this page Dec 5, 2025 · 2 revisions

Linux route Guide

Complete beginner-friendly guide to route on Linux, covering Arch Linux, CachyOS, and other distributions including routing table management, static routes, and network routing.


Table of Contents

  1. Understanding route
  2. route Basics
  3. Viewing Routes
  4. Adding Routes
  5. Troubleshooting

Understanding route

What is route?

route manages routing table.

Uses:

  • View routes: Show routing table
  • Add routes: Add static routes
  • Delete routes: Remove routes
  • Network routing: Manage network routing

Note: Modern alternative is ip route.


route Basics

View Routes

Basic usage:

# View routing table
route -n

# -n = numeric (no hostname resolution)

Kernel Table

Kernel routes:

# Kernel routing table
route

# Shows routing table

Viewing Routes

Numeric Output

No resolution:

# Numeric addresses
route -n

# Faster (no DNS lookup)

Specific Interface

Interface routes:

# Routes for interface
route -n | grep eth0

# Shows routes for eth0

Adding Routes

Add Route

Add static route:

# Add route
sudo route add -net 192.168.2.0/24 gw 192.168.1.1

# Adds route to network

Delete Route

Remove route:

# Delete route
sudo route del -net 192.168.2.0/24

# Removes route

Troubleshooting

route Not Found

Check installation:

# Check route
which route

# Usually in net-tools
# Install if missing
sudo pacman -S net-tools

Summary

This guide covered route usage, routing table management, and network routing for Arch Linux, CachyOS, and other distributions.


Next Steps


This guide covers Arch Linux, CachyOS, and other Linux distributions. For distribution-specific details, refer to your distribution's documentation.

Clone this wiki locally