I have a server written in Go which does not release the consumed memory. I started the program with the GODEBUG=gctrace=1
option and I get the following output:
scvg44: inuse: 1, idle: 423, sys: 425, released: 423, consumed: 1 (MB)
scvg45: inuse: 1, idle: 423, sys: 425, released: 423, consumed: 1 (MB)
...
scvg49: inuse: 1, idle: 423, sys: 425, released: 423, consumed: 1 (MB)
scvg50: inuse: 1, idle: 423, sys: 425, released: 423, consumed: 1 (MB)
So while the output says that 423 MB are released to the OS that seems not to be the case. The program has 423 MB idle memory for hours. Why does the program not release the memory?