how make nmcli conn modify persistent
To modify a persistent connection using nmcli command-line tool, follow these steps:
-
Open a terminal window.
-
List all the available connections and find the connection you want to modify by running the following command:
nmcli connection show -
Identify the connection name or UUID that you want to modify.
-
Use the
nmcli conn modifycommand along with the connection name or UUID to modify the connection. For example, if the connection name is "MyConnection", run the following command:sudo nmcli conn modify MyConnection <options>Replace
<options>with the specific parameters you want to modify. Some commonly used options include:connection.autoconnect yes|noto enable or disable automatic connection.ipv4.method manual|autoto set the IPv4 addressing method.ipv4.addresses IP_ADDRESS[/PREFIX]to set the IPv4 address and subnet mask.ipv4.gateway IP_ADDRESSto set the IPv4 gateway.ipv4.dns IP_ADDRESS1 IP_ADDRESS2to set the IPv4 DNS servers.
You can modify other options as per your requirement. Refer to the
nmclimanual for more details on available options. -
After modifying the connection, save the changes by running the following command:
sudo nmcli conn up MyConnectionReplace "MyConnection" with the actual connection name or UUID.
Note: The nmcli commands require superuser privileges, so you may need to prefix them with sudo.
By following these steps, you can successfully modify a persistent connection using nmcli
原文地址: http://www.cveoy.top/t/topic/iU3d 著作权归作者所有。请勿转载和采集!