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

Double Nic binding was successfully deployed for the first time

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >

Share

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

I installed CentOS 5.11 before I got off work yesterday, and I started to do it when I came to the company today.

Since this DELL R420 server is a standby, the configuration information of binding dual network cards can be fully referenced to the master server. When the configuration is complete, there is no problem with the ping private network. However, after configuring the DNS address, it is always impossible to ping the DNS address, so it is naturally impossible to ping the public network.

After the leader took over, check my dual network card configuration file, unplug the network cable switching test, and then directly configure it as eth0 and then ping external network, all of which will not work.

The error output of executing the "ping 8.8.8.8" command is "connect:Network is unreachable", which makes the leader very confused why there is such a prompt.

Some information on the Internet, it is said that such a hint, because there is a problem with the configuration of the network card, can not find the network card and so on.

In the afternoon, the leader decided to reinstall the server.

When I first installed this server yesterday afternoon, I strictly followed the "minimum" installation principle in lesson 1 of oldboy, and only selected the following seven software packages:

Base

Editors

Development librarys (development library)

Development tools (development tools)

X software development

System tools

Dialup Networking Support [optional]

I'm not sure if it has something to do with the lack of these packages, but the second time I install CentOS in the afternoon, I don't want to take that risk again. During the installation process, the package category selected is "Desktop-Gnome".

The specific software packages only cancel the software packages related to graphics, sound cards, games and printers, and the other software packages are not moved.

After the installation of CentOS 5.11 is complete, only 4 files are edited:

[root@Redis ~] # cat / etc/sysconfig/network-scripts/ifcfg-bond0 DEVICE=bond0TYPE=EthernetONBOOT=yesUSERCTL=noBOOTPROTO=staticIPADDR=172.16.30.122NETMASK=255.255.255.0NETWORK=172.16.30.0BROADCAST=172.16.30.255GATEWAY=172.16.30.1DNS1=8.8.8.8 [root@Redis ~] # cat / etc/sysconfig/network-scripts/ifcfg-eth0# Broadcom Corporation NetXtreme BCM5720 Gigabit Ethernet PCIeDEVICE=eth0BOOTPROTO=staticHWADDR=B0:83:FE:BF:BA:EBONBOOT=yesUSERCTL=noMASTER=bond0SLAVE=yes [root@Redis ~] # cat / etc/sysconfig/network-scripts/ifcfg-eth2# Broadcom Corporation NetXtreme BCM5720 Gigabit Ethernet PCIeDEVICE=eth2BOOTPROTO=noneHWADDR=B0:83:FE:BF:BA:ECONBOOT=yesUSERCTL=noMASTER=bond0SLAVE=yes [root@Redis ~] # cat / etc/modprobe.conf alias eth0 tg3alias eth2 tg3alias scsi_hostadapter megaraid_sasalias scsi_hostadapter1 ahci###bonding###alias bond0 bondingoptions bond0 miimon=100 mode=1 primary=eth0

After configuring the DNS1 address "DNS1=8.8.8.8" in the / etc/sysconfig/network-scripts/ifcfg-bond0 configuration file, the following / etc/resolv.conf configuration file will automatically write the DNS address after restarting the network "/ etc/init.d/network restart". So, I didn't move the / etc/resolv.conf file.

[root@Redis ~] # cat / etc/resolv.confnameserver 8.8.8.8

Execute the "/ etc/init.d/network restart" command to restart the network service.

At this point, the execution result of the ping command is normal.

[root@Redis] # ping www.baidu.comPING www.a.shifen.com (111.13.100.91) 56 (84) bytes of data.64 bytes from 111.13.100.91: icmp_seq=1 ttl=52 time=18.0 ms64 bytes from 111.13.100.91: icmp_seq=2 ttl=52 time=17.8 ms64 bytes from 111.13.100.91: icmp_seq=3 ttl=52 time=17.9 ms--- www.a.shifen.com ping statistics-3 packets transmitted, 3 received, 0 packet loss Time 2001msrtt min/avg/max/mdev = 17.957 ms 18.078 ms [root@Redis ~] # ping 8.8.8.8PING 8.8.8.8 (8.8.8.8) 56 (84) bytes of data.64 bytes from 8.8.8.8: icmp_seq=1 ttl=40 time=80.9 ms64 bytes from 8.8.8.8: icmp_seq=2 ttl=40 time=75.8 ms64 bytes from 8.8.8.8: icmp_seq=3 ttl=40 time=77.2 ms64 Bytes from 8.8.8.8: icmp_seq=4 ttl=40 time=77.4 ms--- 8.8.8.8 ping statistics-4 packets transmitted 4 received, 0% packet loss, time 3003msrtt min/avg/max/mdev = 75.845 ms 77.864 ms

I used the oldboy installation method and used it on the virtual machine many times and never had a problem. This is the second time that the production environment is really used. With full reference to his software package requirements, this is the first time.

I don't know if the first problem has something to do with too few packages selected. If I have the chance, I will continue to test it on other machines.

I would like to say that, in the end, it is to complete the arrangement of the leadership, rather than dwell on some details that are not needed in the short term.

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

Network Security

Wechat

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

12
Report