Description of problem:
OSPD didn't raise any error or warning when a updating an Overcloud, increasing the number of OSDs from 3 in each node to 11. Each Ceph storage node had only 9 available disk to run OSDs on.
The update ended successfully, though not all of the OSDs that were set in the environment file were active.
The environment file was set with 11 OSDs per node:
When there were only 9 disks available for the OSDs /dev/vdb-/dev/vdj
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Deploy an Overcloud with 3 OSDs on each Ceph storage node
2. Update the Overcloud with a new storage environment file that sets more OSDs that disks in the Ceph storage nodes.
The update of the Overcloud finished successfully.
The update fails with an error that not all of the OSDs were initialized.
We can add a test in puppet-ceph's osd.pp to make it fail if any of the OSDs on the list fail to be activated. Here's an example from another tool:
Users should specify a list of the disks they want which is accurate:
They can use something like the following:
If they have heterogeneous hardware.
So the next step is to look at how this scenario is slipping by the following conditionals:
What you get in this scenario is a working directory-based OSD, not block-based directory as the user intended (and they did intend it if they passed /dev/foo along with a list of other block devices).
[root@osd ~]# ls -laF /dev/sdq
drwxr-xr-x. 3 ceph ceph 220 Feb 17 10:10 ./
drwxr-xr-x. 22 root root 3180 Feb 17 10:10 ../
-rw-r--r--. 1 root root 189 Feb 17 10:10 activate.monmap
-rw-r--r--. 1 ceph ceph 37 Feb 17 10:10 ceph_fsid
drwxr-xr-x. 3 ceph ceph 80 Feb 17 10:10 current/
-rw-r--r--. 1 ceph ceph 37 Feb 17 10:10 fsid
-rw-r--r--. 1 ceph ceph 0 Feb 17 10:10 journal
-rw-r--r--. 1 ceph ceph 21 Feb 17 10:10 magic
-rw-r--r--. 1 ceph ceph 4 Feb 17 10:10 store_version
-rw-r--r--. 1 ceph ceph 53 Feb 17 10:10 superblock
-rw-r--r--. 1 ceph ceph 2 Feb 17 10:10 whoami
There was an update requested on this:
- I have a proposed fix https://review.openstack.org/#/c/435618
- I just need to update the unit test so it can pass CI and merge
- I will get this done before the end of march so I can focus on some higher priority items.
Update: Proposed upstream fix  passed CI and received positive review so far.
https://review.openstack.org/#/c/435618 has merged upstream.
verified on puppet-ceph-2.3.0-4.el7ost.noarch
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.