barnacs / compy

HTTP/HTTPS compression proxy
ISC License
204 stars 34 forks source link

100% CPU load #59

Open hdid opened 4 years ago

hdid commented 4 years ago

Sometimes after heavy loads; one of child processes continues 100% loading and does not come back to normal load! (even if i'm not using it).

eugene-su commented 4 years ago

I confirm this issue. What could be workaround for this unpleasant behavior of such abnormal tasks?

eugene-su commented 4 years ago

My temporary dirty solution is to add next 2 lines in systemd unit:

Restart=always
RuntimeMaxSec=600
gaul commented 4 years ago

Could you get some backtraces to figure out what's going on? This might help:

https://stackoverflow.com/a/27398062

I also have seen high CPU usage but in my case it was external clients who discovered my open proxy and were routing through it. This is why I added HTTP BASIC authentication in #20.

eugene-su commented 4 years ago

@gaul, absolutely only I use my proxy: access to it is available only for local addresses. I can reproduce a case of this bad behavior: 1) open a large image in a separate browser tab (3-5 MB); 2) close this tab without waiting for a full download. After that, the cpu is loaded 100% until you kill the process.