New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ceph_disk/main.py: Allow FreeBSD zap a OSD disk #15642

Merged
merged 1 commit into from Jul 5, 2017

Conversation

Projects
None yet
3 participants
@wjwithagen
Contributor

wjwithagen commented Jun 12, 2017

  • FreeBSD only uses GPT partitions at the moment.
    /sbin/gpart dletes both primary and seconday partitions on the disk
    So no need to individually dd-wipe the partitions.

    It will also need PR #15587 to actually detect that a FreeBSD device is a disk

Signed-off-by: Willem Jan Withagen wjw@digiware.nl

@wjwithagen wjwithagen requested a review from Jun 12, 2017

# to make sure that after re-creating the same partition
# there is no trace left of any previous Filesystem or OSD
# Journal
if not FREEBSD:

This comment has been minimized.

@ghost

ghost Jun 12, 2017

could you instead separate this big block in a separate function called zap_linux ? and have another function zap_feebsd. It would be easier to maintain don't you think ?

This comment has been minimized.

@wjwithagen

wjwithagen Jun 12, 2017

Contributor

@dachary
I did sort worry about it, but did not do it in the end.
But I think you are right.

This comment has been minimized.

@ghost

ghost Jun 12, 2017

freebsd has become a first class citizen in ceph-disk, it deserves its name in functions :-)

@@ -1599,12 +1592,41 @@ def zap(dev):
],
)
update_partition(dev, 'zapped')
update_partition(dev, 'zapped')

This comment has been minimized.

@tchaikov

tchaikov Jun 13, 2017

Contributor

i don't think the indent is correct.

@@ -1599,12 +1592,41 @@ def zap(dev):
],
)
update_partition(dev, 'zapped')
update_partition(dev, 'zapped')

This comment has been minimized.

@tchaikov

tchaikov Jun 13, 2017

Contributor

please remove the empty line.

This comment has been minimized.

@wjwithagen
@ghost

ghost approved these changes Jun 13, 2017

@ghost

This comment has been minimized.

ghost commented Jun 13, 2017

approved when @tchaikov comments have been addressed

@wjwithagen wjwithagen added the needs-qa label Jun 15, 2017

@yuriw

This comment has been minimized.

Contributor

yuriw commented Jun 16, 2017

test this please

@tchaikov

This comment has been minimized.

Contributor

tchaikov commented Jun 30, 2017

retest this please.

ceph_disk/main.py: Allow FreeBSD zap a OSD disk
 - refactor zap() into a Linux and FreeBSD version

Signed-off-by: Willem Jan Withagen <wjw@digiware.nl>
@tchaikov

This comment has been minimized.

Contributor

tchaikov commented Jul 5, 2017

retest this please.

@tchaikov tchaikov merged commit b7df96b into ceph:master Jul 5, 2017

4 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodified Submodules submodules for project are unmodified
Details
make check make check succeeded
Details
make check (arm64) make check succeeded
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment