cbeuw / Cloak

A censorship circumvention tool to evade detection by authoritarian state adversaries
GNU General Public License v3.0
3.42k stars 303 forks source link

客户端内存占用问题 #202

Open qwerttvv opened 2 years ago

qwerttvv commented 2 years ago

最近刚刚换了设备,ipq6000处理器,系统x64的openwrt 最新版v2.6.0,在设备内存剩余75m的时候运行ck-client-linux-arm64-v2.6.0直接报out of memery,运行ck-client-linux-arm-v2.6.0正常,跑起来后内存剩余60左右

64位的会占用内存大一些,但现在这样的占用正常吗?剩余70多m的时候直接报oom啊

qwerttvv commented 2 years ago
fatal error: runtime: out of memory

runtime stack:
runtime.throw(0x30af5f, 0x16)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/panic.go:1116 +0x54 fp=0x7fc1d79b90 sp=0x7fc1d79b60 pc=0x40994
runtime.sysMap(0x4000000000, 0x4000000, 0x578518)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/mem_linux.go:169 +0xbc fp=0x7fc1d79bd0 sp=0x7fc1d79b90 pc=0x2639c
runtime.(*mheap).sysAlloc(0x55c560, 0x400000, 0x7fc1d79ce8, 0x3498c)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/malloc.go:727 +0x188 fp=0x7fc1d79c80 sp=0x7fc1d79bd0 pc=0x1b1e8
runtime.(*mheap).grow(0x55c560, 0x1, 0x0)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/mheap.go:1344 +0x80 fp=0x7fc1d79cf0 sp=0x7fc1d79c80 pc=0x34bc0
runtime.(*mheap).allocSpan(0x55c560, 0x1, 0x2a00, 0x578528, 0x0)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/mheap.go:1160 +0x5ec fp=0x7fc1d79d70 sp=0x7fc1d79cf0 pc=0x349bc
runtime.(*mheap).alloc.func1()
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/mheap.go:907 +0x60 fp=0x7fc1d79dd0 sp=0x7fc1d79d70 pc=0x692b0
runtime.(*mheap).alloc(0x55c560, 0x1, 0x7fc1d7012a, 0x25a74)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/mheap.go:901 +0x64 fp=0x7fc1d79e20 sp=0x7fc1d79dd0 pc=0x33fe4
runtime.(*mcentral).grow(0x56f418, 0x0)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/mcentral.go:506 +0x74 fp=0x7fc1d79e70 sp=0x7fc1d79e20 pc=0x25de4
runtime.(*mcentral).cacheSpan(0x56f418, 0x1cb48)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/mcentral.go:177 +0x41c fp=0x7fc1d79f00 sp=0x7fc1d79e70 pc=0x25b3c
runtime.(*mcache).refill(0x7f9b9fa108, 0x2a)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/mcache.go:142 +0xbc fp=0x7fc1d79f30 sp=0x7fc1d79f00 pc=0x2549c
runtime.(*mcache).nextFree(0x7f9b9fa108, 0xffffffffffffff2a, 0x575608, 0x545000, 0x7fc1d79fc8)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/malloc.go:880 +0x8c fp=0x7fc1d79f80 sp=0x7fc1d79f30 pc=0x1b90c
runtime.mallocgc(0x180, 0x303f00, 0x7fc1d7a001, 0x7fc1d7a088)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/malloc.go:1061 +0x6b4 fp=0x7fc1d7a040 sp=0x7fc1d79f80 pc=0x1c154
runtime.newobject(0x303f00, 0x442f8)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/malloc.go:1195 +0x38 fp=0x7fc1d7a070 sp=0x7fc1d7a040 pc=0x1c568
runtime.malg(0x8000, 0x0)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/proc.go:3520 +0x2c fp=0x7fc1d7a0c0 sp=0x7fc1d7a070 pc=0x4b1cc
runtime.mpreinit(0x545000)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/os_linux.go:340 +0x28 fp=0x7fc1d7a0e0 sp=0x7fc1d7a0c0 pc=0x3e0e8
runtime.mcommoninit(0x545000, 0xffffffffffffffff)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/proc.go:663 +0xdc fp=0x7fc1d7a130 sp=0x7fc1d7a0e0 pc=0x4441c
runtime.schedinit()
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/proc.go:565 +0xa4 fp=0x7fc1d7a1a0 sp=0x7fc1d7a130 pc=0x43f74
runtime.rt0_go(0x7fc1d7aec9, 0x0, 0x7fc1d7aed1, 0x7fc1d7aedb, 0x7fc1d7aefe, 0x7fc1d7af06, 0x7fc1d7af11, 0x7fc1d7af1d, 0x7fc1d7af30, 0x7fc1d7af54, ...)
        /opt/hostedtoolcache/go/1.15.15/x64/src/runtime/asm_arm64.s:69 +0xb4 fp=0x7fc1d7a1d0 sp=0x7fc1d7a1a0 pc=0x6ecb4
qwerttvv commented 2 years ago
Name:   ck-client-linux
State:  S (sleeping)
Tgid:   3133
Ngid:   0
Pid:    3133
PPid:   3025
TracerPid:      0
Uid:    0       0       0       0
Gid:    0       0       0       0
FDSize: 1024
Groups:
VmPeak:   800300 kB
VmSize:   800300 kB
VmLck:         0 kB
VmPin:         0 kB
VmHWM:      8496 kB
VmRSS:      8496 kB
VmData:   795260 kB
VmStk:       136 kB
VmExe:      2544 kB
VmLib:         0 kB
VmPTE:        48 kB
VmPMD:         8 kB
VmSwap:        0 kB
Threads:        8
SigQ:   0/609
SigPnd: 0000000000000000
ShdPnd: 0000000000000000
SigBlk: 0000000000000000
SigIgn: 0000000000000002
SigCgt: fffffffe7fc1fefd
CapInh: 0000000000000000
CapPrm: 0000003fffffffff
CapEff: 0000003fffffffff
CapBnd: 0000003fffffffff
CapAmb: 0000000000000000
Cpus_allowed:   f
Cpus_allowed_list:      0-3
voluntary_ctxt_switches:        46415
nonvoluntary_ctxt_switches:     4456

ck-client-linux-arm-v2.6.0的内存情况,这里是不是有什么误会🤣