導航:首頁 > 編程系統 > linux7查看網卡

linux7查看網卡

發布時間:2023-03-13 20:15:10

『壹』 有誰知道linux查網卡型號的方法是怎樣的

兩種通過命令查看網卡型號的方法

#lspci-v|grep-A10-iethernet
02:01.0Ethernetcontroller:(Copper)(rev01)
Subsystem:VMwarePRO/1000MTSinglePortAdapter
PhysicalSlot:33
Flags:busmaster,66MHz,mediumdevsel,latency0,IRQ19
Memoryatfd5c0000(64-bit,non-prefetchable)[size=128K]
Memoryatfdff0000(64-bit,non-prefetchable)[size=64K]
I/Oportsat2000[size=64]
[virtual]ExpansionROMatfd500000[disabled][size=64K]
Capabilities:[dc]PowerManagementversion2
Capabilities:[e4]PCI-Xnon-bridgedevice
Kerneldriverinuse:e1000


#lshw-cnetwork
*-network
description:Ethernetinterface
proct:(Copper)
vendor:IntelCorporation
physicalid:1
businfo:pci@0000:02:01.0
logicalname:ens33
version:01
serial:00:0c:29:b6:d7:9f
size:1Gbit/s
capacity:1Gbit/s
width:64bits
clock:66MHz
capabilities:pmpcixbus_mastercap_-fd100bt100bt-fd1000bt-fdautonegotiation
configuration:autonegotiation=onbroadcast=yesdriver=e1000driverversion=7.3.21-k8-NAPIplex=fullip=192.168.65.146latency=0link=yesmingnt=255multicast=yesport=twistedpairspeed=1Gbit/s
resources:irq:19memory:fd5c0000-fd5dffffmemory:fdff0000-fdffffffioport:2000(size=64)memory:fd500000-fd50ffff

『貳』 linux多網卡機上如何通過工具查看各網卡是否接入網路

一、通過mii-tool指令
[root@linuxzgf ~]# mii-tool
//mii-tool主要是用於配置網卡工作模式的指令,同時也可以進行查詢、監控等工作!
二、ethtool
[root@linuxzgf ~]# ethtool eth0
Settings for eth0:
Supported ports: [ TP ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
Supports auto-negotiation: Yes
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
Advertised auto-negotiation: Yes
Speed: 100Mb/s
Duplex: Full
Port: Twisted Pair
PHYAD: 0
Transceiver: internal
Auto-negotiation: on
Supports Wake-on: umbg
Wake-on: g
Current message level: 0x00000007 (7)
Link detected: yes
從上面 Link detected 可以看出eth0 處於連接狀態
三.[root@linuxzgf ~]# /etc/init.d/network status
配置設備:
lo eth0 eth0.10 eth0.2 eth0.3 eth0.4 eth0.5 eth0.7 eth0.8 eth1
當前的活躍設備:
lo eth0 eth0.10
[四、ifconfig -a
[root@linuxzgf ~]# ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:E0:81:80:D8:96
inet6 addr: fe80::2e0:81ff:fe80:d896/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:626032 errors:0 dropped:0 overruns:0 frame:0
TX packets:415035 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
RX bytes:123631002 (117.9 MiB) TX bytes:297575498 (283.7 MiB)
Base address:0x2000 Memory:df300000-df320000
eth1 Link encap:Ethernet HWaddr 00:E0:81:80:D8:97
BROADCAST MULTICAST MTU:1500 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:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Base address:0x2020 Memory:df320000-df340000
五、lspci也可以看到網卡的信息

『叄』 Linux 企業7版本,虛擬機下只有lo網卡沒eno和eth0網卡,

此原因可以按照以下步驟分析:
注意:在操作時候建議關閉NetworkManager服務(service NetworkManager stop;chkconfig NetworkManager off)
1、網卡驅動,一般用vm安裝不會有此種情況
2、ifconfig -a 看下所有的網卡。默認是按照eht0 1.2.3.4—排序,當網路沒有連接的時候
然後ifconfig -a可以看到主機上有幾塊網卡以及名稱:
這樣可以確定網卡存在,沒有問題。如果不存在任何ethx的話,說明網卡有問題。
3、然後進入配置文件(裡面是沒有ifcfg-eth0的只有個lo):
[root@redhat]# cd /etc/sysconfig/network-scripts/
[root@redhat]# ls
ifcfg-lo ifdown-bnep ifdown-ipv6 ifdown-ppp ifdown-tunnel ifup-bnep
ifup-ipv6 ifup-plusb ifup-routes ifup-wireless network-functions
ifcfg-lo ifdown-eth ifdown-isdn ifdown-routes ifup ifup-eth ifup-isdn ifup-post ifup-sit init.ipv6-global network-functions-ipv6
ifdown ifdown-ippp ifdown-post ifdown-sit ifup-aliases ifup-ippp ifup-plip ifup-ppp ifup-tunnel net.hotplug
4、這樣可以新建個ifcfg-ethx。
然後編輯裡面內容添加:
ONBOOT=yes
USERCTL=no
PEERDNS=yes
TYPE=Ethernet
DEVICE=eth1 #//(此處的1是網卡設備的序號也就是ifconfig -a中看到的網卡名稱後綴數字)
HWADDR=00:0c:29:64:c2:5f #此處可以不添加,根據自己機器而定(建議先不添加地址是網卡的地址,可以在虛擬機設置裡面查看。)
BOOTPROTO=dhcp
5、然後保存重啟服務
service network restart

『肆』 linux 怎麼啟動網卡

在實際工作中,經常會遇到Linux系統進行重啟網卡的操作,有以下三種方法:

1、service network restart

3、ifconfig eth0 up可以用於啟動網卡 ;

4、ifconfig eth0 down可以用於禁用網卡 。

『伍』 linux下如何查看網卡驅動版本信息

Linux下查看網卡驅動和版本信息
查看網卡生產廠商和信號
查看基本信息:lspci
查看詳細信息:lspci -vvv # 3個小寫的v
查看網卡信息:lspci | grep Ethernet
查看網卡驅動
查看網卡驅動信息:lspci -vvv # 找到網卡設備的詳細信息,包括網卡驅動
# lsmod 列出載入的所有驅動,包括網卡驅動

查看網卡驅動版本
查看模塊信息:modifo<mole name> # 其中包含version信息
或 # ethtool-i <device name>
RHEL 6.3中的網卡驅動版本:
# modinfo igb
filename: /lib/moles/2.6.32-279.el6.x86_64/kernel/drivers/net/igb/igb.ko
version: 3.2.10-k
license: GPL
description: Intel(R) Gigabit Ethernet Network Driver
# modinfo e1000e
filename: /lib/moles/2.6.32-279.el6.x86_64/kernel/drivers/net/e1000e/e1000e.ko
version: 1.9.5-k
license: GPL
description: Intel(R) PRO/1000 Network Driver
author: Intel Corporation,<[email protected]>
# modinfo e1000
filename: /lib/moles/2.6.32-279.el6.x86_64/kernel/drivers/net/e1000/e1000.ko
version: 8.0.35-NAPI
license: GPL
description: Intel(R) PRO/1000 Network Driver
# modinfo ixgbe
filename: /lib/moles/2.6.32-279.el6.x86_64/kernel/drivers/net/ixgbe/ixgbe.ko
version: 3.6.7-k
license: GPL
description: Intel(R) 10 Gigabit PCI Express NetworkDriver
# modinfo r8169
filename: /lib/moles/2.6.32-279.el6.x86_64/kernel/drivers/net/r8169.ko
version: 2.3LK-NAPI
license: GPL
description: RealTek RTL-8169 Gigabit Ethernet driver
查看網路介面隊列數
查看網卡介面的中斷信息:#cat /proc/interrupts | grep eth0
或 # ethtool-S eth0
查看網卡驅動源碼的版本號
解壓Intel網卡驅動源碼,打開解壓縮目錄下的*.spec文件查看驅動的版本。
例如:解壓e1000-8.0.35.tar.gz網卡驅動後,查看e1000.spec文件。
Name:e1000
Summary:Intel(R) Gigabit Ethernet Connection
Version: 8.0.35
Release:1
Source:%{name}-%{version}.tar.gz
Vendor:Intel Corporation
License:GPL
ExclusiveOS:linux
Group:System Environment/Kernel
在驅動源碼src目錄中查找:
#grep DRV_VERSION * # forLinux
#findstr DRV_VERSION * # for Windows
在e1000_main.c中也能找到定義驅動版本的一行:
#define DRV_VERSION"8.0.35" DRV_NAPI DRV_DEBUG DRV_HW_PERF
在e1000e中src目錄下netdev.c文件:
#define DRV_VERSION"3.0.4.1" DRV_EXTRAVERSION
igb_main.c:
#define MAJ 5
#define MIN 2
#define BUILD 9.4
#define DRV_VERSION__stringify(MAJ) "." __stringify(MIN) "."\
ixgbe_main.c:
#define DRV_VERSION __stringify(3.22.3) DRIVERIOVDRV_HW_PERF FP GA \

『陸』 Linux網卡配置查看與修改

准備流程:
1 首先准備/檢查好環境。
主要是確定到底是centos6還是centos7系統,因為兩個系統命令不同。
2 操作之前做好備份。
操作完成不一定成功,先備份好,給自己留條退路。
3 進行配置之後注意保存
4 配置完成需要檢查
5 編寫項目文檔,方便交接

系統關機:
shutdown

1 ip address show/ip a #檢查網卡地址配置

2 ping 網址/ip #測試網路的連接性

執行該命令,出現如下界面,選擇【edit a connection】,在彈出的新窗口中選擇需要編輯的網卡,然後選擇【edit】就進入網卡編輯窗口了。

當對網卡進行編輯好後,保存方式依次點擊三個窗口的 【ok】->【back】->【quit】完成保存退出。注意,該方式只是重新配置好了,但還是沒有生效,需要重新啟動網卡服務才能生效。
4 systemctl restart network #系統控制 重啟 網路服務

這里介紹一下網卡設置的一些概念的含義:
ip地址:網路通信的標識信息
子網掩碼:在區域網中可以有多少個主機
網關地址:從一個區域網到另一個區域網的必經之路

1 ctrl+c #中斷當前命令操作(中斷那些持續的命令)
2 ctrl+l #清屏操作

閱讀全文

與linux7查看網卡相關的資料

熱點內容
提現購是哪個app 瀏覽:114
word如何整體縮小 瀏覽:528
中興光纖貓f460埠映射教程 瀏覽:41
怎麼弄迷你世界編程 瀏覽:702
qq發手機里的文件找不到 瀏覽:832
百度雲文件有密碼忘記了怎麼辦 瀏覽:469
掃描文件掃到哪裡了 瀏覽:85
為什麼淘寶app是黑色的 瀏覽:17
如何在cad中把圖形輸出為pdf文件 瀏覽:535
文件夾橫簽 瀏覽:988
extjs5mvc 瀏覽:614
win7如何安裝資料庫 瀏覽:647
informix資料庫倒數卸數 瀏覽:983
華碩p7h55mplus升級 瀏覽:240
servlet調用jsp 瀏覽:481
文件的命名原則有哪些 瀏覽:352
蘋果的文件管理是哪個 瀏覽:387
智能黑板如何給pdf文件做批註 瀏覽:788
哈弗智聯app如何綁定二手車 瀏覽:728
cad文件不多可是異常增大 瀏覽:872

友情鏈接