In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article introduces the relevant knowledge of "how RHEL7 configures ip addresses". In the operation of actual cases, many people will encounter such a dilemma, so let the editor lead you to learn how to deal with these situations. I hope you can read it carefully and be able to achieve something!
Graphical interface configuration method
Click on the wired connection in the upper right corner of the desktop, and select configure ens33
Enter ip address, mask, DNS, gateway, etc.
Then select the startup to ok.
In this way, the network configuration is complete!
By modifying the configuration file
Modify the configuration ip by modifying the ifcfg-ens33 configuration file
[root@localhost] # vim / etc/sysconfig/network-scripts/ifcfg-ens33 TYPE=EthernetPROXY_METHOD=noneBROWSER_ONLY=noBOOTPROTO=dhcpDEFROUTE=yesIPV4_FAILURE_FATAL=noIPV6INIT=yesIPV6_AUTOCONF=yesIPV6_DEFROUTE=yesIPV6_FAILURE_FATAL=noIPV6_ADDR_GEN_MODE=stable-privacyNAME=ens33UUID=96a5f670-6b15-4711Muaf6eMur92aa92e1c66bDEVICEroomens33ONBOOTRANNON ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ "/ etc/sysconfig/network-scripts/ifcfg-ens33" 15L 279C
Change BOOTPROTO to static
Change ONBOOT=no to ONBOOT=yes
Add the IPADDR NETMASK GATEWAY DNS1 field as follows:
[root@localhost] # cat / etc/sysconfig/network-scripts/ifcfg-ens33 TYPE=EthernetPROXY_METHOD=noneBROWSER_ONLY=noBOOTPROTO=staticDEFROUTE=yesIPV4_FAILURE_FATAL=noIPV6INIT=yesIPV6_AUTOCONF=yesIPV6_DEFROUTE=yesIPV6_FAILURE_FATAL=noIPV6_ADDR_GEN_MODE=stable-privacyNAME=ens33UUID=96a5f670-6b15-4711-af6e-92aa92e1c66bDEVICE=ens33ONBOOT=yesIPADDR=172.16.1.115NETMASK=255.255.255.0GATEWAY=172.16.1.254DNS1=8.8.8.8
So restart the network card on it!
[root@localhost ~] # systemctl restart network
Use tool configuration
Enter the following command to specify the ip mask
[root@localhost ~] # nmcli connection modify ens33 ipv4.method manual ipv4.address 172.16.1.120 Universe 24 connection.autoconnect yes
Restart the network card
[root@localhost ~] # ifconfigens33: flags=4163mtu 1500 inet 172.16.1.120 netmask 255.255.255.0 broadcast 172.16.1.255 inet6 fe80::d09c:682a:b786:6214 prefixlen 64 scopeid 0x20 ether 00:0c:29:65:07:1a txqueuelen 1000 (Ethernet) RX packets 2536 bytes 836453 (816.8 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 2054 bytes 277233 (270.7 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0lo: flags=73mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6:: 1 prefixlen 128 scopeid 0x10loop txqueuelen 1 (Local Loopback) RX packets 96 bytes 8256 (8.0 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 96 bytes 8256 (8.0 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0virbr0: flags=4099mtu 1500 inet 192. 168.122.1 netmask 255.255.255.0 broadcast 192.168.122.255 ether 52:54:00:dc:7d:cf txqueuelen 1000 (Ethernet) RX packets 0 bytes 0 (0.0B) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 0 bytes 0 (0.0B) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 "how RHEL7 configures ip addresses" ends here. Thank you for your reading. If you want to know more about the industry, you can follow the website, the editor will output more high-quality practical articles for you!
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.