Hi everyone, I am writing a CLI based golang programme which will run traceroute command for a range of IPs. Sometimes a range will include 63*256*256 ips, which is close to 4 million IPs. Each traceroute runs in a goroutine and then there is a watcher goroutines that acts on the console output from the traceroute. so for each ip 2 goroutines. I have capped the number of goroutines to 512 by creating a buffered channel.
After a lot of trial and error I have had a stable run on an 8GB server with an 8GB swap file, if I run the same programme on a 512MB server with 1GB swap file, it takes the server to peak utilization thereby shutting me out. After which I have to restart my server to gain access again. If I lower the buffered channel size to 100 on the 512MB server it runs fine. Is there a formula of some sort using which I can find out the server size from the number of goroutines or the go programme... cheers, Faizan -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.