RedHat systemd configuration
DataStax Enterprise (DSE) versions 6.8.2 and later support installation using systemd for RHEL-based and compatible systems.
The system installs the following units in /usr/lib/systemd/system:
-
dse-all.target: starts DSE nodes -
dse-shutdown.target: stops DSE nodes
The system also installs a dse@.service template in /usr/share/dse/templates. It serves as a template unit for all DSE node instances running on the host OS under the cassandra user.
The dse add-node command and the /usr/share/dse/tools/dse-convert-to-systemd helper script use that template.
Once you enable dse-all.target, the dse add-node command creates and enables systemd service for new nodes, and creates init.d scripts to redirect lifecycle commands to systemctl.
Enable DSE systemd units
By default, systemd units are not enabled.
Previous init.d scripts remain in effect.
|
On systems that have |
-
Stop the DSE
init.dservice:sudo service dse stop -
Enable
dse-all.target:sudo systemctl enable dse-all.targetAfter enabling
dse-all.target, DSE nodes automatically start as part of the multi-user target on each reboot. -
On each node run:
sudo /usr/share/dse/tools/dse-convert-to-systemd full-node-idThe node address,
full-node-id, must be the fully-qualified node ID and include thedse-prefix. The default node ID isdseunless you configure other nodes./usr/share/dse/tools/dse-convert-to-systemd dse-node1The
dse-convert-tosystemdscript makes the following changes:-
Creates and enables
systemdunits for DSE nodes in/etc/systemd/system/. -
Modifies the DSE
init.dscript to redirect lifecycle commands tosystemctl.
-
DSE systemd operations
DSE systemd commands include:
-
Start all DSE nodes:
systemctl start dse-all.target -
Stop all DSE nodes:
systemctl start dse-shutdown.target -
Start one DSE node:
systemctl start full-node-id -
Stop one DSE node:
systemctl stop full-node-id
|
The node address, |
|
The default start timeout is 10 minutes and the default stop timeout is 30 seconds. Adjust these values by editing the corresponding unit files. |