Report a Dgraph Bug
What version of Dgraph are you using?
Dgraph Version
$ dgraph version
test git:(master) ✗ ./dgraph version
<jemalloc>: option background_thread currently supports pthread only
<jemalloc>: option background_thread currently supports pthread only
Dgraph version : v21.07.0-g7531e95f9
Dgraph codename : unnamed-mod
Dgraph SHA-256 : 1c62f228998819ed74fd72f3b4abee6e864eb84360e72f08e533f9b67e88b1fc
Commit SHA-1 : 7531e95f9
Commit timestamp : 2021-07-16 13:05:18 -0700
Branch : master
Go version : go1.16.4
jemalloc enabled : true
For Dgraph official documentation, visit https://dgraph.io/docs.
For discussions about Dgraph , visit http://discuss.dgraph.io.
For fully-managed Dgraph Cloud , visit https://dgraph.io/cloud.
Licensed variously under the Apache Public License 2.0 and Dgraph Community License.
Copyright 2015-2021 Dgraph Labs, Inc
Have you tried reproducing the issue with the latest release?
yes , in master branch
What is the hardware spec (RAM, OS)?
CPU Brand: Apple M1
CPU Core Count: 8
CPU Thread Count: 8
Memory:
Memory: 16 GB
Type: LPDDR4
Graphics/Displays:
Chipset Model: Apple M1
Resolution: 2560 x 1600 Retina
Storage:
Media Name: AppleAPFSMedia
Medium Type: SSD
Media Name: AppleAPFSMedia
Medium Type: SSD
Media Name: AppleAPFSMedia
Medium Type: SSD
Steps to reproduce the issue (command/config used to run Dgraph).
step 1: setup dgraph
./dgraph zero
./dgraph alpha
step2: run set mutation
In ratel, run mutation
{
set{
_:a <dgraph.type> "Node" .
_:a <name> "A" .
_:c <dgraph.type> "Node" .
_:c <name> "B" .
_:b <dgraph.type> "Node" .
_:b <name> "B" .
}
}
twice
first time ,it’s okay. second times, it errors.
Expected behaviour and actual result.
no errors
full logs
<jemalloc>: option background_thread currently supports pthread only
<jemalloc>: option background_thread currently supports pthread only
[Sentry] 2021/07/26 10:53:14 Integration installed: ContextifyFrames
[Sentry] 2021/07/26 10:53:14 Integration installed: Environment
[Sentry] 2021/07/26 10:53:14 Integration installed: Modules
[Sentry] 2021/07/26 10:53:14 Integration installed: IgnoreErrors
<jemalloc>: option background_thread currently supports pthread only
<jemalloc>: option background_thread currently supports pthread only
[Sentry] 2021/07/26 10:53:14 Integration installed: ContextifyFrames
[Sentry] 2021/07/26 10:53:14 Integration installed: Environment
[Sentry] 2021/07/26 10:53:14 Integration installed: Modules
[Sentry] 2021/07/26 10:53:14 Integration installed: IgnoreErrors
I0726 10:53:14.217653 50011 sentry_integration.go:48] This instance of Dgraph will send anonymous reports of panics back to Dgraph Labs via Sentry. No confidential information is sent. These reports help improve Dgraph. To opt-out, restart your instance with the --telemetry "sentry=false;" flag. For more info, see https://dgraph.io/docs/howto/#data-handling.
I0726 10:53:14.248068 50011 init.go:110]
Dgraph version : v21.07.0-g7531e95f9
Dgraph codename : unnamed-mod
Dgraph SHA-256 : 1c62f228998819ed74fd72f3b4abee6e864eb84360e72f08e533f9b67e88b1fc
Commit SHA-1 : 7531e95f9
Commit timestamp : 2021-07-16 13:05:18 -0700
Branch : master
Go version : go1.16.4
jemalloc enabled : true
For Dgraph official documentation, visit https://dgraph.io/docs.
For discussions about Dgraph , visit http://discuss.dgraph.io.
For fully-managed Dgraph Cloud , visit https://dgraph.io/cloud.
Licensed variously under the Apache Public License 2.0 and Dgraph Community License.
Copyright 2015-2021 Dgraph Labs, Inc.
I0726 10:53:14.248106 50011 run.go:254] Setting Config to: {raft:0x1400011c530 telemetry:0x1400011c500 limit:0x1400011c538 bindall:true portOffset:0 numReplicas:1 peer: w:zw rebalanceInterval:480000000000 tlsClientConfig:<nil> audit:<nil> limiterConfig:0x14000043e80}
I0726 10:53:14.248124 50011 run.go:144] Setting up grpc listener at: 0.0.0.0:5080
I0726 10:53:14.248228 50011 run.go:144] Setting up http listener at: 0.0.0.0:6080
I0726 10:53:14.248673 50011 storage.go:125] Init Raft Storage with snap: 0, first: 1, last: 0
I0726 10:53:14.248735 50011 node.go:152] Setting raft.Config to: &{ID:1 peers:[] learners:[] ElectionTick:20 HeartbeatTick:1 Storage:0x1400035c500 Applied:0 MaxSizePerMsg:262144 MaxCommittedSizePerReady:67108864 MaxUncommittedEntriesSize:0 MaxInflightMsgs:256 CheckQuorum:false PreVote:true ReadOnlyOption:0 Logger:0x102933f80 DisableProposalForwarding:false}
I0726 10:53:14.248997 50011 node.go:326] Group 0 found 0 entries
I0726 10:53:14.249004 50011 raft.go:662] Starting a brand new node
I0726 10:53:14.249099 50011 log.go:34] 1 became follower at term 0
I0726 10:53:14.249102 50011 log.go:34] newRaft 1 [peers: [], term: 0, commit: 0, applied: 0, lastindex: 0, lastterm: 0]
I0726 10:53:14.249105 50011 log.go:34] 1 became follower at term 1
I0726 10:53:14.249225 50011 run.go:388] Running Dgraph Zero...
I0726 10:53:14.249245 50011 disk_metrics_others.go:12] File system metrics are not currently supported on non-Linux platforms
I0726 10:53:14.249450 50011 node.go:189] Setting conf state to nodes:1
I0726 10:53:14.249520 50011 raft.go:965] Done applying conf change at 0x1
E0726 10:53:14.250385 50011 raft.go:547] While proposing CID: Not Zero leader. Aborting proposal: cid:"efda0bb0-722d-4f13-b89d-9cbac99e1696" . Retrying...
I0726 10:53:16.354367 50011 log.go:34] 1 is starting a new election at term 1
I0726 10:53:16.354410 50011 log.go:34] 1 became pre-candidate at term 1
I0726 10:53:16.354416 50011 log.go:34] 1 received MsgPreVoteResp from 1 at term 1
I0726 10:53:16.354493 50011 log.go:34] 1 became candidate at term 2
I0726 10:53:16.354499 50011 log.go:34] 1 received MsgVoteResp from 1 at term 2
I0726 10:53:16.354533 50011 log.go:34] 1 became leader at term 2
I0726 10:53:16.354545 50011 log.go:34] raft.node: 1 elected leader 1 at term 2
I0726 10:53:16.354623 50011 raft.go:911] I've become the leader, updating leases.
I0726 10:53:16.354708 50011 assign.go:47] Updated UID: 1. Txn Ts: 1. NsID: 1.
E0726 10:53:17.254387 50011 raft.go:547] While proposing CID: Not Zero leader. Aborting proposal: cid:"79538f55-d8ec-4ac1-afae-5fa5d11a72b5" . Retrying...
I0726 10:53:20.254688 50011 raft.go:540] CID set for cluster: 539c36d5-23c5-4918-86b0-14e0aa09073b
I0726 10:53:20.254833 50011 license_ee.go:46] Enterprise trial license proposed to the cluster: license:<maxNodes:18446744073709551615 expiryTs:1629860000 >
I0726 10:53:28.383765 50011 zero.go:447] Got connection request: cluster_info_only:true
I0726 10:53:28.383847 50011 zero.go:472] Connected: cluster_info_only:true
I0726 10:53:28.384738 50011 zero.go:447] Got connection request: addr:"localhost:7080"
I0726 10:53:28.384896 50011 pool.go:164] CONN: Connecting to localhost:7080
I0726 10:53:28.385021 50011 zero.go:612] Connected: id:1 group_id:1 addr:"localhost:7080"
panic: runtime error: index out of range [20] with length 20
goroutine 134 [running]:
github.com/dgraph-io/ristretto/z/simd.Search(0x13b398288, 0x14, 0x800, 0xc014799db7679f58, 0x12ae30000)
/Users/brain/go/pkg/mod/github.com/dgraph-io/ristretto@v0.0.4-0.20210504190834-0bf2acd73aa3/z/simd/search.go:34 +0x1a4
github.com/dgraph-io/ristretto/z.node.search(0x13b398288, 0x800, 0x800, 0xc014799db7679f58, 0x0)
/Users/brain/go/pkg/mod/github.com/dgraph-io/ristretto@v0.0.4-0.20210504190834-0bf2acd73aa3/z/btree.go:586 +0xd4
github.com/dgraph-io/ristretto/z.node.get(0x13b398288, 0x800, 0x800, 0xc014799db7679f58, 0x140027d9768)
/Users/brain/go/pkg/mod/github.com/dgraph-io/ristretto@v0.0.4-0.20210504190834-0bf2acd73aa3/z/btree.go:649 +0x40
github.com/dgraph-io/ristretto/z.(*Tree).get(0x140002c7e30, 0x13b398288, 0x800, 0x800, 0xc014799db7679f58, 0x0)
/Users/brain/go/pkg/mod/github.com/dgraph-io/ristretto@v0.0.4-0.20210504190834-0bf2acd73aa3/z/btree.go:339 +0x1e0
github.com/dgraph-io/ristretto/z.(*Tree).get(0x140002c7e30, 0x13b394288, 0x800, 0x800, 0xc014799db7679f58, 0x0)
/Users/brain/go/pkg/mod/github.com/dgraph-io/ristretto@v0.0.4-0.20210504190834-0bf2acd73aa3/z/btree.go:348 +0x138
github.com/dgraph-io/ristretto/z.(*Tree).Get(0x140002c7e30, 0xc014799db7679f58, 0x24)
/Users/brain/go/pkg/mod/github.com/dgraph-io/ristretto@v0.0.4-0.20210504190834-0bf2acd73aa3/z/btree.go:334 +0x90
github.com/dgraph-io/dgraph/dgraph/cmd/zero.(*Oracle).hasConflict(0x140003e4100, 0x140028f3140, 0x1)
/Users/brain/go/src/github.com/dgraph-io/dgraph/dgraph/cmd/zero/oracle.go:93 +0x16c
github.com/dgraph-io/dgraph/dgraph/cmd/zero.(*Server).commit(0x140004e11e0, 0x101c9ca28, 0x14002caede0, 0x140028f3140, 0x0, 0x0)
/Users/brain/go/src/github.com/dgraph-io/dgraph/dgraph/cmd/zero/oracle.go:360 +0x128
github.com/dgraph-io/dgraph/dgraph/cmd/zero.(*Server).CommitOrAbort(0x140004e11e0, 0x101c9ca28, 0x14002caede0, 0x140028f3140, 0x0, 0x0, 0x0)
/Users/brain/go/src/github.com/dgraph-io/dgraph/dgraph/cmd/zero/oracle.go:438 +0x104
github.com/dgraph-io/dgraph/protos/pb._Zero_CommitOrAbort_Handler.func1(0x101c9ca28, 0x14002caec90, 0x101bc1a60, 0x140028f3140, 0x0, 0x1400290da80, 0x140027d9b18, 0x100cc7990)
/Users/brain/go/src/github.com/dgraph-io/dgraph/protos/pb/pb.pb.go:6481 +0x7c
github.com/dgraph-io/dgraph/ee/audit.AuditRequestGRPC(0x101c9ca28, 0x14002caec90, 0x101bc1a60, 0x140028f3140, 0x1400290dae0, 0x140025abcc8, 0x101b26120, 0x14002caec90, 0x58, 0x101b69f80)
/Users/brain/go/src/github.com/dgraph-io/dgraph/ee/audit/interceptor_ee.go:77 +0x58
github.com/dgraph-io/dgraph/protos/pb._Zero_CommitOrAbort_Handler(0x101c29aa0, 0x140004e11e0, 0x101c9ca28, 0x14002caec90, 0x140028f30e0, 0x101c3eb48, 0x101c9ca28, 0x14002caec90, 0x140027ff600, 0x9f)
/Users/brain/go/src/github.com/dgraph-io/dgraph/protos/pb/pb.pb.go:6483 +0x12c
google.golang.org/grpc.(*Server).processUnaryRPC(0x140003bd500, 0x101cafa38, 0x14000103080, 0x14002caca20, 0x14000388810, 0x1028e81f8, 0x0, 0x0, 0x0)
/Users/brain/go/pkg/mod/google.golang.org/grpc@v1.37.1/server.go:1217 +0x3e8
google.golang.org/grpc.(*Server).handleStream(0x140003bd500, 0x101cafa38, 0x14000103080, 0x14002caca20, 0x0)
/Users/brain/go/pkg/mod/google.golang.org/grpc@v1.37.1/server.go:1540 +0xa50
google.golang.org/grpc.(*Server).serveStreams.func1.2(0x140003e8810, 0x140003bd500, 0x101cafa38, 0x14000103080, 0x14002caca20)
/Users/brain/go/pkg/mod/google.golang.org/grpc@v1.37.1/server.go:878 +0x94
created by google.golang.org/grpc.(*Server).serveStreams.func1
/Users/brain/go/pkg/mod/google.golang.org/grpc@v1.37.1/server.go:876 +0x1f8
W0726 10:53:32.905510 50009 sentry_integration.go:140] unable to read CID from file /var/folders/g1/0ptvctt579q4nzvv98c85hj80000gp/T//dgraph-zero-cid-sentry open /var/folders/g1/0ptvctt579q4nzvv98c85hj80000gp/T//dgraph-zero-cid-sentry: no such file or directory. Skip
[Sentry] 2021/07/26 10:53:32 Sending fatal event [42cb1db038e64580a7960e550c9bb220] to o318308.ingest.sentry.io project: 5208688
[Sentry] 2021/07/26 10:53:33 Buffer flushed successfully.