5
0
mirror of git://git.proxmox.com/git/pve-storage.git synced 2025-02-04 17:47:17 +03:00

fix #1099 (again): map cciss/c0d0 to cciss!c0d0

there was still a point where we got the wrong string
on createosd we get the devpath (/dev/cciss/c0d0)

but need the info from get_disks, which looks in /sys/block
where it needs to be cciss!c0d0

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
Dominik Csapak 2017-01-05 11:11:52 +01:00 committed by Dietmar Maurer
parent afd0afe4f5
commit 1590fc13bf

View File

@ -376,6 +376,11 @@ sub get_disks {
my $lvmlist = get_lvm_devices();
# we get cciss/c0d0 but need cciss!c0d0
if (defined($disk) && $disk =~ m|^cciss/|) {
$disk =~ s|cciss/|cciss!|;
}
dir_glob_foreach('/sys/block', '.*', sub {
my ($dev) = @_;
return if defined($disk) && $disk ne $dev;