Skip to content

Instantly share code, notes, and snippets.

@supersonictw
Last active November 26, 2024 00:42
Show Gist options
  • Save supersonictw/a9f8b826b2b3cbb03c8a2d688815c11c to your computer and use it in GitHub Desktop.
Save supersonictw/a9f8b826b2b3cbb03c8a2d688815c11c to your computer and use it in GitHub Desktop.
The powerful YugabyteDB systemd files for building bare metal cluster.

YugabyteDB cluster by bare metal

YugabyteDB is a high-performance transactional distributed SQL database.

TODO: add description and usage

--master_addresses=10.0.0.1:7100,10.0.0.2:7100,10.0.0.3:7100
--rpc_bind_addresses=10.0.0.1:7100
--enable_ysql
--ysql_enable_auth=true
--use_cassandra_authentication=true
--fs_data_dirs=/opt/yugabyte/var/data
--certs_dir=/opt/yugabyte/var/certs
--use_node_to_node_encryption=true
--allow_insecure_connections=false
--placement_cloud=mycloud
--placement_region=taiwan
--placement_zone=taipei
--tserver_master_addrs=10.6.0.1:7100,10.6.0.2:7100,10.6.0.3:7100
--rpc_bind_addresses=10.0.0.1:9100
--enable_ysql
--ysql_enable_auth=true
--use_cassandra_authentication=true
--pgsql_proxy_bind_address=10.6.0.1:5433
--cql_proxy_bind_address=10.6.0.1:9042
--fs_data_dirs=/opt/yugabyte/var/data
--certs_dir=/opt/yugabyte/var/certs
--use_node_to_node_encryption=true
--use-client-to-server-encryption=false
--allow_insecure_connections=true
--placement_cloud=mycloud
--placement_region=taiwan
--placement_zone=taipei
[Install]
WantedBy=multi-user.target
[Unit]
Description=YugabyteDB is a high-performance transactional distributed SQL database.
Wants=network-online.target
After=network-online.target
[Service]
Type=simple
Restart=always
RestartSec=5
TimeoutStopSec=300
User=yugabyte
WorkingDirectory=/opt/yugabyte
Environment="FLAGFILE=/opt/yugabyte/var/conf/master.conf"
ExecStart=/opt/yugabyte/bin/yb-master --flagfile "$FLAGFILE"
PermissionsStartOnly=True
TimeoutStartSec=30
LimitCORE=infinity
LimitNOFILE=1048576
LimitNPROC=12000
LimitMEMLOCK=64
[Install]
WantedBy=multi-user.target
[Unit]
Description=YugabyteDB is a high-performance transactional distributed SQL database.
Wants=network-online.target
After=network-online.target
[Service]
Type=simple
Restart=always
RestartSec=5
TimeoutStopSec=300
User=yugabyte
WorkingDirectory=/opt/yugabyte
Environment="FLAGFILE=/opt/yugabyte/var/conf/tserver.conf"
ExecStart=/opt/yugabyte/bin/yb-tserver --flagfile "$FLAGFILE"
PermissionsStartOnly=True
TimeoutStartSec=30
LimitCORE=infinity
LimitNOFILE=1048576
LimitNPROC=12000
LimitMEMLOCK=64
BIND_ADDRESS=0.0.0.0
DATABASE_HOST=10.0.0.1
[Install]
WantedBy=multi-user.target
[Unit]
Description=YugabyteDB is a high-performance transactional distributed SQL database.
Wants=network-online.target
After=network-online.target
[Service]
Type=simple
Restart=always
RestartSec=5
TimeoutStopSec=300
User=yugabyte
WorkingDirectory=/opt/yugabyte
EnvironmentFile=/opt/yugabyte/var/conf/yugabyte-ui.conf
ExecStart=/opt/yugabyte/bin/yugabyted-ui --bind_address "$BIND_ADDRESS" --database_host "$DATABASE_HOST"
PermissionsStartOnly=True
TimeoutStartSec=30
LimitCORE=infinity
LimitNOFILE=1048576
LimitNPROC=12000
LimitMEMLOCK=64
@supersonictw
Copy link
Author

These codes are licensed by SPDX-License-Identifier: MIT.
License: https://ncurl.xyz/s/o_o6DVqIR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment