参考资料:http://blog.chinaunix.net/uid-10697776-id-3080243.html
http://hi.baidu.com/widebright/item/2f28cd0da72b9210addc70a7
问:dell的optiplex 360或者optiplex 380机器,broadcom网卡如何在redhat enterprise linux 5系统下识别和安装驱动?
答案如下:
首先看网卡是否已经正确连接到计算机,使用的命令是lspci。redhat上使用lspci的输出:
[root@localhost ~]# lspci
00:00.0 Host bridge: Intel Corporation Eaglelake DRAM Controller (rev 03)
00:01.0 PCI bridge: Intel Corporation Eaglelake PCI Express Root Port (rev 03)
00:02.0 VGA compatible controller: Intel Corporation Eaglelake Integrated Graphics Controller (rev 03)
00:02.1 Display controller: Intel Corporation Eaglelake Integrated Graphics Controller (rev 03)
00:1b.0 Audio device: Intel Corporation 82801G (ICH7 Family) High Definition Audio Controller (rev 01)
00:1c.0 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 1 (rev 01)
00:1d.0 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #1 (rev 01)
00:1d.1 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #2 (rev 01)
00:1d.2 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #3 (rev 01)
00:1d.3 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #4 (rev 01)
00:1d.7 USB Controller: Intel Corporation 82801G (ICH7 Family) USB2 EHCI Controller (rev 01)
00:1e.0 PCI bridge: Intel Corporation 82801 PCI Bridge (rev e1)
00:1f.0 ISA bridge: Intel Corporation 82801GB/GR (ICH7 Family) LPC Interface Bridge (rev 01)
00:1f.1 IDE interface: Intel Corporation 82801G (ICH7 Family) IDE Controller (rev 01)
00:1f.2 IDE interface: Intel Corporation 82801GB/GR/GH (ICH7 Family) SATA IDE Controller (rev 01)
00:1f.3 SMBus: Intel Corporation 82801G (ICH7 Family) SMBus Controller (rev 01)
会发现系统识别不到这个网卡的设备,需要更新网卡设备读取文件,具体是:
用update-pciids 命令先更新一下 系统的pci.ids文件,这个最新的应该有人维护的在http://pciids.sourceforge.net/ 可以找得到。
或者像我这样直接手工更新一下/usr/share/hwdata/pci.ids 文件的内容。
把pci.ids文件放到tmp目录
Redhat上使用命令:cp /tmp/pci.ids /usr/share/hwdata/pci.ids;回车后回复yes
再次执行lspci,结果如下,成功识别。
[root@localhost ~]# cp /tmp/llj/pci.ids /usr/share/hwdata/pci.ids
cp:是否覆盖“/usr/share/hwdata/pci.ids”? yes
[root@localhost ~]# lspci
00:00.0 Host bridge: Intel Corporation 4 Series Chipset DRAM Controller (rev 03)
00:01.0 PCI bridge: Intel Corporation 4 Series Chipset PCI Express Root Port (rev 03)
00:02.0 VGA compatible controller: Intel Corporation 4 Series Chipset Integrated Graphics Controller (rev 03)
00:02.1 Display controller: Intel Corporation 4 Series Chipset Integrated Graphics Controller (rev 03)
00:1b.0 Audio device: Intel Corporation NM10/ICH7 Family High Definition Audio Controller (rev 01)
00:1c.0 PCI bridge: Intel Corporation NM10/ICH7 Family PCI Express Port 1 (rev 01)
00:1d.0 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #1 (rev 01)
00:1d.1 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #2 (rev 01)
00:1d.2 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #3 (rev 01)
00:1d.3 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #4 (rev 01)
00:1d.7 USB controller: Intel Corporation NM10/ICH7 Family USB2 EHCI Controller (rev 01)
00:1e.0 PCI bridge: Intel Corporation 82801 PCI Bridge (rev e1)
00:1f.0 ISA bridge: Intel Corporation 82801GB/GR (ICH7 Family) LPC Interface Bridge (rev 01)
00:1f.1 IDE interface: Intel Corporation 82801G (ICH7 Family) IDE Controller (rev 01)
00:1f.2 IDE interface: Intel Corporation NM10/ICH7 Family SATA Controller [IDE mode] (rev 01)
00:1f.3 SMBus: Intel Corporation NM10/ICH7 Family SMBus Controller (rev 01)
02:00.0 Ethernet controller: Broadcom Corporation NetLink BCM57780 Gigabit Ethernet PCIe (rev 01)
网卡成功识别后,使用ifconfig命令看网卡信息,发现没有eth0,需要进行如下操作:
下载网卡驱动安装包:
kernel-2.6.18-92.el5.i686.rpm
kernel-devel-2.6.18-92.el5.i686.rpm
kernel-xen-2.6.18-92.el5.i686.rpm
kernel-xen-devel-2.6.18-92.el5.i686.rpm
tg3-3.122n-1.src.rpm
使用rpm –ivh 命令安装上面的kernel包
Tg3包安装步骤如下:
[root@localhost llj]# rpm -ivh tg3-3.122n-1.src.rpm
1:tg3 ########################################### [100%]
[root@localhost llj]# cd /usr/src/redhat/
[root@localhost redhat]# rpmbuild -bb SPECS/tg3.spec
[root@localhost redhat]# rpm -ivh RPMS/i386/tg3-3.122n-1.i386.rpm
Preparing... ########################################### [100%]
1:tg3 ########################################### [100%]
[root@localhost redhat]# modprobe tg3
打开网络设备:[root@linpcl root]#ifconfig eth0 up
使用命令ifconfig查看可看见eth0
到此Dell optiplex 380 broadcom网卡在redhat 5下网卡识别和安装驱动完毕。^_^。