nmcli: add more server examples (#3816)
This commit is contained in:
27
pages/linux/nmcli-connection.md
Normal file
27
pages/linux/nmcli-connection.md
Normal file
@@ -0,0 +1,27 @@
|
||||
# nmcli connection
|
||||
|
||||
> Connection management with NetworkManager.
|
||||
|
||||
- List all NetworkManager connections (shows name, uuid, type and device):
|
||||
|
||||
`nmcli connection`
|
||||
|
||||
- Activate a connection by specifying an uuid:
|
||||
|
||||
`nmcli connection up uuid {{uuid}}`
|
||||
|
||||
- Deactivate a connection:
|
||||
|
||||
`nmcli connection down uuid {{uuid}}`
|
||||
|
||||
- Create an auto-configured dual stack connection:
|
||||
|
||||
`nmcli connection add ifname {{interface_name}} type {{ethernet}} ipv4.method {{auto}} ipv6.method {{auto}}`
|
||||
|
||||
- Create a static IPv6-only connection:
|
||||
|
||||
`nmcli connection add ifname {{interface_name}} type {{ethernet}} ip6 {{2001:db8::2/64}} gw6 {{2001:db8::1}} ipv6.dns {{2001:db8::1}} ipv4.method {{ignore}}`
|
||||
|
||||
- Create a static IPv4-only connection:
|
||||
|
||||
`nmcli connection add ifname {{interface_name}} type {{ethernet}} ip4 {{10.0.0.7/8}} gw4 {{10.0.0.1}} ipv4.dns {{10.0.0.1}} ipv6.method {{ignore}}`
|
15
pages/linux/nmcli-device.md
Normal file
15
pages/linux/nmcli-device.md
Normal file
@@ -0,0 +1,15 @@
|
||||
# nmcli device
|
||||
|
||||
> Hardware device management with NetworkManager.
|
||||
|
||||
- Print the statuses of all network interfaces:
|
||||
|
||||
`nmcli device status`
|
||||
|
||||
- Print the available Wi-Fi access points:
|
||||
|
||||
`nmcli device wifi`
|
||||
|
||||
- Connect to the Wi-Fi network with a specified name and password:
|
||||
|
||||
`nmcli device wifi connect {{ssid}} password {{password}}`
|
@@ -2,26 +2,18 @@
|
||||
|
||||
> A command line tool for controlling NetworkManager.
|
||||
|
||||
- List all NetworkManager connections (shows name, uuid, type and device):
|
||||
- Check the nmcli version:
|
||||
|
||||
`nmcli connection`
|
||||
`nmcli --version`
|
||||
|
||||
- Print the available Wi-Fi access points:
|
||||
- Call general help:
|
||||
|
||||
`nmcli device wifi`
|
||||
`nmcli --help`
|
||||
|
||||
- Connect to the Wi-Fi network with a specified name and password:
|
||||
- Call help on a command:
|
||||
|
||||
`nmcli device wifi connect {{name}} password {{password}}`
|
||||
`nmcli {{command}} --help`
|
||||
|
||||
- Activate a connection by specifying an uuid:
|
||||
- Execute an `nmcli` command:
|
||||
|
||||
`nmcli connection up uuid {{uuid}}`
|
||||
|
||||
- Deactivate a connection:
|
||||
|
||||
`nmcli connection down uuid {{uuid}}`
|
||||
|
||||
- Print statuses of network interfaces:
|
||||
|
||||
`nmcli device status`
|
||||
`nmcli {{command}}`
|
||||
|
Reference in New Issue
Block a user