Skip to content

Commit 2f455b9

Browse files
committed
cleanup docs for persistent state
1 parent a41a59a commit 2f455b9

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

docs/persistent-state.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,26 @@
11
# Configuration of Persistent State
22

3-
To enable cluster state to persist beyond individual node lifetimes (e.g. to survive a cluster deletion or rebuild) set `appliances_state_dir` to the path of a directory on persistent storage.
3+
To enable cluster state to persist beyond individual node lifetimes (e.g. to survive a cluster deletion or rebuild) set `appliances_state_dir` to the path of a directory on persistent storage, such as an OpenStack volume.
44

5-
At present this will affect the following items:
5+
At present this will affect the following:
66
- `slurmctld` state, i.e. the Slurm queue.
77
- The MySQL database for `slurmdbd`, i.e. Slurm accounting information as shown by the `sacct` command.
88
- Prometheus database
99
- Grafana data
1010
- OpenDistro/elasticsearch data
1111

12-
If using the `environments/common/layout/everything` Ansible groups template (which is the default for a new cookiecutter-produced enviromnent) then these services will all be on the `control` node and hence only this node requires persistent storage.
12+
If using the `environments/common/layout/everything` Ansible groups template (which is the default for a new cookiecutter-produced environment) then these services will all be on the `control` node and hence only this node requires persistent storage.
1313

14-
Note that if `appliances_state_dir` is defined, the path it gives must exist and should be owned by root. Directories will be created within this with appropriate permissions for each item of state defined above.
14+
Note that if `appliances_state_dir` is defined, the path it gives must exist and should be owned by root. Directories will be created within this with appropriate permissions for each item of state defined above. Additionally, the systemd units for the services listed above will be modified to require `appliances_state_dir` to be mounted before service start (via the `systemd` role).
1515

1616
A new cookiecutter-produced environment supports persistent state in the default Terraform (see `environments/skeleton/{{cookiecutter.environment}}/terraform/`) by:
1717

1818
- Defining a volume with a default size of 150GB - this can be controlled by the Terraform variable `state_volume_size`.
1919
- Attaching it to the control node.
20-
- Defining cloud-init userdata for the control node which partitions, formats and mounts this volume to `/var/lib/state`.
21-
- Defining `appliances_state_dir` for the control node in the (Terraform-templated) the `inventory/hosts` file.
20+
- Defining cloud-init userdata for the control node which formats and mounts this volume at `/var/lib/state`.
21+
- Defining `appliances_state_dir: /var/lib/state` for the control node in the (Terraform-templated) `inventory/hosts` file.
2222

23-
**NB: The default Terraform is provided as a working example and for internal CI use - therefore this volume is deleted when running `terraform destroy` - this is probably not suitable for
24-
a production environment.**
23+
**NB: The default Terraform is provided as a working example and for internal CI use - therefore this volume is deleted when running `terraform destroy` - this may not be appropriate for a production environment.**
2524

2625
In general, the Prometheus data is likely to be the only sizeable state stored. The size of this can be influenced through [Prometheus role variables](https://github.com/cloudalchemy/ansible-prometheus#role-variables), e.g.:
2726
- `prometheus_storage_retention` - [default](../environments/common/inventory/group_vars/all/prometheus.yml) 31d

0 commit comments

Comments
 (0)