Project

General

Profile

Bug #57609

applying osd service spec with size filter fails if there's tiny (KB-sized) block devices present

Added by Tim Serong 4 months ago. Updated 4 months ago.

Status:
Pending Backport
Priority:
Normal
Assignee:
Category:
-
Target version:
-
% Done:

0%

Source:
Tags:
backport_processed
Backport:
quincy,pacific
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

This issue came up on a system with a 4KB virtual floppy disk drive.

ceph-volume inventory gives:

Device Path               Size         rotates available Model name
/dev/fd0                  4.00 KB      True    False     
/dev/sda                  50.00 GB     True    False     Virtual disk
/dev/sdb                  50.00 GB     True    False     Virtual disk
/dev/sdc                  50.00 GB     True    False     Virtual disk
/dev/sdd                  50.00 GB     True    False     Virtual disk

Doing a simple ceph orch apply osd --all-available-devices works just fine, but service specs utilising size specifiers will fail to apply. For example:

service_id: at_least_8g
service_type: osd
placement:
  host_pattern: '*'
spec:
  data_devices:
    size: '8G:'

Applying the above will give the following error in ceph log last cephadm:

ceph.deployment.drive_group.DriveGroupValidationError: Failed to validate OSD spec "at_least_8g.data_devices": Unit 'KB' not supported

The problem is that the SizeMatcher class only understands MB, GB and TB. When presented with a disk whose size is expressed in KB, it doesn't know what to do with it.


Related issues

Copied to Orchestrator - Backport #57637: quincy: applying osd service spec with size filter fails if there's tiny (KB-sized) block devices present In Progress
Copied to Orchestrator - Backport #57638: pacific: applying osd service spec with size filter fails if there's tiny (KB-sized) block devices present Resolved

History

#1 Updated by Tim Serong 4 months ago

  • Status changed from New to Fix Under Review
  • Pull request ID set to 48184

#2 Updated by Adam King 4 months ago

  • Status changed from Fix Under Review to Pending Backport

#3 Updated by Backport Bot 4 months ago

  • Copied to Backport #57637: quincy: applying osd service spec with size filter fails if there's tiny (KB-sized) block devices present added

#4 Updated by Backport Bot 4 months ago

  • Copied to Backport #57638: pacific: applying osd service spec with size filter fails if there's tiny (KB-sized) block devices present added

#5 Updated by Backport Bot 4 months ago

  • Tags set to backport_processed

Also available in: Atom PDF