-
I am running a network of libp2p nodes, which use the following protocols:
Notes:
The problem which I have is that the process seems to be using too much memory. The usage grows ~15MB/sec seemingly without any limit (process gets killed by OOM at 10 GB). I've tried adding How can I limit the memory usage of my node to some reasonable value (e.g. 4 GB)? libp2p version: |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 17 replies
-
Thank you for the report! Much appreciated, especially the framegraph. I will take a more in-depth look tomorrow. If you can, in the meantime, are you able to share more code? Also what network topology do you have? Are you connecting to a known network, e.g. IPFS or Ethereum? |
Beta Was this translation helpful? Give feedback.
-
Can you do some investigation with |
Beta Was this translation helpful? Give feedback.
-
@Wiezzel after our call last Friday, any updates? Where you able to find the source for the intermittent bug, i.e. the old messages? |
Beta Was this translation helpful? Give feedback.
I see two solutions:
EnabledHandler
oncesend_queue
reaches a certain size.NetworkBehaviour
andConnectionHandler
and only forward fromNetworkBehaviour
toConnectionHandler
when the latter can handle another message. I.e. drop messages for a specific peer inNetworkBehaviour
instead of as suggested in (1) inConnectionHandler
.