Skip to content

Commit 9bdac0b

Browse files
committed
Add full-ratio storage settings
Fix performance tests Improve forced OSD deletion
1 parent 42b0e2e commit 9bdac0b

24 files changed

Lines changed: 496 additions & 121 deletions

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
tmp/
22
trash/
3+
testing/benchmark/fio/results
34

45
build.log
56
logs/

COMMAND_LIST.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
| [cephos-init-mon](documentation/cephos-init-mon.md) | Initialize Ceph Monitor service |
2828
| [cephos-mkswap](documentation/cephos-mkswap.md) | Create swap space |
2929
| [cephos-prometheus-helper](documentation/cephos-prometheus-helper.md) | Generates scrape configuration file for prometheus |
30+
| [cephos-set-fill-ratios](documentation/cephos-set-fill-ratios.md) | Setup cluster fill ratios |
3031
| [cephos-setup-interface](documentation/cephos-setup-interface.md) | Configure network interfaces |
3132
| [cephos-shutdown-cluster](documentation/cephos-shutdown-cluster.md) | Shutdown and poweroff all cluster nodes |
3233
| [cephos-status](documentation/cephos-status.md) | Check system status |

documentation/cephos-disk-remove.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ The `cephos-disk-remove` script removes a block device (OSD) from a Ceph cluster
1414
cephos-disk-remove -d /dev/sdb
1515
```
1616

17+
## Attention
18+
1. Do not delete several disks in parallel
19+
1. Try not to delete disks while the cluster is actively working.
20+
1721
## Functionality
1822
1. Validates that a block device is specified
1923
1. Checks if the block device exists and is valid
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# cephos-set-fill-ratios
2+
3+
## Description
4+
5+
The `cephos-set-fill-ratios` script is used to configure the fill ratios for a Ceph cluster. It sets three important OSD (Object Storage Daemon) ratios that control when Ceph considers a storage device to be near full, backfill full, or completely full.
6+
7+
## Usage
8+
9+
```bash
10+
cephos-set-fill-ratios -n <ratio> -b <ratio> -f <ratio> [-hv]
11+
```
12+
13+
## Options
14+
15+
- `-n <ratio>`: Set the nearfull-ratio (default: 0.85)
16+
- `-b <ratio>`: Set the backfillfull-ratio (default: 0.9)
17+
- `-f <ratio>`: Set the full-ratio (default: 0.95)
18+
- `-h`: Show this help message and exit
19+
- `-v`: Enable verbose mode
20+
21+
## Ratios Explanation
22+
1. **nearfull-ratio**: When the storage usage reaches this ratio, Ceph will start considering the device as near full. This triggers certain behaviors to prevent the device from becoming completely full. (Default: 0.85)
23+
1. **backfillfull-ratio**: When the storage usage reaches this ratio, Ceph will consider the device as backfill full. This affects backfill operations where data is being moved to balance the cluster. (Default: 0.9)
24+
1. **full-ratio**: When the storage usage reaches this ratio, Ceph will consider the device as completely full. No new data will be written to the device until space is freed up. (Default: 0.95)
25+
26+
## Validation
27+
28+
The script validates that the ratios are set in the correct order:
29+
`nearfull-ratio < backfillfull-ratio < full-ratio`
30+
31+
If the ratios are not in the correct order, the script will display an error and exit.
32+
33+
## Example Usage
34+
35+
```bash
36+
# Set custom ratios
37+
cephos-set-fill-ratios -n 0.80 -b 0.85 -f 0.90
38+
39+
# Show help
40+
cephos-set-fill-ratios -h
41+
42+
# Run with verbose output and set ratios to defaults
43+
cephos-set-fill-ratios -v
44+
```
45+
46+
## Default Values
47+
48+
If no options are provided, the script will use the following default values:
49+
- nearfull-ratio: 0.85
50+
- backfillfull-ratio: 0.9
51+
- full-ratio: 0.95

live_build_config/includes.chroot_after_packages/usr/local/bin/cephos-cephfs-compression

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
. /usr/local/lib/cephos/base.sh.lib
44
. /usr/local/lib/cephos/config.sh.lib
5+
. /usr/local/lib/cephos/ceph.sh.lib
56
. /usr/local/lib/cephos/cephos.sh.lib
67
. /usr/local/lib/cephos/cephfs.sh.lib
78

live_build_config/includes.chroot_after_packages/usr/local/bin/cephos-cephfs-mount-helper

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
. /usr/local/lib/cephos/base.sh.lib
44
. /usr/local/lib/cephos/config.sh.lib
5+
. /usr/local/lib/cephos/ceph.sh.lib
56
. /usr/local/lib/cephos/cephos.sh.lib
67
. /usr/local/lib/cephos/cephfs.sh.lib
78

live_build_config/includes.chroot_after_packages/usr/local/bin/cephos-conf-reconcile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
. /usr/local/lib/cephos/base.sh.lib
44
. /usr/local/lib/cephos/config.sh.lib
5+
. /usr/local/lib/cephos/ceph.sh.lib
56
. /usr/local/lib/cephos/cephos.sh.lib
67
. /usr/local/lib/cephos/network.sh.lib
78

live_build_config/includes.chroot_after_packages/usr/local/bin/cephos-conf-sync

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
. /usr/local/lib/cephos/base.sh.lib
44
. /usr/local/lib/cephos/config.sh.lib
5+
. /usr/local/lib/cephos/ceph.sh.lib
56
. /usr/local/lib/cephos/cephos.sh.lib
67
. /usr/local/lib/cephos/ssh.sh.lib
78

live_build_config/includes.chroot_after_packages/usr/local/bin/cephos-dashboard-user

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
. /usr/local/lib/cephos/base.sh.lib
44
. /usr/local/lib/cephos/config.sh.lib
5+
. /usr/local/lib/cephos/ceph.sh.lib
56
. /usr/local/lib/cephos/cephos.sh.lib
67
. /usr/local/lib/cephos/blockdev.sh.lib
78

live_build_config/includes.chroot_after_packages/usr/local/bin/cephos-disconnect-from-cluster

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
. /usr/local/lib/cephos/base.sh.lib
44
. /usr/local/lib/cephos/config.sh.lib
5+
. /usr/local/lib/cephos/ceph.sh.lib
56
. /usr/local/lib/cephos/cephos.sh.lib
67
. /usr/local/lib/cephos/network.sh.lib
78
. /usr/local/lib/cephos/ssh.sh.lib

0 commit comments

Comments
 (0)