欢迎来到 DPDK交流社区 ,有什么问题可以尽管在这里提问,您将会收到社区其他成员的回答;也可以将您的总结写在这里,为社区其他成员提供帮助。 QQ交流2群:635461501

OpenNetVM中C++程序调用dpdk库 EAL:no free hugepages reported in hugepages

0 投票

最近在用 OpenNetVM 平台写一些用C++语言编写的包处理程序,但是发现一旦加入C++的特性,在调用dpdk库的时候就会报 EAL:no free hugepages reported in hugepages 的错误,请有经验的大佬指点迷津

makefile 文件如下:
 


ifeq ($(RTE_SDK),)

$(error "Please define RTE_SDK environment variable")

endif

 

RTE_TARGET ?= x86_64-native-linuxapp-gcc

CPPFLAGS = -std=c++11 -lpcap

LDFLAGS = -lstdc++

# Default target, can be overriden by command line or environment

include $(RTE_SDK)/mk/rte.vars.mk

 

# binary name

APP = forward

 

# all source are stored in SRCS-y

SRCS-y := forward.c

 

# OpenNetVM path

ONVM= $(SRCDIR)/../../onvm

CFLAGS = $(WERROR_FLAGS) -O3 $(USER_FLAGS)

 

CFLAGS += -I$(ONVM)/onvm_nflib

CFLAGS += -I$(ONVM)/lib

CFLAGS += -I/home/ubuntu/evan/NFV/openNetVM/dpdk/x86_64-native-linuxapp-gcc/include

LDFLAGS += $(ONVM)/onvm_nflib/$(RTE_TARGET)/libonvm.a

LDFLAGS += $(ONVM)/lib/$(RTE_TARGET)/lib/libonvmhelper.a -lm -lpthread

 

# workaround for a gcc bug with noreturn attribute

# http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12603

ifeq ($(CONFIG_RTE_TOOLCHAIN_GCC),y)

CFLAGS_main.o += -Wno-return-type

endif

include $(RTE_SDK)/mk/rte.extapp.mk


 

最新提问 1月 18 分类:DPDK API问答 | 用户: supreme90 (120 分)

1个回答

0 投票
好像未分配大页内存,谢谢!
最新回答 3月 10 用户: dpdk_lover (2,700 分)
...