[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [linux-lvm] Easy way to expend to the maximum length???



> 
> 
> Is there an easy way to expand to the maximum length of a lv?
> I used lvexpand until it wouldn't allow me to continue, but I figure there
> has to be an easy way to simple expand to maximum.
> 

Sorry, no direct support for that with LVM commands today.


But if you have next free allocation policy (as oposed to
contiguous/striped etc.), you can solve your need by

lvextend -l+`vgdisplay YourVG|awk '{if(/^Free PE/){print $3}}'` \
   /dev/YourVG/YourLV

If you put it into a script and do some parameter magic to parse
the VG name etc. -> that's it.

Have to implement an option for that in lvextend ;*)

Regards,
Heinz
--

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Systemmanagement C/S                             Deutsche Telekom AG
                                                 Entwicklungszentrum Darmstadt
Heinz Mauelshagen                                Otto-Roehm-Strasse 71c
Senior Systems Engineer                          Postfach 10 05 41
                                                 64205 Darmstadt
mge ez-darmstadt telekom de                      Germany
                                                 +49 6151 886-425
                                                          FAX-386
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]