我在 go 中安装了 vnc 应用程序,问题是在同时执行崩溃后,出现内存不足的消息。
完整的日志在这里:https://ghostbin.com/paste/3wpcm
client.go完整代码哪里有这个错误是这样的:https://ghostbin.com/paste/bgn7s
有谁知道为什么这个应用程序内存不足?我的 Linux 机器有 16gb 内存。
最佳答案
Profile memory usage你的程序:
Memory profiler shows what functions allocate heap memory. You can collect it in similar ways as CPU profile: with
go test --memprofile
(http://golang.org/cmd/go/#hdr-Description_of_testing_flags), withnet/http/pprof
via http://myserver:6060:/debug/pprof/heap or by callingruntime/pprof.WriteHeapProfile
.<…>
关于golang vnc连接错误-内存不足,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50718652/