Hugepages for apps running inside container

Hi,
I’m new to ‘Docker’. I apologize in advance if i’ve missed any basic stuff.

I’m trying to run an application inside the container that needs hugepages,
I configured hugepages on the host and then mounted it to container using “-v /dev/hugepages:/dev/hugepages” option and it worked fine.

I’m now trying to run 2 containers on the same host with the same -v mount option, both the containers pointing to the same /dev/hugepages of the host. In this case, i’m not able to run the these 2 applications (that needs hugepages) on these 2 containers at the same time. (I’m getting a cannot get hugepages information kinda error log from the application on one of the containers while the other application in the other container is running fine.)

Note:I haven’t gotten to the docker compose part where i read that we could simply restrict the resources to containers
.
Did i miss any configuration stuff? or what am i doing wrong here.? How do i get past this?
Any advise is appreciated. Thanks.

1 Like

Hi,

I am having the same problem at the moment. Have you managed to find a solution for this?

I am interested in running multiple containers (at least 6) on the same host, all running dpdk applications which need hugepages.

Thanks