(Docker) Failed to sufficiently increase receive buffer size

Hi guys,

I encountered this error when using go-ipfs docker image

Failed to sufficiently increase receive buffer size (was: 208 kiB, wanted: 2048 kiB, got: 416 kiB). See https://github.com/lucas-clemente/quic-go/wiki/UDP-Receive-Buffer-Size for details

I tried the solution in the embedded link but nothing changes. I think it is because the container must be configured, not the outside OS.

Have made researches but not found any way to configure this inside Docker container yet.

It would be nice if anyone can share your solution. Really appreciate any help.

In case this may get you moving forward here’s how I was able to pass some custom commands to IPFS docker:

Note the dockerfile-ipfs on line 59. That file is in the same folder.

My other tip is you can just potentially shell into your docker IPFS containner, and run the command line option to set the configuration parameter, and then restart the daemon. Updating config param always requires a restart.

Also there maybe there’s a way to specify a specific config file location on the deamon startup command. I can’t remember if there is. Hope it helps. It’s not a direct answer, but I’m just making sure you know of this way to configure parameters.

Hi @wclayf,

Thanks a lot for the tips. I tried multiple ways (using ways suggested by you as well) to set net.core.rmem_max inside the container but have not succeeded yet :slight_smile:

Some errors I encountered when trying to configure it (putting these here so that anyone encounter the same errors can search for the solution if anyone come up with any idea):

(when trying to set sysctls in docker-compose.yml)

OCI runtime create failed: container_linux.go:349: starting container process caused "process_linux.go:449: container init caused \"write sysctl key net.core.rmem_default: open /proc/sys/net/core/rmem_default: no such file or directory\"": unknown


(when trying to configure from the container's shell)

sysctl: error: 'net.core.rmem_max' is an unknown key

Will give you the update when I’ve found a way.

Thanks a lot.

I guess you already googled “net.core.rmem_max” to see how people set that?

Here’s the other one from this forum:

Yes I have googled for solutions.

And I read the forum post you attached too. However, such solution seems to change the config on the host machine while I prefer a solution to set it within the container while leaving the host machine untouched.

Your host machine and docker container are completely separate full stacks of IPFS, neither of which should know about each other or even share any common folders.

Since they are totally separate, if the solution works for either one, then it works for both…or…just one and not the other too.