Open zkl94 opened 7 years ago
Perhaps it is the problem with hugepages, try to set them up.
Thanks for the help. I really appreciate it!
It turns out that I didn't config hugepages in the right way. After specifying 1G hugepage size in kernel cmd parameter and mount it with hugetlbfs with fstab, the hugepage warning disappear. However, the 'No Ethernet ports' error still exists.
EAL: Detected 8 lcore(s)
EAL: Probing VFIO support...
EAL: Error - exiting with code: 1
Cause: No Ethernet ports - bye
My NIC binding is still the same as above, where one device has DPDK-compatible driver.
I am now able to run ./a.out
, ./a.out --dpdk-pmd
, and ./a.out --network-stack native
(with help from this tutorial) successfully. However, ./a.out --dpdk-pmd --network-stack native
still shows the error above.
Could you provide more suggestions?
Do the sample applications from dpdk work?
Hi Zhikun,
Can you try to run your application through the scripts/run_with_dpdk.sh helper script? It should bind the specified NIC for you to use it with DPDK.
Another thing to try is modprobe uio_pci_generic
which enables the generic driver suitable for most DPDK-comparible NICs.
Have you solved this problem? I also have this problem and I am suspecting that my NICs don't support DPDK. Have you considered you NICs?
I encounter the same problem as @zkl94. EAL: Detected 64 lcore(s) EAL: Probing VFIO support... EAL: Error - exiting with code: 1 Cause: No Ethernet ports - bye
And, how do you run ./a.out --network-stack native
successful ?
Are you configure a virbr0 ?
If not, it will output an error "[shard 0] seastar - Exceptional future ignored: std::system_error (error system:2, No such file or directory), backtrace: 0x41a9e4"
Same here at my side.
Maybe someone can help?
In my case (same error) turns out that DPDK requires a couple of libraries to be linked even if not used by the code (specifically the PWDs that are registered automatically on library load - which causes rte_eth_dev_count to return 0) Use the -Wl,--whole-archive,-ldpdk,--no-whole-archive during the linking stage to link with the whole dpdk library to fix the issue. I don't know the best way to add this to the seastar library itself (in the CMake) but this, for example, fixes the issue specifically for the apps folder:
diff --git a/apps/CMakeLists.txt b/apps/CMakeLists.txt
index d1a97279..c2b3188e 100644
--- a/apps/CMakeLists.txt
+++ b/apps/CMakeLists.txt
@@ -40,7 +40,7 @@ macro (seastar_add_app name)
PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
target_link_libraries (${target}
- PRIVATE seastar_private)
+ PRIVATE seastar_private -Wl,--whole-archive,-ldpdk,--no-whole-archive)
set_target_properties (${target}
PROPERTIES
@avikivity maybe you can help with incorporating this into the seastar library build process
Hi Folks,
We recently developed a simple key-value server using Seastar. We used default setting to run the server during development (no native stack, no DPDK). In order to benchmark it, we tried to run it with native stack and DPDK support on an Ubuntu VM on Google Cloud Platform.
The VM is of type n1-standard-8 with 8 vCPUs and 30GB memory. It is equipped with two network interfaces: one for remote login (first NIC), one for enabling DPDK (second NIC).
First, we clone the seastar project, do everything necessary to build it with DPDK enabled. Then we compile our project. After compilation, our application can run smoothly (
./a.out
, without parameters).To enable DPDK + native stack, we did the following:
ifconfig SECOND_NIC down
./a.out --network-stack native --dpdk-pmd --dhcp 1 --smp 8 -m 2G
and we get the following error:NIC binding output from dpdk-setup.sh:
So even though there is a device with DPDK-compatible driver, seastar can't recognize it.
Could you give us any help?