-
-
Notifications
You must be signed in to change notification settings - Fork 14
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
Periodic high CPU usage #44
Comments
Can you provide a sample of the vhost-proxy logs as they are written during these spikes? EDIT: |
Sure; it's just leaving a cron trail behind every minute (so not as often as the CPU spikes):
|
I was curious because I ran into this issue with vhost-proxy in CI where I had a BAN request being made to a site, but the BAN request was being made to a host that didn't exist in the environment and so vhost-proxy was just churning constantly. I literally couldn't access anything on the container network because vhost-proxy was so bogged down from bad requests. At any rate, I discovered what the issue was by inspecting the logs of vhost-proxy, I was curious if there was anything similar happening in your circumstances. Doesn't look like there is. Not sure what would be going on at this point. I'll leave it to the maintainer crew from here :) |
Yeah it is docker-gen. It's not critical since it's 20-50% on one core, and you have 4 of them (at least), but truly annoying. At the same time it would take a major redesign to change it IMHO https://github.com/docksal/service-vhost-proxy/blob/develop/conf/supervisord.conf#L27 |
If I have 4 cores, I do not necessarily assign all 4 of them to the Docker for Mac/Windows VM but probably 2 or 3. Then, periodically the vhost-proxy service starts to chug on CPU cycles which will probably negatively influence the performance of my other containers (i.e. the applications I'm trying to run with Docksal). So fixing this will not only increase battery lifetime on laptops running Docksal, but will probably also increase other containers' performance. Would it be possible to trigger docker-gen using a signal (TCP/unix socket? Command?) instead of making it "watch" (which I'm guessing is polling instead). |
I don't think there is much we can do with the CPU spikes from Everyone is welcome to brainstorm and through ideas for v2 here: |
Here's a potentially viable stop-gap solution: Please try and report results. |
Looks like that approach won't result in any CPU cycle/Energy consumption savings, but rather will make the load even. After setting |
@lmakarov seems like a good candidate for 1.12.2 if it proves to be working fine |
When the
docksal-vhost-proxy
container is running, the CPU usage is peaking periodically (about every 5 seconds) without any activity on the user's behalf.Easiest way to see this is to start Docksal and run
docker stats
. Thedocksal-vhost-proxy
container should show a CPU usage of about 20%-50% every few seconds.The text was updated successfully, but these errors were encountered: