Bug 1619812

Summary: extend ceph-volume to handle LV creation
Product: [Red Hat Storage] Red Hat Ceph Storage Reporter: John Harrigan <jharriga>
Component: Ceph-VolumeAssignee: Sébastien Han <shan>
Status: CLOSED ERRATA QA Contact: Parikshith <pbyregow>
Severity: high Docs Contact: Bara Ancincova <bancinco>
Priority: high    
Version: 3.0CC: adeza, agunn, anharris, aschoen, bengland, ceph-eng-bugs, ceph-qe-bugs, dfuller, gabrioux, gmeno, hnallurv, jbrier, jharriga, kdreyer, mhackett, mmanjuna, nojha, nthomas, pasik, sagrawal, sankarshan, shan
Target Milestone: rc   
Target Release: 3.2   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: RHEL: ceph-12.2.8-2.el7cp Ubuntu: ceph_12.2.8-3redhat1 Doc Type: Enhancement
Doc Text:
.New subcommand: `ceph-volume lvm batch' This update adds the `ceph-volume lvm batch` subcommand that allows creation of volume groups and logical volumes for OSD provisioning from raw disks. The `batch` subcommand makes creating logical volumes easier for users who are not familiar with the Logical Volume Manager (LVM). With `batch`, one or many OSDs can be created by passing an array of devices and an OSD count per device to the `ceph-volume lvm batch` command.
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-01-03 19:01:46 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1629656, 1641792    

Description John Harrigan 2018-08-21 19:26:30 UTC
Description of problem:
currently when using osd_scenario=lvm, users must manually create logical volumes prior to running ceph-ansible for deployment.

for RHCS 3.2 ceph-volume should handle creation of LVs for both bluestore and filestore deployments 

Additional Info:
addressed for filestore in RHCS 3.1 by this ad-hoc playbook 
 bz 1591074  https://bugzilla.redhat.com/show_bug.cgi?id=1591074

Comment 3 Alfredo Deza 2018-08-21 19:35:15 UTC
This is already in ceph-ansible master:

    http://docs.ceph.com/ceph-ansible/master/osds/scenarios.html#lvm

It will require backporting the ceph-volume functionality that currently exists in ceph master back to luminous

Comment 4 John Harrigan 2018-08-21 19:42:23 UTC
(In reply to Alfredo Deza from comment #3)
> This is already in ceph-ansible master:
> 
>     http://docs.ceph.com/ceph-ansible/master/osds/scenarios.html#lvm
> 
> It will require backporting the ceph-volume functionality that currently
> exists in ceph master back to luminous

Hi Alfredo,

Just checking on the upstream capability to create the LVs.
I see this in the URL you provided

> Note
>
> The creation of the logical volumes is not supported by ceph-ansible, 
> ceph-volume only creates OSDs from existing logical volumes.

Comment 5 Alfredo Deza 2018-08-21 19:50:09 UTC
That is a documentation bug in ceph-ansible, it is no longer accurate

Comment 6 Alfredo Deza 2018-08-21 19:57:12 UTC
John could you please clarify if you are looking for bucket index creations or for LVs for OSDs? 

In current master of both ceph-ansible and Ceph, we handle the creation of LVs from an input of devices *to create OSDs*

We do not handle anything for bucket indexes as mentioned in the linked BZ that ended in an ad-hoc ceph-ansible playbook

Comment 7 Neha Ojha 2018-08-21 20:52:00 UTC
Alfredo, what should the changes to osd.yml look something like? Something like this:

osd_objectstore: bluestore                                                      
osd_scenario: lvm                                                               
devices:
- /dev/sdb
- /dev/sdc
- ...

Comment 19 Ken Dreyer (Red Hat) 2018-10-16 23:23:36 UTC
*** Bug 1631729 has been marked as a duplicate of this bug. ***

Comment 23 Alfredo Deza 2018-11-13 12:07:54 UTC
@sagrawal before these changes, it was required that logical volumes be pre-created for ceph-ansible to pass them onto ceph-volume.

These changes allow one to simply use `devices` and the logical volumes will be created (see http://docs.ceph.com/ceph-ansible/master/osds/scenarios.html#lvm )

For example:

osd_scenario: lvm
devices:
  - /dev/sda
  - /dev/sdb

Comment 28 errata-xmlrpc 2019-01-03 19:01:46 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:0020