-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[DOC-574][ysql] update benchmark doc - sysbench page #25194
Open
sudhanshu456
wants to merge
7
commits into
yugabyte:master
Choose a base branch
from
sudhanshu456:doc-574-sysbench
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+79
−42
Open
Changes from 6 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
ca17194
update sysbench docs, add alternative options for sysbench install
sudhanshu456 98550a8
remove latest release text
sudhanshu456 c9ad912
use inline content instead of separate files
sudhanshu456 3212267
correct the alignment of slashes
sudhanshu456 ddf1389
Merge branch 'master' into doc-574-sysbench
sudhanshu456 8f633e0
shift the sysbench result per release version
sudhanshu456 6259357
minor edit
ddhodge File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,6 +20,36 @@ sysbench is a popular tool for benchmarking databases like PostgreSQL and MySQL, | |
|
||
To ensure the recommended hardware requirements are met and the database is correctly configured before benchmarking, review the [deployment checklist](../../deploy/checklist/). | ||
|
||
### Install sysbench | ||
|
||
Install sysbench on a machine which satisfies the Prerequisites using one of | ||
the following options: | ||
|
||
<ul class="nav nav-tabs nav-tabs-yb"> | ||
<li> | ||
<a href="#github" class="nav-link active" id="github-tab" data-bs-toggle="tab" role="tab" aria-controls="github" aria-selected="true"> | ||
<i class="fab fa-github" aria-hidden="true"></i> | ||
Source | ||
</a> | ||
</li> | ||
<li> | ||
<a href="#rhel" class="nav-link" id="rhel-tab" data-bs-toggle="tab" role="tab" aria-controls="rhel" aria-selected="true"> | ||
<i class="fa-brands fa-redhat" aria-hidden="true"></i> | ||
RHEL | ||
</a> | ||
</li> | ||
<li > | ||
<a href="#macos" class="nav-link" id="macos-tab" data-bs-toggle="tab" role="tab" aria-controls="macos" aria-selected="true"> | ||
<i class="fa-brands fa-apple" aria-hidden="true"></i> | ||
macOS | ||
</a> | ||
</li> | ||
|
||
</ul> | ||
|
||
<div class="tab-content"> | ||
<div id="github" class="tab-pane fade show active" role="tabpanel" aria-labelledby="github-tab"> | ||
|
||
Install sysbench using the following steps: | ||
|
||
```sh | ||
|
@@ -37,55 +67,63 @@ Make sure you have the [YSQL shell](../../api/ysqlsh/) `ysqlsh` exported to the | |
$ export PATH=$PATH:/path/to/ysqlsh | ||
``` | ||
|
||
### Start YugabyteDB | ||
</div> | ||
|
||
Start your YugabyteDB cluster by following the steps in [Manual deployment](../../deploy/manual-deployment/). | ||
<div id="rhel" class="tab-pane fade" role="tabpanel" aria-labelledby="rhel-tab"> | ||
|
||
{{< tip title="Tip" >}} | ||
You will need the IP addresses of the nodes in the cluster for the next step. | ||
{{< /tip>}} | ||
```sh | ||
wget https://github.com/yugabyte/sysbench/releases/download/1.0.0-yb/sysbench-1.0.0-1.el8.x86_64.rpm | ||
|
||
### Run the benchmark | ||
sudo yum install -y sysbench-1.0.0-1.el8.x86_64.rpm | ||
``` | ||
|
||
Run the `run_sysbench.sh` shell script to load the data and run the various workloads: | ||
</div> | ||
<div id="macos" class="tab-pane fade" role="tabpanel" aria-labelledby="macos-tab"> | ||
|
||
```sh | ||
./run_sysbench.sh --ip <ip> | ||
brew install postgresql@14 wget | ||
|
||
wget https://github.com/yugabyte/sysbench/releases/download/1.0.0-yb/Sysbench.pkg | ||
|
||
sudo installer -pkg Sysbench.pkg -target / | ||
``` | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. where is sysbench installed? |
||
This script runs all 8 workloads using 64 threads with the number of tables as 10 and the table size as 100k. | ||
</div> | ||
|
||
If you want to run the benchmark with a different count of tables and tablesize, do the following: | ||
</div> | ||
|
||
```sh | ||
./run_sysbench.sh --ip <ip> --numtables <number of tables> --tablesize <number of rows in each table> | ||
``` | ||
### Start YugabyteDB | ||
|
||
### Run individual workloads (optional) | ||
Start your YugabyteDB cluster by following the steps in [Manual deployment](../../deploy/manual-deployment/). | ||
|
||
{{< tip title="Tip" >}} | ||
You will need the IP addresses of the nodes in the cluster for the next step. | ||
{{< /tip>}} | ||
|
||
### Run individual workloads | ||
|
||
You can choose to run the following workloads individually: | ||
|
||
* oltp_insert | ||
* oltp_point_select | ||
* oltp_write_only | ||
* oltp_read_only | ||
* oltp_read_write | ||
* oltp_multi_insert | ||
* oltp_update_index | ||
* oltp_update_non_index | ||
* oltp_delete | ||
|
||
|
||
Before starting the workload, load the data as follows: | ||
|
||
```sh | ||
$ sysbench <workload> \ | ||
--tables=10 \ | ||
--table-size=100000 \ | ||
--range_key_partitioning=true \ | ||
--db-driver=pgsql \ | ||
--pgsql-host=127.0.0.1 \ | ||
--pgsql-port=5433 \ | ||
--pgsql-user=yugabyte \ | ||
--pgsql-db=yugabyte \ | ||
$ sysbench <workload> \ | ||
--tables=10 \ | ||
--table-size=100000 \ | ||
--range_key_partitioning=true \ | ||
--db-driver=pgsql \ | ||
--pgsql-host=<comma-separated-ips> \ | ||
--pgsql-port=5433 \ | ||
--pgsql-user=yugabyte \ | ||
--pgsql-db=yugabyte \ | ||
prepare | ||
``` | ||
|
||
|
@@ -109,17 +147,15 @@ $ sysbench <workload> \ | |
|
||
## Expected results | ||
|
||
The following results are for a 3-node cluster with each node on a c5.4xlarge AWS instance (16 cores, 32 GB of RAM, and 2 EBS volumes), all in the same AZ with the client VM running in the same AZ. | ||
The following results are for a 3-node cluster, with each node running on a c5.2xlarge AWS instance (8 cores, 16 GiB of RAM), all in the same AZ, with a replication factor of 3 and TLS enabled. | ||
|
||
### 10 tables each with 100k rows | ||
|
||
| Workload | Throughput (txns/sec) | Latency (ms) | | ||
| :-------------------- | :-------------------- | :----------- | | ||
| OLTP_READ_ONLY | 3276 | 39 | | ||
| OLTP_READ_WRITE | 487 | 265 | | ||
| OLTP_WRITE_ONLY | 1818 | 70 | | ||
| OLTP_POINT_SELECT | 95695 | 1.3 | | ||
| OLTP_INSERT | 6348 | 20.1 | | ||
| OLTP_UPDATE_INDEX | 4052 | 31 | | ||
| OLTP_UPDATE_NON_INDEX | 11496 | 11 | | ||
| OLTP_DELETE | 67499 | 1.9 | | ||
| Workload | Throughput(txns/sec) | Latency(ms) | | ||
| --------------------- | -------------------- | ----------- | | ||
| oltp_read_only | 36150 | 1.6 | | ||
| oltp_read_write | 2150 | 11.1 | | ||
| oltp_multi_insert | 5450 | 4.4 | | ||
| oltp_update_index | 2420 | 9.8 | | ||
| oltp_update_non_index | | | | ||
| oltp_delete | | | |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where is sysbench installed?