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

load_cassandra.sh creating errors #82

Open
varunsenthil96 opened this issue Jul 3, 2019 · 2 comments
Open

load_cassandra.sh creating errors #82

varunsenthil96 opened this issue Jul 3, 2019 · 2 comments

Comments

@varunsenthil96
Copy link

varunsenthil96 commented Jul 3, 2019

Upon generating queries, I was able to load it into timescale but kept getting
runtime error: slice bounds out of range error when I try to do that for cassandra that is on the same server.

BATCH_SIZE=1000 BULK_DATA_DIR=/tmp REPLICATION_FACTOR=2 DATABASE_HOST=nosql3. scripts/load_cassandra.sh Bulk loading file /tmp/cassandra-data.gz

and the error that pops up are as follows

` + nc -z nosql3 9042

  • cqlsh -e 'drop keyspace measurements;'
    Connection error: ('Unable to connect to any servers', {'127.0.0.1:9042': error(111, "Tried connecting to [('127.0.0.1', 9042)]. Last error: Connection refused")})
  • cat /tmp/cassandra-data.gz
  • gunzip
  • /home/v5s/go/bin/tsbs_load_cassandra --workers=4 --batch-size=1000 --reporting-period=10s --write-timeout=1000s --hosts=nosql3:9042 --replication-factor=2
    time,per. metric/s,metric total,overall metric/s,per. row/s,row total,overall row/s
    panic: runtime error: slice bounds out of range

goroutine 144 [running]:
main.singleMetricToInsertStatement(0x0, 0x0, 0xb7, 0x0)
/home/v5s/go/src/github.com/timescale/tsbs/cmd/tsbs_load_cassandra/scan.go:41 +0x3b8
main.(*processor).ProcessBatch(0xc420504098, 0x6ef5e0, 0xc4205258e0, 0x1, 0xc420532180, 0x5c8e19)
/home/v5s/go/src/github.com/timescale/tsbs/cmd/tsbs_load_cassandra/main.go:103 +0xa7

github.com/timescale/tsbs/load.(*BenchmarkRunner).work(0x80dc60, 0x6f0a40, 0xc42000e038, 0xc4207bae80, 0xc4204e0930, 0x0)
/home/v5s/go/src/github.com/timescale/tsbs/load/loader.go:253 +0xc6
created by github.com/timescale/tsbs/load.(*BenchmarkRunner).RunBenchmark
/home/v5s/go/src/github.com/timescale/tsbs/load/loader.go:118 +0x16a `

I only edited out the name of the server because of workplace security reasons.

@atanasovskib
Copy link
Contributor

Hello, can you format the output you're getting, from the current output it seams that TSBS shell script couldn't connect Cassandra first?

@varunsenthil96
Copy link
Author

Hey, so the cassandra connection does not seem to be the problem as I was able to run it previously.

BATCH_SIZE=1000 BULK_DATA_DIR=/tmp REPLICATION_FACTOR=2 DATABASE_HOST=armnosql3.ornl.gov scripts/load_cassandra.sh

Bulk loading file /tmp/cassandra-data.gz + nc -z armnosql3.ornl.gov 9042 + cqlsh -e 'drop keyspace measurements;' Connection error: ('Unable to connect to any servers', {'127.0.0.1:9042': error(111, "Tried connecting to [('127.0.0.1', 9042)]. Last error: Connection refused")}) + cat /tmp/cassandra-data.gz + gunzip + /home/v5s/go/bin/tsbs_load_cassandra --workers=4 --batch-size=1000 --reporting-period=10s --write-timeout=1000s --hosts=armnosql3.ornl.gov:9042 --replication-factor=2 time,per. metric/s,metric total,overall metric/s,per. row/s,row total,overall row/s panic: runtime error: slice bounds out of range

goroutine 144 [running]: main.singleMetricToInsertStatement(0x0, 0x0, 0xb7, 0x0) /home/v5s/go/src/github.com/timescale/tsbs/cmd/tsbs_load_cassandra/scan.go:41 +0x3b8 main.(*processor).ProcessBatch(0xc420504098, 0x6ef5e0, 0xc4205258e0, 0x1, 0xc420532180, 0x5c8e19) /home/v5s/go/src/github.com/timescale/tsbs/cmd/tsbs_load_cassandra/main.go:103 +0xa7 github.com/timescale/tsbs/load.(*BenchmarkRunner).work(0x80dc60, 0x6f0a40, 0xc42000e038, 0xc4207bae80, 0xc4204e0930, 0x0) /home/v5s/go/src/github.com/timescale/tsbs/load/loader.go:253 +0xc6 created by github.com/timescale/tsbs/load.(*BenchmarkRunner).RunBenchmark /home/v5s/go/src/github.com/timescale/tsbs/load/loader.go:118 +0x16a

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