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

net/http: panic at Transport.roundTrip getConn #55127

Open
windzhu0514 opened this issue Sep 18, 2022 · 0 comments
Open

net/http: panic at Transport.roundTrip getConn #55127

windzhu0514 opened this issue Sep 18, 2022 · 0 comments
Labels
NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@windzhu0514
Copy link

windzhu0514 commented Sep 18, 2022

What version of Go are you using (go version)?

$ go version
go version go1.18.3 linux/amd64

Does this issue reproduce with the latest release?

yes

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GO111MODULE="on"
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/centos/.cache/go-build"
GOENV="/home/centos/.config/go/env"
GOEXE=""
GOEXPERIMENT=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE="git.17usoft.com"
GOMODCACHE="/usr/local/golang/gopath/pkg/mod"
GONOPROXY="git.17usoft.com"
GONOSUMDB="git.17usoft.com"
GOOS="linux"
GOPATH="/usr/local/golang/gopath"
GOPRIVATE="git.17usoft.com"
GOPROXY="https://goproxy.cn/"
GOROOT="/usr/local/golang/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/golang/go/pkg/tool/linux_amd64"
GOVCS=""
GOVERSION="go1.18.3"
GCCGO="gccgo"
GOAMD64="v1"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/home/centos/workspace/QOrderPreLoginSvr/go.mod"
GOWORK=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build791289068=/tmp/go-build -gno-record-gcc-switches"

What did you do?

What did you expect to see?

What did you see instead?

program is panic in product env,and generate a linux core dump file,this is dlv core {binary} {core file} ouput

Type 'help' for list of commands.
(dlv) bt
 0  0x000000000046a541 in runtime.raise
    at /usr/local/golang/go/src/runtime/sys_linux_amd64.s:168
 1  0x000000000044e645 in runtime.dieFromSignal
    at /usr/local/golang/go/src/runtime/signal_unix.go:852
 2  0x000000000044f016 in runtime.sigfwdgo
    at /usr/local/golang/go/src/runtime/signal_unix.go:1066
 3  0x000000000044d367 in runtime.sigtrampgo
    at /usr/local/golang/go/src/runtime/signal_unix.go:430
 4  0x000000000046b36e in runtime.sigtrampgo
    at <autogenerated>:1
 5  0x000000000046a81d in runtime.sigtramp
    at /usr/local/golang/go/src/runtime/sys_linux_amd64.s:361
 6  0x00007f2b0e726630 in ???
    at ?:-1
 7  0x0000000000439269 in runtime.crash
    at /usr/local/golang/go/src/runtime/signal_unix.go:944
 8  0x0000000000439269 in runtime.fatalpanic
    at /usr/local/golang/go/src/runtime/panic.go:1092
 9  0x0000000000438a37 in runtime.gopanic
    at /usr/local/golang/go/src/runtime/panic.go:941
10  0x000000000044e516 in runtime.panicmem
    at /usr/local/golang/go/src/runtime/panic.go:220
11  0x000000000044e516 in runtime.sigpanic
    at /usr/local/golang/go/src/runtime/signal_unix.go:818
12  0x00000000007215c0 in net/http.(*Transport).roundTrip
    at /usr/local/golang/go/src/net/http/transport.go:581
13  0x00000000007084f9 in net/http.(*Transport).RoundTrip
    at /usr/local/golang/go/src/net/http/roundtrip.go:17
14  0x00000000006c9e18 in net/http.send
    at /usr/local/golang/go/src/net/http/client.go:252
Sending output to pager...
 0  0x000000000046a541 in runtime.raise
    at /usr/local/golang/go/src/runtime/sys_linux_amd64.s:168
 1  0x000000000044e645 in runtime.dieFromSignal
    at /usr/local/golang/go/src/runtime/signal_unix.go:852
 2  0x000000000044f016 in runtime.sigfwdgo
    at /usr/local/golang/go/src/runtime/signal_unix.go:1066
 3  0x000000000044d367 in runtime.sigtrampgo
    at /usr/local/golang/go/src/runtime/signal_unix.go:430
 4  0x000000000046b36e in runtime.sigtrampgo
    at <autogenerated>:1
 5  0x000000000046a81d in runtime.sigtramp
    at /usr/local/golang/go/src/runtime/sys_linux_amd64.s:361
 6  0x00007f2b0e726630 in ???
    at ?:-1
 7  0x0000000000439269 in runtime.crash
    at /usr/local/golang/go/src/runtime/signal_unix.go:944
 8  0x0000000000439269 in runtime.fatalpanic
    at /usr/local/golang/go/src/runtime/panic.go:1092
 9  0x0000000000438a37 in runtime.gopanic
    at /usr/local/golang/go/src/runtime/panic.go:941
10  0x000000000044e516 in runtime.panicmem
    at /usr/local/golang/go/src/runtime/panic.go:220
11  0x000000000044e516 in runtime.sigpanic
    at /usr/local/golang/go/src/runtime/signal_unix.go:818
12  0x00000000007215c0 in net/http.(*Transport).roundTrip
    at /usr/local/golang/go/src/net/http/transport.go:581
13  0x00000000007084f9 in net/http.(*Transport).RoundTrip
    at /usr/local/golang/go/src/net/http/roundtrip.go:17
14  0x00000000006c9e18 in net/http.send
    at /usr/local/golang/go/src/net/http/client.go:252
15  0x00000000006c96bb in net/http.(*Client).send
15  0x00000000006c96bb in net/http.(*Client).send
    at /usr/local/golang/go/src/net/http/client.go:176
16  0x00000000006cbaf5 in net/http.(*Client).do
    at /usr/local/golang/go/src/net/http/client.go:725
17  0x0000000000a14a57 in net/http.(*Client).Do
    at /usr/local/golang/go/src/net/http/client.go:593
18  0x0000000000a14a57 in github.com/go-kratos/kratos/v2/transport/http.(*Client).do
    at /usr/local/golang/gopath/pkg/mod/github.com/go-kratos/kratos/v2@v2.3.1/transport/http/client.go:288
19  0x0000000000a142f5 in github.com/go-kratos/kratos/v2/transport/http.(*Client).invoke.func1
    at /usr/local/golang/gopath/pkg/mod/github.com/go-kratos/kratos/v2@v2.3.1/transport/http/client.go:234
20  0x0000000000dd003b in git.17usoft.com/go/QOrderPreLoginSvr/pkg/middleware/logging.Client.func1.1
    at /home/centos/workspace/QOrderPreLoginSvr/pkg/middleware/logging/logging.go:96
21  0x0000000000a13fcd in github.com/go-kratos/kratos/v2/transport/http.(*Client).invoke
    at /usr/local/golang/gopath/pkg/mod/github.com/go-kratos/kratos/v2@v2.3.1/transport/http/client.go:253
22  0x0000000000a13cb5 in github.com/go-kratos/kratos/v2/transport/http.(*Client).Invoke
    at /usr/local/golang/gopath/pkg/mod/github.com/go-kratos/kratos/v2@v2.3.1/transport/http/client.go:229
23  0x0000000000a91acb in git.17usoft.com/go/QOrderPreLoginSvr/api/center/v1.(*CenterHTTPClientImpl).GetContactList
    at /home/centos/workspace/QOrderPreLoginSvr/api/center/v1/center_http.pb.go:137
24  0x0000000000ded447 in git.17usoft.com/go/QOrderPreLoginSvr/internal/data.(*PreLoginData).GetContactList
    at /home/centos/workspace/QOrderPreLoginSvr/internal/data/prelogin.go:637
25  0x0000000000ab34fd in git.17usoft.com/go/QOrderPreLoginSvr/internal/biz.(*PreLogin).getContactList
    at /home/centos/workspace/QOrderPreLoginSvr/internal/biz/prelogin.go:535
26  0x0000000000ab61b5 in git.17usoft.com/go/QOrderPreLoginSvr/internal/biz.(*PreLogin).ReportLogin.func1
    at /home/centos/workspace/QOrderPreLoginSvr/internal/biz/prelogin.go:773
27  0x0000000000468be1 in runtime.goexit
    at /usr/local/golang/go/src/runtime/asm_amd64.s:1571

(dlv) frame 12
> runtime.raise() /usr/local/golang/go/src/runtime/sys_linux_amd64.s:168 (PC: 0x46a541)
Warning: debugging optimized function
Frame 12: /usr/local/golang/go/src/net/http/transport.go:581 (PC: 7215c0)
(dlv) locals
ctx = context.Context(*context.valueCtx) 0xbeef000000000008
~R0.data = (unreadable empty OP stack)
~R0.itab = (unreadable empty OP stack)
trace = *net/http/httptrace.ClientTrace nil
scheme = "http"
isHTTP = true
origReq = ("*net/http.Request")(0xc005f28e00)
cancelKey = net/http.cancelKey {req: ("*net/http.Request")(0xc005f28e00)}
~R0 = (unreadable empty OP stack)
treq = ("*net/http.transportRequest")(0xc00668be40)
err = (unreadable could not read 8 bytes from register 3 (size: 0))
cm = net/http.connectMethod {_: net/http.incomparable [], proxyURL: *net/url.URL nil, targetScheme: "http",...+2 more}
@panjf2000 panjf2000 added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Sep 18, 2022
@dmitshur dmitshur added this to the Backlog milestone Sep 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Projects
None yet
Development

No branches or pull requests

3 participants