mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-02-24 09:52:03 +00:00
Update cheatsheets
This commit is contained in:
@@ -16,21 +16,21 @@ source: https://github.com/tldr-pages/tldr.git
|
||||
|
||||
`sudo ip {{[r|route]}} {{[a|add]}} default via {{gateway_ip}}`
|
||||
|
||||
- Add a default route using `eth0`:
|
||||
- Add a default route using `ethX`:
|
||||
|
||||
`sudo ip {{[r|route]}} {{[a|add]}} default dev {{eth0}}`
|
||||
`sudo ip {{[r|route]}} {{[a|add]}} default dev {{ethX}}`
|
||||
|
||||
- Add a static route:
|
||||
|
||||
`sudo ip {{[r|route]}} {{[a|add]}} {{destination_ip}} via {{gateway_ip}} dev {{eth0}}`
|
||||
`sudo ip {{[r|route]}} {{[a|add]}} {{destination_ip}} via {{gateway_ip}} dev {{ethX}}`
|
||||
|
||||
- Delete a static route:
|
||||
|
||||
`sudo ip {{[r|route]}} {{[d|delete]}} {{destination_ip}} dev {{eth0}}`
|
||||
`sudo ip {{[r|route]}} {{[d|delete]}} {{destination_ip}} dev {{ethX}}`
|
||||
|
||||
- Change or replace a static route:
|
||||
|
||||
`sudo ip {{[r|route]}} {{change|replace}} {{destination_ip}} via {{gateway_ip}} dev {{eth0}}`
|
||||
`sudo ip {{[r|route]}} {{change|replace}} {{destination_ip}} via {{gateway_ip}} dev {{ethX}}`
|
||||
|
||||
- Show which route will be used by the kernel to reach an IP address:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user