Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

libos-nuse/net-next-nuse#45 ? #22

Open
vincentmli opened this issue Jul 2, 2015 · 4 comments
Open

libos-nuse/net-next-nuse#45 ? #22

vincentmli opened this issue Jul 2, 2015 · 4 comments

Comments

@vincentmli
Copy link

I found a common pattern here that when I run either ping, iperf, or my own simple http client using libos-nuse, after ping or iperf run for a little while, the packet will stop completely, at one time ping test, I get:

ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available
ping: sendmsg: No buffer space available

I tried libos-nuse with DPDK 1.7.1 or DPDK git upstream. both have same issue. I can try libos-nuse without DPDK, will let you know the result

@vincentmli
Copy link
Author

I tested without DPDK, libos-nuse experienced same issue that the packet completely stops after some packet passing.( I ran tcpdump at the destination host to monitor traffic). please let me know what detail information you need to help you understand the issue.

@thehajime
Copy link
Member

@vincentmli I'm going to reproduce this issue on my local machine.

  • how does the command line argument look like ? a complete list of cmd line would be the best
  • how long does it take until stop the packet passing ?
  • brief information about nuse.conf would be a plus.

thank you again.

@vincentmli
Copy link
Author

I think this issue maybe same as libos-nuse/net-next-nuse#45.
here is my own simple c code to send http get request to reproduce the issue
http://www.vcn.bc.ca/~vli/httpgettfo.c.txt

to compile the program:

#gcc -g -dH -o httpgettfo httpgettfo.c
#cp httpgettfo /bin

in my code i have usleep in the for loop, if it sleep 100 microsecond, it core dumps each run with same backtrace as libos-nuse/net-next-nuse#45. If it sleep 0.1 second, the program would not core dump, but hang forever after running for a while (maybe 1 - 2 mintues). do you think it might be different than libos-nuse/net-next-nuse#45 ?

for (;;) {
//sleep(1);
usleep(100);
if(get_page_thread(hpptr)){
perror("Can't get page");
exit(2);
}
}

my /home/vincent/nuse-raw.conf

interface p1p1
address 10.9.1.9
netmask 255.255.255.0
macaddr 00:01:01:01:01:02
viftype RAW

route
network 10.9.1.0
netmask 255.255.255.0
gateway 10.9.1.2

I put the NUSECONF in the nuse bash script as:

export NUSECONF=/home/vincent/nuse-raw.conf

if [ -e /usr/lib64 ]; then
sudo ln -f -s pwd/libnuse-linux.so /usr/lib64/libnuse-linux.so
fi
sudo ln -f -s pwd/libnuse-linux.so /usr/lib/libnuse-linux.so
sudo chown root libnuse-linux.so
sudo chmod 4755 libnuse-linux.so

LD_LIBRARY_PATH=.:../../../ LD_PRELOAD=liblinux.so:libnuse-linux.so $*

and run the command as:

#./nuse httpgettfo 10.9.1.2

by the way, has libos-nuse/net-next-nuse#45 been fixed ?

@thehajime
Copy link
Member

@vincentmli thanks, I will look at this issue with your program.

I had a tentative patch for libos-nuse/net-next-nuse#45, but it's not a generic solution so need to work more.

https://gist.github.com/thehajime/65e58a101f0c50a04764

@vincentmli vincentmli changed the title memory leak? libos-nuse/net-next-nuse#45 ? Jul 10, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants