Tomáš Golembiovský
2016-Aug-10 22:25 UTC
[Libguestfs] [PATCH] v2v: linux: accept 'sr' devices is fstab
Do not print warning for 'sr' devices when converting fstab. Not all systems create the /dev/cdrom symlink for SCSI CD-ROM devices. Moreover, on systems with multiple CD-ROMs, having entries for /dev/sr* devices may be inevitable. Signed-off-by: Tomáš Golembiovský <tgolembi@redhat.com> --- v2v/convert_linux.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/v2v/convert_linux.ml b/v2v/convert_linux.ml index 06943cd..9bc0271 100644 --- a/v2v/convert_linux.ml +++ b/v2v/convert_linux.ml @@ -1330,7 +1330,7 @@ let rec convert ~keep_serial_console (g : G.guestfs) inspect source rcaps try List.assoc device map with Not_found -> if String.find device "md" = -1 && String.find device "fd" = -1 && - device <> "cdrom" then + String.find device "sr" = -1 && device <> "cdrom" then warning (f_"%s references unknown device \"%s\". You may have to fix this entry manually after conversion.") path device; device -- 2.9.2
Richard W.M. Jones
2016-Aug-11 07:57 UTC
Re: [Libguestfs] [PATCH] v2v: linux: accept 'sr' devices is fstab
On Thu, Aug 11, 2016 at 12:25:53AM +0200, Tomáš Golembiovský wrote:> Do not print warning for 'sr' devices when converting fstab. Not all > systems create the /dev/cdrom symlink for SCSI CD-ROM devices. Moreover, > on systems with multiple CD-ROMs, having entries for /dev/sr* devices > may be inevitable. > > Signed-off-by: Tomáš Golembiovský <tgolembi@redhat.com> > --- > v2v/convert_linux.ml | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/v2v/convert_linux.ml b/v2v/convert_linux.ml > index 06943cd..9bc0271 100644 > --- a/v2v/convert_linux.ml > +++ b/v2v/convert_linux.ml > @@ -1330,7 +1330,7 @@ let rec convert ~keep_serial_console (g : G.guestfs) inspect source rcaps > try List.assoc device map > with Not_found -> > if String.find device "md" = -1 && String.find device "fd" = -1 && > - device <> "cdrom" then > + String.find device "sr" = -1 && device <> "cdrom" then > warning (f_"%s references unknown device \"%s\". You may have to fix this entry manually after conversion.") > path device; > deviceACK, although we should change all those String.find to String.is_prefix. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-top is 'top' for virtual machines. Tiny program with many powerful monitoring features, net stats, disk stats, logging, etc. http://people.redhat.com/~rjones/virt-top
Possibly Parallel Threads
- [PATCH v2] v2v: linux: accept 'sr' devices in fstab
- [PATCH 2/2] v2v: ilnux: detect name of grub2-mkconfig
- [PATCH] v2v: remove MAC address related information
- [PATCH v3 1/2] v2v: linux: correctly reconfigure the initrd on Debian
- [PATCH v4] v2v: linux: correctly reconfigure the initrd on Debian