git.annexia.org
/
libguestfs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
e492608
)
Add a comment to device naming heuristic
author
Matthew Booth
<mbooth@redhat.com>
Mon, 29 Jun 2009 13:39:27 +0000
(14:39 +0100)
committer
Matthew Booth
<mbooth@redhat.com>
Mon, 29 Jun 2009 13:39:27 +0000
(14:39 +0100)
inspector/virt-inspector.pl
patch
|
blob
|
history
diff --git
a/inspector/virt-inspector.pl
b/inspector/virt-inspector.pl
index
bd8de70
..
b5d62ae
100755
(executable)
--- a/
inspector/virt-inspector.pl
+++ b/
inspector/virt-inspector.pl
@@
-705,6
+705,12
@@
sub find_filesystem
} else {
return ($_, $fses{$_}) if exists $fses{$_};
} else {
return ($_, $fses{$_}) if exists $fses{$_};
+ # The following is to handle the case where an fstab entry specifies a
+ # specific device rather than its label or uuid, and the libguestfs
+ # appliance has named the device differently due to the use of a
+ # different driver.
+ # This will work as long as the underlying drivers recognise devices in
+ # the same order.
if (m{^/dev/hd(.*)} && exists $fses{"/dev/sd$1"}) {
return ("/dev/sd$1", $fses{"/dev/sd$1"});
}
if (m{^/dev/hd(.*)} && exists $fses{"/dev/sd$1"}) {
return ("/dev/sd$1", $fses{"/dev/sd$1"});
}