Lewati ke isi

CLI operasional

Prompt user@host>. Kata kunci boleh disingkat selama tidak ambigu (sh int, sh conf | disp set).

show

Perintah Fungsi
show interfaces Port dan interface logis (unit, irb, lo0): state admin/link, MTU, alamat, description
show vlans VLAN, vlan-id, irb, port access dan trunk
show interfaces counters Counter VPP per interface
show ip route / show ipv6 route Tabel routing FRR
show ip fib / show ipv6 fib Tabel forwarding di dalam VPP
show nat sessions Sesi NAT44 aktif
show nat interfaces Interface NAT dan alamat pool
show dataplane Driver, pembagian CPU, buffer, port
show dataplane load Paket yang di-routing per worker sejak clear
show dataplane queues Cara pembagian koneksi per port, dan antrean per worker
show configuration [path] Running config (format blok), seluruhnya atau satu bagian
show configuration [path] \| display set Running config sebagai perintah set
show history Riwayat commit
show version [detail] Hardware, uptime, dan versi semua software
show system Uptime, memori, hugepages
show system users User yang sedang login
show log Log service router (60 baris terakhir)
show vpp <perintah> Perintah show VPP apa pun, misalnya show vpp errors

Lainnya

Perintah Fungsi Kelas minimum
ping <host> [count N] [source IP] [size N] [interface IF] Ping; selalu berhenti setelah count + 4 detik operator
traceroute <host> Traceroute operator
monitor interface traffic [count N] Throughput live; Ctrl+C untuk berhenti read-only
clear dataplane statistics Nolkan counter worker dan interface operator
clear interfaces statistics Nolkan counter interface operator
restart dataplane Restart VPP (dengan konfirmasi) operator
configure Masuk mode konfigurasi super-user
start shell [user root] Shell Linux super-user
vppctl <perintah> Perintah VPP mentah super-user
reboot / poweroff Dengan konfirmasi super-user
exit Keluar semua

Pipe

Filter Fungsi
\| display set Konfigurasi sebagai perintah set (hanya untuk show configuration, atau show di mode konfigurasi)
\| compare [rollback N] Beda konfigurasi per blok [edit …]. Di mode konfigurasi: candidate vs running; show configuration \| compare rollback N: running vs commit ke-N
\| match <regex> Hanya baris yang cocok
\| except <regex> Sembunyikan baris yang cocok
\| count Jumlah baris
\| no-more Tanpa paging (diterima untuk kompatibilitas)
admin@r1> show configuration interfaces | display set
admin@r1> show configuration | display set | match "eth1|eth2"
admin@r1> show interfaces | except lo0
admin@r1> show configuration | display set | count
admin@r1> show configuration | compare rollback 1    # apa yang diubah commit terakhir
  • Filter bisa disambung.
  • | hanya dianggap pipe kalau diikuti nama filter. Jadi description uplink|ISP tetap nilai biasa.
  • Pola yang berisi spasi atau | diberi tanda kutip.
  • Pipe hanya untuk show, ping, traceroute, dan (di mode konfigurasi) show/compare.

Bantuan dan singkatan

Tab Lengkapi kata (termasuk nama port dataplane)
? Pilihan pada posisi kursor, beserta penjelasannya
sh int Singkatan show interfaces
Ctrl+C Batalkan baris
Ctrl+D Keluar (di mode konfigurasi hanya kalau tidak ada perubahan)

Tanpa interaktif

cidr-cli -c "show interfaces; show dataplane load"
cidr-cli -f perintah.txt

Perintah dijalankan berurutan dan berhenti di error pertama (kode keluar 1).