Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

树莓派3b+ ssh 一连就报错 #1

Closed
keac opened this issue Jan 9, 2020 · 10 comments
Closed

树莓派3b+ ssh 一连就报错 #1

keac opened this issue Jan 9, 2020 · 10 comments

Comments

@keac
Copy link

keac commented Jan 9, 2020

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x4 pc=0x12464]

goroutine 34 [running]:
ehang.io/nps/lib/mux.(*ReceiveWindowQueue).Pop(0x21aa0d8, 0x513eb0, 0x216c2d0, 0xe716f753)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/mux/queue.go:254 +0x48
ehang.io/nps/lib/mux.(*ReceiveWindow).readFromQueue(0x21aa0c0, 0x21ca024, 0x4, 0x4, 0x1, 0x26214, 0xa48388, 0x0)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/mux/conn.go:346 +0x230
ehang.io/nps/lib/mux.(*ReceiveWindow).Read(0x21aa0c0, 0x21ca024, 0x4, 0x4, 0x1, 0xa48388, 0x1, 0x32)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/mux/conn.go:329 +0x58
ehang.io/nps/lib/mux.(*conn).Read(0x20fa060, 0x21ca024, 0x4, 0x4, 0x1b3d4, 0x0, 0x76f8cdf8)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/mux/conn.go:63 +0xb0
ehang.io/nps/lib/conn.(*Conn).Read(0x20d80a0, 0x21ca024, 0x4, 0x4, 0x3f888, 0x1309e4, 0x4)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/conn/conn.go:269 +0x128
io.ReadAtLeast(0x6a61a8, 0x20d80a0, 0x21ca024, 0x4, 0x4, 0x4, 0x0, 0x1b8a0, 0x19138)
/home/travis/.gimme/versions/go1.13.linux.amd64/src/io/io.go:310 +0x6c
io.ReadFull(...)
/home/travis/.gimme/versions/go1.13.linux.amd64/src/io/io.go:329
encoding/binary.Read(0x6a61a8, 0x20d80a0, 0x6ad940, 0xa51b50, 0x5167c8, 0x21ca020, 0x6, 0x14)
/home/travis/.gimme/versions/go1.13.linux.amd64/src/encoding/binary/binary.go:165 +0x378
ehang.io/nps/lib/conn.(*Conn).GetLen(...)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/conn/conn.go:101
ehang.io/nps/lib/conn.(*Conn).getInfo(0x20d80a0, 0x50f978, 0x20dc008, 0x0, 0x0)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/conn/conn.go:238 +0x100
ehang.io/nps/lib/conn.(*Conn).GetLinkInfo(...)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/conn/conn.go:148
ehang.io/nps/client.(*TRPClient).handleChan(0x20f6140, 0x6ae030, 0x20fa060)
/home/travis/gopath/src/github.com/ehang-io/nps/client/client.go:169 +0x78
created by ehang.io/nps/client.(*TRPClient).newChan
/home/travis/gopath/src/github.com/ehang-io/nps/client/client.go:164 +0xe8

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots or logs
Add screenshots or logs to help explain your problem.

Server (please complete the following information):

  • OS: [e.g. Centos, Windows]
  • ARCH: [e.g. Amd64, Arm]
  • Tunnel [e.g. TCP, HTTP]
  • Version [e.g. 0.24.0]

Client (please complete the following information):

  • OS: [e.g. Centos, Windows]
  • ARCH: [e.g. Amd64, Arm]
  • Tunnel [e.g. TCP, HTTP]
  • Version [e.g. 0.24.0]

Additional context
Add any other context about the problem here.

@ffdfgdfg
Copy link
Contributor

ffdfgdfg commented Jan 9, 2020

配的tcp隧道访问内网树莓派的ssh端口?
目前我只能判断是网桥连接没有起起来,正常连接上服务器了吗

@keac
Copy link
Author

keac commented Jan 9, 2020

tcp 连接的,连接服务器正常,只要连接vnc 或者 ssh 就炸了

pi@raspberrypi:~/npc $ ./npc -server=xxx.xxx.xxx.xxx:8024 -vkey=xxxxxxxxx -type=tcp
2020/01/09 12:40:40.139 [I] [npc.go:173] the version of client is 0.26.0, the core version of client is 0.26.0
2020/01/09 12:40:40.159 [I] [client.go:67] Successful connection with server xxx.xxx.xxx.xxx:8024
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x4 pc=0x12464]

goroutine 58 [running]:
ehang.io/nps/lib/mux.(*ReceiveWindowQueue).Pop(0x15c8018, 0x513eb0, 0x15b04d0, 0xeb4df3d8)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/mux/queue.go:254 +0x48
ehang.io/nps/lib/mux.(*ReceiveWindow).readFromQueue(0x15c8000, 0x158c3f4, 0x4, 0x4, 0x1, 0x26214, 0xa48388, 0x0)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/mux/conn.go:346 +0x230
ehang.io/nps/lib/mux.(*ReceiveWindow).Read(0x15c8000, 0x158c3f4, 0x4, 0x4, 0x1, 0xa48388, 0x1, 0x32)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/mux/conn.go:329 +0x58
ehang.io/nps/lib/mux.(*conn).Read(0x14ce030, 0x158c3f4, 0x4, 0x4, 0x1b3d4, 0x0, 0x76f3ee48)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/mux/conn.go:63 +0xb0
ehang.io/nps/lib/conn.(*Conn).Read(0x14d06c0, 0x158c3f4, 0x4, 0x4, 0x3f888, 0x1309e4, 0x4)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/conn/conn.go:269 +0x128
io.ReadAtLeast(0x6a61a8, 0x14d06c0, 0x158c3f4, 0x4, 0x4, 0x4, 0x0, 0x1ae20, 0x76f3e4e8)
/home/travis/.gimme/versions/go1.13.linux.amd64/src/io/io.go:310 +0x6c
io.ReadFull(...)
/home/travis/.gimme/versions/go1.13.linux.amd64/src/io/io.go:329
encoding/binary.Read(0x6a61a8, 0x14d06c0, 0x6ad940, 0xa51b50, 0x5167c8, 0x158c3f0, 0x37, 0x14)
/home/travis/.gimme/versions/go1.13.linux.amd64/src/encoding/binary/binary.go:165 +0x378
ehang.io/nps/lib/conn.(*Conn).GetLen(...)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/conn/conn.go:101
ehang.io/nps/lib/conn.(*Conn).getInfo(0x14d06c0, 0x50f978, 0x14e2050, 0x0, 0x0)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/conn/conn.go:238 +0x100
ehang.io/nps/lib/conn.(*Conn).GetLinkInfo(...)
/home/travis/gopath/src/github.com/ehang-io/nps/lib/conn/conn.go:148
ehang.io/nps/client.(*TRPClient).handleChan(0x14cc140, 0x6ae030, 0x14ce030)
/home/travis/gopath/src/github.com/ehang-io/nps/client/client.go:169 +0x78
created by ehang.io/nps/client.(*TRPClient).newChan
/home/travis/gopath/src/github.com/ehang-io/nps/client/client.go:164 +0xe8

@ffdfgdfg
Copy link
Contributor

ffdfgdfg commented Jan 9, 2020

你用的是arm而不是arm64?

@keac
Copy link
Author

keac commented Jan 9, 2020

arm 不是 arm64

@keac
Copy link
Author

keac commented Jan 9, 2020

Linux raspberrypi 4.19.66-v7+ #1253 SMP Thu Aug 15 11:49:46 BST 2019 armv7l GNU/Linux

@ffdfgdfg
Copy link
Contributor

ffdfgdfg commented Jan 9, 2020

疑似是64位校准以及编译器重排导致的一个问题,晚上我改好后能帮忙测测吗

@keac
Copy link
Author

keac commented Jan 9, 2020

可以

@ffdfgdfg ffdfgdfg transferred this issue from ehang-io/nps Jan 9, 2020
@ffdfgdfg
Copy link
Contributor

ffdfgdfg commented Jan 9, 2020

@keac 麻烦再试试,文件已更新,我这边测arm没问题,如果还有的话再详细的说下是armv6还是v7
以及详细的配置

@keac
Copy link
Author

keac commented Jan 10, 2020

没有问题了,非常完美

@ffdfgdfg
Copy link
Contributor

好的感谢反馈

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants