Bug#717684: Patch

Ken Hahn khahn at engr.wisc.edu
Mon Oct 7 19:31:53 UTC 2013


Hi,

On 10/07/2013 02:19 PM, Thomas Lange wrote:
> Here's the patch, that adds support for LV Path in this library.
> Later I will also adjust setup-storage in FAI.
> 
Not sure if applies, but be aware that the field LV Name changes
depending on the kernel underneath it.. the contents of LV Path used to
be in LV Name, with no equivalent of LV Name existing.

I'm not certain where the point of demarcation is when the switch
occurred.  You may want to chase down that information and populate LV
Path with a copy of LV Name if kernel version is low enough.

That said, I'm not sure if this module should account for the switch, or
if one level up (in the caller) the change in field definition should be
detected and accounted for.

That said, you're doing the work that I don't have a chance to do :)
This is already better than what it was doing.  Thanks!

Cheers,

-Ken Hahn


> 
> --- LVM.pm	2012-02-08 23:51:49.000000000 +0100
> +++ /home/lange/LVM.pm	2013-10-07 21:15:10.935908675 +0200
> @@ -288,9 +288,14 @@
>              $vghash{$vgn}->{uuid} = $1; 
>              next VGINF; }
>  
> +        # Parse the logical path name.
> +        elsif( m/LV Path\s+(\S+)/ ) { 
> +            $lvn = $1; 
> +            $vghash{$vgn}->{lvols}->{$lvn}->{path} = $1; 
> +            next VGINF; }
> +
>          # Parse the logical volume name.
>          elsif( m/LV Name\s+(\S+)/ ) { 
> -            $lvn = $1; 
>              $vghash{$vgn}->{lvols}->{$lvn}->{name} = $1; 
>              next VGINF; }
>  
> 
> 



More information about the pkg-perl-maintainers mailing list