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

fuzzing in docker performance #18

Closed
songxpu opened this issue May 7, 2022 · 4 comments
Closed

fuzzing in docker performance #18

songxpu opened this issue May 7, 2022 · 4 comments

Comments

@songxpu
Copy link

songxpu commented May 7, 2022

Hi !
I am very sorry that I closed the original issue by mistake

As mentioned in the original link , I have a finding that when I made experimental dockers for afl according to the profuzzbench configuration, when one docker executed the Fuzz task, the speed was 2000/sec; but when 10 dockers were started at the same time to execute the task, the speed dropped to 100/sec for almost every Fuzzer.

Perhaps we'll think of using tmpfs to save Fuzz's output, so I added the mount command to the docker internal run.sh script for requesting tmpfs, and the result is as mentioned above.

For a rigorous comparison, I started afl directly on the real host system and pointed the output all to tmpfs, then executed several at the same time, and they all maintained the highest level of speed, i.e. 2000/sec.
So, I am wondering if the docker internal application tmpfs is not the real tmpfs, and if so, what do we need to do to make the real tmpfs available to fuzzer in docker?

@songxpu
Copy link
Author

songxpu commented May 7, 2022

I created a good tmpfs directory on the physical host and then by mounting it inside the docker container, I found that the speed problem was not solved and it did not seem to be the disk performance that was causing the impact.

The scenario now is that there are 5 AFLs running on the machine, 4 running separately within docker at an average speed of 600/sec, and 1 running directly on the machine at 2400/sec, does anyone know what is causing this?

@songxpu songxpu changed the title how profuzzbench docker use tmpfs ? fuzzing in docker performance May 7, 2022
@songxpu
Copy link
Author

songxpu commented May 7, 2022

I have found the above mentioned problem on several machines

@songxpu
Copy link
Author

songxpu commented May 7, 2022

I seem to have come up with the reason why the sum of the execution speed of each docker in the above phenomenon is equal to the speed of running only one AFL. This is probably because the AFLs running inside the docker at the same time are all tied to the same CPU, which causes the above phenomenon of a very uniform speed drop across the AFLs.

Therefore, I have started multiple AFLs inside a docker, and found that the speed does not drop, they all remain at 2000+, this may belongs to the docker problem, it will affect the AFL family Fuzzer experiment, is there a way to solve it?

@songxpu
Copy link
Author

songxpu commented May 7, 2022

Hi , I seem to have gotten the solution, forcing the bound CPU to be specified via the AFL -b parameter, which solved the problem for now.
The problem I will close in two days, thanks :)

@songxpu songxpu closed this as completed May 10, 2022
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

1 participant