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

Segfault on startup #2138

Closed
aphyr opened this Issue Feb 18, 2018 · 1 comment

Comments

Projects
None yet
3 participants
@aphyr
Copy link

aphyr commented Feb 18, 2018

On 1.0.3 and the current nightly (2018/02/17), dgraph alpha can segfault shortly after cluster startup when nodes are started concurrently. Here are complete cluster logs; node n5 crashed.

2018-02-17 12:28:28 Jepsen starting dgraph :server :--memory_mb 1024 :--idx 5 :--my n5:7080 :--zero n5:5080
2018/02/17 12:28:28 groups.go:86: Current Raft Id: 5
2018/02/17 12:28:28 gRPC server started.  Listening on port 9080
2018/02/17 12:28:28 HTTP server started.  Listening on port 8080
2018/02/17 12:28:28 worker.go:99: Worker listening at address: [::]:7080
2018/02/17 12:28:28 pool.go:118: == CONNECT ==> Setting n5:5080
2018/02/17 12:28:28 groups.go:109: Connected to group zero. Connection state: member:<id:5 group_id:1 addr:"n5:7080" > state:<counter:13 groups:<key:1 value:<members:<key:5 value:<id:5 group_id:1 addr:"n5:7080" > > > > zeros:<key:1 value:<id:1 addr:"n1:5080" leader:true > > zeros:<key:5 value:<id:5 addr:"n5:5080" > > > 
2018/02/17 12:28:28 pool.go:118: == CONNECT ==> Setting n1:5080
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x109788a]

goroutine 243 [running]:
github.com/dgraph-io/dgraph/worker.(*node).AmLeader(0x0, 0x1)
	/home/travis/gopath/src/github.com/dgraph-io/dgraph/worker/draft.go:697 +0x3a
github.com/dgraph-io/dgraph/worker.(*grpcWorker).PredicateAndSchemaData(0xc4201c8180, 0xc4200be900, 0x1a1bf60, 0xc4202da330, 0x0, 0x0)
	/home/travis/gopath/src/github.com/dgraph-io/dgraph/worker/predicate.go:220 +0x737
github.com/dgraph-io/dgraph/protos/intern._Worker_PredicateAndSchemaData_Handler(0x12ac480, 0xc4201c8180, 0x1a1b240, 0xc4202cc320, 0x0, 0x0)
	/home/travis/gopath/src/github.com/dgraph-io/dgraph/protos/intern/internal.pb.go:2553 +0x10e
google.golang.org/grpc.(*Server).processStreamingRPC(0xc4257faf00, 0x1a1c500, 0xc42acce180, 0xc42ace6500, 0xc420258c60, 0x1a01180, 0x0, 0x0, 0x0)
	/home/travis/gopath/src/google.golang.org/grpc/server.go:1032 +0xa3e
google.golang.org/grpc.(*Server).handleStream(0xc4257faf00, 0x1a1c500, 0xc42acce180, 0xc42ace6500, 0x0)
	/home/travis/gopath/src/google.golang.org/grpc/server.go:1126 +0x14c1
google.golang.org/grpc.(*Server).serveStreams.func1.1(0xc4257aa160, 0xc4257faf00, 0x1a1c500, 0xc42acce180, 0xc42ace6500)
	/home/travis/gopath/src/google.golang.org/grpc/server.go:617 +0x9f
created by google.golang.org/grpc.(*Server).serveStreams.func1
	/home/travis/gopath/src/google.golang.org/grpc/server.go:615 +0xa1
@aphyr

This comment has been minimized.

Copy link
Author

aphyr commented Mar 6, 2018

Woo! :)

@manishrjain manishrjain added the bug label Mar 21, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.