Page MenuHomeFreeBSD

bsdinstall: Do not show disks that are already in use when creating a zpool
ClosedPublic

Authored by brd on Feb 4 2022, 2:49 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Nov 17, 5:14 PM
Unknown Object (File)
Fri, Nov 15, 5:29 AM
Unknown Object (File)
Oct 1 2024, 4:58 AM
Unknown Object (File)
Sep 23 2024, 5:18 PM
Unknown Object (File)
Sep 18 2024, 6:42 PM
Unknown Object (File)
Sep 16 2024, 12:01 PM
Unknown Object (File)
Sep 15 2024, 11:58 PM
Unknown Object (File)
Aug 15 2024, 7:55 AM
Subscribers

Details

Summary

Currently zfsboot shows disks that are unavailable to be used, such as the thumbdrive we are installing from, so check if they are open first and exclude them.

Are there any cases that I am missing where a disk would be opened already and this would be a regression?

Test Plan

Test installing in bhyve via cdrom and memstick

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

brd requested review of this revision.Feb 4 2022, 2:49 AM

I can't say for certain whether there will be a regression here, but it seems reasonable to not install to a disk in use.

As a side note, it looks like the same scenario exists for UFS installs, but that looks like a separate change.

This revision is now accepted and ready to land.Feb 8 2022, 9:55 PM

My only concern here is a user not understanding why the disks they know exist are not present in the list.
dialog doesn't really provide a way to present the 'disabled' disks, so I don't know there is much we can do about this.
Since it is likely the commands will fail for the disk that is in use, I think this is fine.

reviewed-by: allanjude