[ceph-osd] fix to find empty directory logic
This is to fix the logic to find empty directory which has lost+found folder created by linux filesystem. This is giving problem when linux partition mounted and using it as file backed osd. Change-Id: I11e68a7b9e5df6657d8bf199b8030bc3fc51595e
This commit is contained in:
parent
acb6f6c628
commit
af0b03b69d
@ -30,7 +30,7 @@ if [[ ! -d /var/lib/ceph/osd ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# check if anything is present, if not, create an osd and its directory
|
# check if anything is present, if not, create an osd and its directory
|
||||||
if [[ -n "$(find /var/lib/ceph/osd -prune -empty)" ]]; then
|
if [[ -n "$(find /var/lib/ceph/osd -type d -empty ! -name "lost+found")" ]]; then
|
||||||
echo "Creating osd"
|
echo "Creating osd"
|
||||||
UUID=$(uuidgen)
|
UUID=$(uuidgen)
|
||||||
OSD_SECRET=$(ceph-authtool --gen-print-key)
|
OSD_SECRET=$(ceph-authtool --gen-print-key)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user