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

Example Analysis of Network Card configuration File in CentOS8

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

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

This article mainly introduces the example analysis of the network card configuration file in CentOS8, which has a certain reference value, and interested friends can refer to it. I hope you will gain a lot after reading this article.

I. introduction

Centos8 system update, the new version makes people feel very comfortable, at this time someone will configure the CentOS8 system network card to make the system online, will encounter the configured network card will not take effect, think about it and configure CentOS7 when the same ah, the biggest change in CentOS8 update is the network card, and then configure the network card

II. Configuration

Nic configuration file: / etc/sysconfig/network-scripts/ifcfg-ens33

[root@localhost ~] # cd / etc/sysconfig/network-scripts/ [root@localhost network-scripts] # ls # you will see a configuration file for configuring the network card [root@localhost network-scripts] # vim ifcfg-ens33 # go to the configuration file of the network card

The following configuration file: red bold is modified; yellow background is added; black bold is added comment.

TYPE=EthernetPROXY_METHOD=noneBROWSER_ONLY=noBOOTPROTO=staticDEFROUTE=yesIPADDR=192.168.10.111NETMASK=255.255.255.0GATEWAY=192.168.10.1DNS1=114.114.114.114IPV4_FAILURE_FATAL=no#IPV6INIT=yes#IPV6_AUTOCONF=yes#IPV6_DEFROUTE=yes#IPV6_FAILURE_FATAL=no#IPV6_ADDR_GEN_MODE=stable-privacyNAME=ens33UUID=7afc67d5-b767-4d89-97b4-2558f8dc33c3DEVICE=ens33ONBOOT=yes [root@localhost network-scripts] # nmcli c reload # restart the network card

See here, do not feel the gap with the CentOS7 system!

III. Interpretation of nmcli command

Nacli uses:

Usage: nmcli [option] OBJECT

Options:

-o [verview] Overview mode (hides default values)

-t [erse] concise output

-p [retty] neat output

-m [ode] tabular | multiline output mode

-c [olors] auto | yes | whether no uses colors in the output

-e [scape] yes | no escapes column delimiters in values

-a [sk] asks for missing parameters

-s [how-secrets] allows password to be displayed

-w [ait] sets the timeout wait time for completed operations

-v [ersion] display program version

-h [elp] output this help

Object:

G [eneral] General status and operation of the Network Manager (NetworkManager)

N [etworking] integrated networked control

R [adio] Network Manager Radio switch

C [onnection] connection to the network manager

D [evice] Devices managed by the network manager

A [gent] the secret agent or polkit agent of the network manager

M [onitor] monitors network manager changes

Generally use c:

[root@localhost network-scripts] # nmcli c-- help # option to see help COMMAND: = {show | up | down | add | modify | clone | delete | monitor | reload | load | import | export} Thank you for reading this article carefully. I hope the article "sample Analysis of Network Card configuration File in CentOS8" shared by the editor will be helpful to you. At the same time, I hope you will support it and pay attention to the industry information channel. More related knowledge is waiting for you to learn!

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