DPDK 网卡绑定和解绑

参考:

DPDK 网卡绑定和解绑

DPDK 网卡绑定和解绑

注意: 建议不要使用本文的eth0网卡绑定dpdk驱动.

1.进入DPDK目录:

$ cd dpdk/tools/

2.查看网卡信息:

$ ./dpdk-devbind.py --status
Network devices using DPDK-compatible driver
============================================
<none> Network devices using kernel driver
===================================
0000:00:1f.6 'Ethernet Connection (2) I219-LM' if=eth0 drv=e1000e unused=igb_uio Other network devices
=====================
<none> Crypto devices using DPDK-compatible driver
===========================================
<none> Crypto devices using kernel driver
==================================
<none> Other crypto devices
====================
<none>

3.绑定eth0网卡到dpdk到驱动:

$ ./dpdk-devbind.py --bind=igb_uio 00:1f.6

4.再次查看网卡状态, 发现该网卡已经绑定到dpdk驱动:

Network devices using DPDK-compatible driver
============================================
0000:00:1f.6 'Ethernet Connection (2) I219-LM' drv=igb_uio unused= Network devices using kernel driver
===================================
<none> Other network devices
=====================
<none> Crypto devices using DPDK-compatible driver
===========================================
<none> Crypto devices using kernel driver
==================================
<none> Other crypto devices
====================
<none>

5.解绑eth0:

$ ./dpdk-devbind.py -u 00:1f.6

查看驱动信息, 此时网卡已经与dpdk驱动解绑:

Network devices using DPDK-compatible driver
============================================
<none> Network devices using kernel driver
===================================
<none> Other network devices
=====================
0000:00:1f.6 'Ethernet Connection (2) I219-LM' unused=igb_uio Crypto devices using DPDK-compatible driver
===========================================
<none> Crypto devices using kernel driver
==================================
<none> Other crypto devices
====================
<none>

如果需要重新将eth0绑定回kernel driver, 执行reboot即可:

$ reboot

2017.9

上一篇:Android之桌面组件AppWidget


下一篇:css+js定位到屏幕中间