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

Fairly high resource usage #186

Open
r-vdp opened this issue Mar 29, 2024 · 6 comments
Open

Fairly high resource usage #186

r-vdp opened this issue Mar 29, 2024 · 6 comments

Comments

@r-vdp
Copy link
Contributor

r-vdp commented Mar 29, 2024

I deployed mycelium on three machines and on each of them I see regular (every couple of seconds) CPU spikes.
My router which is usually consistently at 0.00 load, even while routing all network traffic, sits consistently at 0.20 load when running mycelium without any active mycelium connections.

Is this to be expected? Do you have any idea what would be causing the high resource usage?

@LeeSmet
Copy link
Contributor

LeeSmet commented Mar 29, 2024

In general that is not expected behavior if no traffic is coming through. What is the setup of your nodes? Also could you share some logs from the nodes, especially around the time of these spikes?

@r-vdp
Copy link
Contributor Author

r-vdp commented Apr 6, 2024

This seems to have gotten better with the latest release, so I'll close this for now. Thanks!

@r-vdp r-vdp closed this as completed Apr 6, 2024
@r-vdp r-vdp reopened this May 5, 2024
@r-vdp
Copy link
Contributor Author

r-vdp commented May 5, 2024

I'm reopening this issue since I'm noticing this again on the latest release. I see very regular CPU spikes, often up to 80%, that last for a couple of seconds.

I will try tomorrow to correlate them to any specific output in the debug logs.
Alternatively I might look into profiling options to see where this comes from.

I have a suspicion that it might be related to neighbour discovery, since the issue was not there when I was running the versions where the multicast probes were sent out on the wrong interface (and so neighbour discovery was not working on those versions).

@LeeSmet
Copy link
Contributor

LeeSmet commented May 7, 2024

Is this still going on right now? We shut down one of the public nodes yesterday, and after that the other nodes we monitor suggest there is quite a bit less protocol traffic in the network. I wonder if that is related.

@r-vdp
Copy link
Contributor Author

r-vdp commented May 7, 2024

Yeah it looks a lot better now. Still some mild CPU spikes, but not nearly as bad as before. We're talking 10% on a core now compared to 80%+ over the weekend.

I noticed with tcpdump over the weekend that there were a lot of packets being sent over the mycelium port, and a lot of them having length 0. I didn't have the time to look into it in more detail though. I'm just mentioning it in case it's useful info to you.

@LeeSmet
Copy link
Contributor

LeeSmet commented May 7, 2024

Thanks for the info. I'll check the packet length in tcpdump when I get around to it, I'm guessing its related to the tcp/quic connection layer (there are no explicit 0 length sends in the code)

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