mos-stack / mOS-networking-stack

A Specialized Network Programming Library for Stateful Middleboxes:
http://mos.kaist.edu
Other
103 stars 21 forks source link

Performance problem #26

Open chandaweia opened 4 years ago

chandaweia commented 4 years ago

I’m using your latest version mOS-networking-stack but meet a problem. I will be grateful if you can help me. I found that if I run the Midstat in inline mode and add a line code “g_max_cores = 6;” in here: https://github.com/mos-stack/mOS-networking-stack/blob/master/samples/midstat/midstat.c#L298 , the midstat will have very low performance(the throughput will decrease from 1.1G to ~140M or even 0 )(like the following picture). I thought there may be a problem of coordination of multiple mtcp threads.

If I don't edit the code and just run by ./midstat -c 6, the performance problem also exists.

image

ajamshed commented 4 years ago

@ygmoon , If you have some time, can you please take a look at it. @chandaweia, I will test out midstat over the weekend. Please allow me a few days. I will have to set up my testbed in the lab server room before I can run this experiment.

chandaweia commented 4 years ago

Thanks so much. If you have some questions about my test of Midstat, let me know. I'm glad to talk about the MOS with you.

ajamshed commented 4 years ago

Can you please share the contents of the following:

chandaweia commented 4 years ago

Is there only one conf file to be used when running the midstat? The configuration samples/midstat/config/mos.conf is as the following. image

ygmoon commented 4 years ago

Hi @chandaweia . Yes, midstat only require mos.conf. Could you please let me know the NIC model that you're using? How many CPU cores are available in your setup?

chandaweia commented 4 years ago

Hi @ygmoon . The NIC model is as following. The CPU cores are 20 but when I run without changing any of your code, there will be 8 threading running by using htop. Actually, I want to limit the cores the midstat uses, so I change the g_max_cores value. And after changing, the performance will decrease. I wonder whether there may be rings that don't match the number of mtcp threads.

image