"use client" import React, { useState } from "react" import Link from "next/link" import { Network, ArrowLeft, Copy, Check, Terminal } from "lucide-react" import { Button } from "@/components/ui/button" import { Table, TableBody, TableCell, TableHead, TableHeader, TableRow } from "@/components/ui/table" import { Accordion, AccordionContent, AccordionItem, AccordionTrigger } from "@/components/ui/accordion" export default function NetworkCommandsPage() { const [viewMode, setViewMode] = useState<"table" | "accordion">("table") // Group commands by category for better organization const commandGroups = [ { title: "Network Information", commands: [ { command: "ip a", description: "Show network interfaces and IPs" }, { command: "ip r", description: "Show routing table" }, { command: "ip -s link", description: "Show traffic statistics per interface" }, { command: "brctl show", description: "Show configured network bridges" }, { command: "cat /etc/network/interfaces", description: "Show raw network configuration" }, ], }, { title: "Network Testing", commands: [ { command: "ping ", description: "Check connectivity with another host" }, { command: "traceroute ", description: "Trace route to a host" }, { command: "mtr ", description: "Combine ping and traceroute in real-time" }, { command: "dig ", description: "DNS lookup for a domain" }, { command: "nslookup ", description: "Alternative DNS lookup" }, ], }, { title: "Network Configuration", commands: [ { command: "ifreload -a", description: "Reload network configuration (ifupdown2)" }, { command: "ethtool ", description: "Show Ethernet device info" }, { command: "resolvectl status", description: "Show DNS resolution status" }, { command: "nmcli device show", description: "Show network device details (if NetworkManager is used)" }, { command: "ip link set up", description: "Bring network interface up" }, { command: "ip link set down", description: "Bring network interface down" }, ], }, { title: "Network Monitoring", commands: [ { command: "ss -tuln", description: "Show listening ports (TCP/UDP)" }, { command: "netstat -tuln", description: "Alternative to show listening ports" }, { command: "lsof -i", description: "List open network files and connections" }, { command: "tcpdump -i ", description: "Capture packets on interface" }, { command: "iftop -i ", description: "Monitor bandwidth usage on interface" }, ], }, { title: "Firewall Management", commands: [ { command: "iptables -L -n -v", description: "Show active firewall rules (iptables)" }, { command: "nft list ruleset", description: "Show nftables rules" }, { command: "pve-firewall status", description: "Check Proxmox firewall status" }, { command: "pve-firewall compile", description: "Compile firewall rules for all nodes" }, { command: "pve-firewall reload", description: "Reload Proxmox firewall rules" }, ], }, ] return (
Back to Help and Info

Network Commands

This section provides commands for configuring, monitoring, and troubleshooting network connections in Proxmox VE. Learn how to view network interfaces, test connectivity, configure network settings, and manage firewall rules.

{viewMode === "table" ? (
{commandGroups.map((group, index) => (

{group.title}

Command Description Action {group.commands.map((cmd, cmdIndex) => ( {cmd.command} {cmd.description} ))}
))}
) : (
{commandGroups.map((group, index) => (

{group.title}

{group.commands.map((cmd, cmdIndex) => (
{cmd.command}
{cmd.command}

{cmd.description}

))}
))}
)}

Usage Tips

  • Replace <host> with an IP address or hostname
  • Replace <iface> with your network interface name (e.g., eth0, vmbr0)
  • Replace <domain> with a domain name for DNS lookups
  • Use ip a to find the names of your network interfaces
  • For more detailed packet capture with tcpdump, add filters like{" "} tcpdump -i eth0 port 80 -n to capture HTTP traffic
) } interface CopyButtonProps { text: string } function CopyButton({ text }: CopyButtonProps) { const [copied, setCopied] = React.useState(false) const copyToClipboard = () => { navigator.clipboard.writeText(text) setCopied(true) setTimeout(() => setCopied(false), 2000) } return ( ) }