Skip to content

Commit 1d94591

Browse files
committed
pool server - don't issue MANY_STORAGE_ISSUES after scaling up (dfbugs 4152) (noobaa#9235)
Signed-off-by: Amit Prinz Setter <[email protected]>
1 parent 4086ec3 commit 1d94591

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/server/system_services/pool_server.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1257,8 +1257,11 @@ function calc_hosts_pool_mode(pool_info, storage_by_mode, s3_by_mode) {
12571257
const storage_count = hosts.by_service.STORAGE;
12581258
const storage_offline = storage_by_mode.OFFLINE || 0;
12591259
const storage_optimal = storage_by_mode.OPTIMAL || 0;
1260+
const storage_low_capacity = storage_by_mode.LOW_CAPACITY || 0;
12601261
const storage_offline_ratio = (storage_offline / host_count) * 100;
1261-
const storage_issues_ratio = ((storage_count - storage_optimal) / storage_count) * 100;
1262+
//don't count individual storage with low capacity as having issues.
1263+
//low capacity is handled for the entire BS by free_ratio check below
1264+
const storage_issues_ratio = ((storage_count - storage_optimal - storage_low_capacity) / storage_count) * 100;
12621265
const hosts_initializing = hosts.by_mode.INITIALIZING || 0;
12631266
const hosts_migrating = (hosts.by_mode.INITIALIZING || 0) + (hosts.by_mode.DECOMMISSIONING || 0) + (hosts.by_mode.MIGRATING || 0);
12641267
const s3_count = hosts.by_service.GATEWAY;

0 commit comments

Comments
 (0)