Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Use linux's nmcli commands to manage the command line tool for the network

2025-02-25 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Editor to share with you the use of linux's nmcli command network management command line tool, I hope you have learned a lot after reading this article, let's discuss it together!

The nmcli command can complete all the configurations on the network card and can be written to the configuration file.

Syntax format: nmcli [parameters]

Common parameters:

D monitor and manage the interface of network equipment c monitor and manage the connection of network equipment

Reference example

Displays a list of all connections:

[root@linuxcool ~] # nmcli con show

View interface information:

[root@linuxcool ~] # nmcli device show

Define a new connection named default, which will use DHCP to automatically connect through the Ethernet of the eth0 device:

[root@linuxcool ~] # nmcli con add con-name "default" type ethernet ifname eth0

Turn off automatic connection:

[root@linuxcool ~] # nmcli connection modify "static" connection.autoconnect no

Add DNS:

[root@linuxcool] # nmcli connection modify team0 ipv4.dns 8.8.8.8 after reading this article, I believe you have some understanding of using linux's nmcli command network management command line tool, want to know more about it, welcome to follow the industry information channel, thank you for reading!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report