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

What is the specific method of networking RHEL6 virtual machines?

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

Share

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

What is the specific method of RHEL6 virtual machine networking? I believe many inexperienced people are at a loss about it. Therefore, this paper summarizes the causes and solutions of the problem. Through this article, I hope you can solve this problem.

How are RHEL6 virtual machines networked?

Switch to / etc/sysconfig/network-scripts/ to know the name of your network card (use the ifconfig command) to open the corresponding file with vim

Add the following (modify if the same parameter already exists)

Shell "spellcheck=" false "> [root@admin network-scripts] # ifconfigeth0 Link encap:Ethernet HWaddr 00:0C:29:B2:F3:30 # Nic name inet addr:192.168.221.128 Bcast:192.168.221.255 Mask:255.255.255.0 inet6 addr: fe80::20c:29ff:feb2:f330/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:4845 errors:0 Dropped:0 overruns:0 frame:0 TX packets:2956 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:1757331 (1.6 MiB) TX bytes:435030 (424.8 KiB) lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: 1There 128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:0 (0.0b) TX bytes:0 (0.0b) [root@admin network-scripts] # cd / etc/sysconfig/network-scripts/ | lsifcfg-eth0 ifdown-ippp ifdown-routes ifup-bnep ifup-plip ifup- Sit network-functions [root@admin network-scripts] # vim ifcfg-eth0DEVICE=eth0HWADDR=00:0C:29:B2:F3:30TYPE=EthernetUUID=0b622218-431e-4f5d-b828-4f23c5c3fef7ONBOOT=yesNM_CONTROLLED=yesBOOTPROTO=dhcp # 1 change these three points to NETMASK=255.255.255.0 # 2DNS=114.114.114.114 # 3

Parameters to be modified:

BOOTPROTO=dhcpNETMASK=255.255.255.0DNS=114.114.114.114

Restart the service

Service network restart, after reading the above, have you mastered the specific method of networking RHEL6 virtual machines? If you want to learn more skills or want to know more about it, you are 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

Development

Wechat

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

12
Report