cockroachdb / docs

CockroachDB user documentation
https://cockroachlabs.com/docs
Creative Commons Attribution 4.0 International
188 stars 456 forks source link

Update cockroach workload examples when running on multiple nodes #8659

Open dbist opened 4 years ago

dbist commented 4 years ago

Artem Ervits (dbist) commented:

Re: cockroach workload

Issue Description

when workload is being run without a load balancer and using multiple nodes, cockroach will not balance connections against any of the nodes in the url except for the very first address. All postgres urls must be separated by white space and single quotes.

Suggested Resolution

here's a sample that worked for me

./cockroach workload run kv --duration=10m  \
 --read-percent 0  \
 --splits 32  \
 --concurrency 128 \
 'postgres://root@10.12.19.177:26257?sslmode=disable' 'postgres://root@10.12.18.167:26257?sslmode=disable' 'postgres://root@10.12.20.102:26257?sslmode=disable' 'postgres://root@10.12.29.25:26257?sslmode=disable' 'postgres://root@10.12.26.153:26257?sslmode=disable' 'postgres://root@10.12.28.162:26257?sslmode=disable' 'postgres://root@10.12.31.49:26257?sslmode=disable' 'postgres://root@10.12.27.203:26257?sslmode=disable' 'postgres://root@10.12.30.253:26257?sslmode=disable' 'postgres://root@10.12.27.181:26257?sslmode=disable' 'postgres://root@10.12.30.243:26257?sslmode=disable' 'postgres://root@10.12.18.120:26257?sslmode=disable' 'postgres://root@10.12.23.253:26257?sslmode=disable' 'postgres://root@10.12.20.210:26257?sslmode=disable' 'postgres://root@10.12.28.123:26257?sslmode=disable' 'postgres://root@10.12.23.105:26257?sslmode=disable' 'postgres://root@10.12.20.125:26257?sslmode=disable' 'postgres://root@10.12.27.62:26257?sslmode=disable' 'postgres://root@10.12.21.254:26257?sslmode=disable' 'postgres://root@10.12.18.31:26257?sslmode=disable' 'postgres://root@10.12.18.116:26257?sslmode=disable' 'postgres://root@10.12.31.11:26257?sslmode=disable' 'postgres://root@10.12.31.184:26257?sslmode=disable' 'postgres://root@10.12.24.9:26257?sslmode=disable' 'postgres://root@10.12.24.196:26257?sslmode=disable' 'postgres://root@10.12.28.11:26257?sslmode=disable' 'postgres://root@10.12.17.222:26257?sslmode=disable' 'postgres://root@10.12.27.206:26257?sslmode=disable' 'postgres://root@10.12.20.226:26257?sslmode=disable' 'postgres://root@10.12.16.65:26257?sslmode=disable' 'postgres://root@10.12.31.56:26257?sslmode=disable' 'postgres://root@10.12.29.68:26257?sslmode=disable'

if I was just to include 'postgres://root@10.12.31.56:26257,ip2:26257,ip3:26257,,,,?sslmode=disable' load balancing would not occur.

Jira Issue: DOC-801

lnhsingh commented 4 years ago

@ericharmeling I think this falls in your area but feel free to re-route if you think otherwise (I know cockroach demo is in a kind of grey area)

github-actions[bot] commented 1 year ago

We have marked this issue as stale because it has been inactive for 18 months. If this issue is still relevant, removing the stale label or adding a comment will keep it active. Otherwise, we'll close it in 10 days to keep the issue queue tidy. Thank you for your contribution to CockroachDB docs!