Expose and set a default fallocate_reserve value
When swift disks fill up completely it becomes difficult to perform operations since delete operations require a write. By setting this value we can ensure that PUT requests won't happen when the disk space is below the threshold set (in bytes). This will not govern rsyncs, which can still happen to fill up the disks, but assuming a reasonably uniform distribution of data this should help prevent disks from filling up. Change-Id: I753de5e5ed09a21571575ef51c38752edc0730cb Closes-Bug: #1545018
This commit is contained in:
parent
e53ac82f25
commit
81aecda55f
@ -135,6 +135,16 @@ swift_allow_all_users: False
|
||||
# If you want to regenerate the swift keys, on a run, for rsync purposes set this var to True otherwise keys will be generated on the first run and not regenerated each run.
|
||||
swift_recreate_keys: False
|
||||
swift_sorting_method: shuffle
|
||||
# Set the fallocate_reserve value which will reserve space and fail on PUTs above this value in bytes (Default 10GB)
|
||||
swift_fallocate_reserve: 10737418240
|
||||
swift_account_fallocate_reserve: "{{ swift_fallocate_reserve }}"
|
||||
swift_container_fallocate_reserve: "{{ swift_fallocate_reserve }}"
|
||||
swift_object_fallocate_reserve: "{{ swift_fallocate_reserve }}"
|
||||
# Set this to true to disable fallocate
|
||||
swift_disable_fallocate: false
|
||||
swift_account_disable_fallocate: "{{ swift_disable_fallocate }}"
|
||||
swift_container_disable_fallocate: "{{ swift_disable_fallocate }}"
|
||||
swift_object_disable_fallocate: "{{ swift_disable_fallocate }}"
|
||||
|
||||
## Swift ceilometer variables
|
||||
swift_reselleradmin_role: ResellerAdmin
|
||||
|
@ -0,0 +1,8 @@
|
||||
---
|
||||
features:
|
||||
- Allow the fallocate_reserve option to be set (in
|
||||
bytes) for Swift, to help prevent disks from filling
|
||||
up and prevent a situation where Swift is unable to
|
||||
remove objects due to a lack of disk space. The
|
||||
fallocate_reserve value to is set to a default of
|
||||
10GB.
|
@ -13,6 +13,9 @@ devices = {{ swift_vars.mount_point | default(swift.mount_point) }}
|
||||
log_facility = LOG_LOCAL2
|
||||
{% include "statsd.j2" %}
|
||||
|
||||
disable_fallocate = {{ swift_account_disable_fallocate }}
|
||||
fallocate_reserve = {{ swift_account_fallocate_reserve }}
|
||||
|
||||
[pipeline:main]
|
||||
pipeline = healthcheck recon account-server
|
||||
|
||||
|
@ -13,6 +13,9 @@ devices = {{ swift_vars.mount_point | default(swift.mount_point) }}
|
||||
log_facility = LOG_LOCAL3
|
||||
{% include "statsd.j2" %}
|
||||
|
||||
disable_fallocate = {{ swift_container_disable_fallocate }}
|
||||
fallocate_reserve = {{ swift_container_fallocate_reserve }}
|
||||
|
||||
[pipeline:main]
|
||||
pipeline = healthcheck recon container-server
|
||||
|
||||
|
@ -14,6 +14,9 @@ devices = {{ swift_vars.mount_point | default(swift.mount_point) }}
|
||||
log_facility = LOG_LOCAL4
|
||||
{% include "statsd.j2" %}
|
||||
|
||||
disable_fallocate = {{ swift_object_disable_fallocate }}
|
||||
fallocate_reserve = {{ swift_object_fallocate_reserve }}
|
||||
|
||||
[pipeline:main]
|
||||
pipeline = healthcheck recon object-server
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user