Hi Sara,
are you using Linux ? Did you check socket buffer default write memory size?
/proc/sys/net/core/wmem_default
where the default is 256k, and
/proc/sys/net/core/wmem_max
where the default is 1m, so socket options that set a socket write buffer size can use values up to 1m.
To change for IPv4, you can modify
/proc/sys/net/ipv4/tcp_wmem
But be careful of huge values like 64m. I do not recommend such extreme values. They are not worth the price because each and every socket might be able to use such large buffer size for each write operation, which wastes a lot of memory, and increases the risk of running out of memory. And, because TCP frames can not exceed 64k (and typical MTU for ethernet is 1500 bytes), there is not much effect. If you care for performance on the Linux kernel and network interface level, you would have to use a Linux network performance tuning guide like /
https://access.redhat.com/sites/default/files/attachments/20150325_network_performance_tuning.pdf
Best,
Jörg