search for: create_surplus

Displaying 20 results from an estimated 21 matches for "create_surplus".

2014 Sep 22
0
[PATCH v3 4/7] resize: add function calculate_target_partitions
And introduce parameter create_surplus to indicate whether to create surplus partition or not. Later this parameter will be used by when calculating positions for target logical partitions. Signed-off-by: Hu Tao <hutao@cn.fujitsu.com> --- resize/resize.ml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff...
2014 Sep 22
13
[PATCH v3 0/7] add support to resize MBR logical partitions
Hi Rich, This is v3 series to add support for resizing MBR logical partitions. changes to v2: 1. remove p_part_num 2. remove filter_parts 3. name the function calculate_target_partitions 4. remove the code to restart guest introduced in v2 changes to v1: 1. spit the patches so it's easier to review 2. fix the parted error caused by unaligned logical partitions 3. extend the
2014 Sep 22
0
[PATCH v3 7/7] resize: add support to resize logical partitions
...quot;\n\n") in List.iter print_summary partitions; + List.iter print_summary logical_partitions; List.iter ( fun ({ lv_name = name } as lv) -> @@ -1030,6 +1070,7 @@ read the man page virt-resize(1). | OpDelete -> calculate_target_partitions partnum start ~create_surplus ps (* skip p *) | OpIgnore | OpCopy -> (* same size *) + let start = roundup64 start 2L in (* Size in sectors. *) let size = div_roundup64 p.p_part.G.part_size sectsize in (* Start of next partition + alignment. *) @@ -1044,6 +1085,7...
2014 Oct 08
0
[PATCH V5 2/4] resize: add support to resize logical partitions
...ndent:4 (text ^ "\n\n") in List.iter print_summary partitions; + List.iter print_summary logical_partitions; List.iter ( fun ({ lv_name = name } as lv) -> @@ -1031,6 +1072,7 @@ read the man page virt-resize(1). calculate_target_partitions partnum start ~create_surplus ps (* skip p *) | OpIgnore | OpCopy -> (* same size *) + let start = roundup64 start 2L in (* Size in sectors. *) let size = div_roundup64 p.p_part.G.part_size sectsize in (* Start of next partition + alignment. *) @@ -1046,6 +1088,7 @@ read...
2014 Sep 19
22
[PATCH v2 00/13] virt-resize: add support for resizing MBR logical partitions
Hi Rich, This is v2 series to add support for resizing MBR logical partitions. I found the reason of problem in v1 that parted reports error when adding logical partitions, is that logical partitions are not aligned to 2 sectors. This problem doesn't appear in v2. This is for early review, because of: 1. I'm not sure the splitting of patches is appropriate or not, but it's much
2015 Jun 03
13
[PATCH v3 00/11] virt-resize: add support for resizing MBR logical partitions
In current virt-resize, only primary partitions(including extended partition) are supported. They are collected in an array for resize operations. Logical partitions are not supported. This series add support for resizing logical partitions. v3: 1) rewrite partitions/logical_partitions/extended_partition section by the comments from Rich and Pino. 2) in 03/11 introduce logical_align for
2015 Jun 17
13
[PATCH v4 00/11] virt-resize: add support for resizing MBR logical partitions
In current virt-resize, only primary partitions(including extended partition) are supported. They are collected in an array for resize operations. Logical partitions are not supported. This series add support for resizing logical partitions. v4: rebase on upstream. v3: 1) rewrite partitions/logical_partitions/extended_partition section by the comments from Rich and Pino. 2) in 03/11
2015 Jul 06
13
[PATCH rebase v4 00/11] virt-resize: add support for resizing MBR logical partitions
In current virt-resize, only primary partitions(including extended partition) are supported. They are collected in an array for resize operations. Logical partitions are not supported. This series add support for resizing logical partitions. v4: rebase on upstream. v3: 1) rewrite partitions/logical_partitions/extended_partition section by the comments from Rich and Pino. 2) in 03/11
2014 Oct 08
6
[PATCH V5 0/4] virt-resize: add support for resizing logical
Hi Rich, This is v5 series to add support for resizing MBR logical partitions. please review. Thanks! changes to v4: 1. add support to resize extended partition (--resize or --expand extended partition) 2. fix the problem of deficit of 512 bytes when expanding a logical partition (this problem can be reproduced in v4 by only expanding a logical partition, without resizing any other
2015 May 20
15
[PATCH v2 00/11] virt-resize: add support for resizing MBR logical partitions
In current virt-resize, only primary partitions(including extended partition) are supported. They are collected in an array for resize operations. Logical partitions are not supported. This series add support for resizing logical partitions. v2: 1) Add 3 variables to describe relationship of logical and extended partitions: - partitions flat list of primary partitions (as now, the global
2014 Jul 16
2
Re: virt-resize: support to MBR logical partitions and some question
On Tue, Jul 15, 2014 at 09:01:47AM +0100, Richard W.M. Jones wrote: > The answer is I don't know. But there are a few things you can try: > > (1) Most importantly, enable tracing (export LIBGUESTFS_TRACE=1) and > get a list of operations that are performed in the order they are > performed. This is vital for debugging this. > > (2) When the error happens, run
2014 Sep 22
1
Re: [PATCH v3 5/7] resize: add function mbr_part_type
...8 insertions(+), 1 deletion(-) > > diff --git a/resize/resize.ml b/resize/resize.ml > index 8b43306..c56a91a 100644 > --- a/resize/resize.ml > +++ b/resize/resize.ml > @@ -1091,10 +1091,17 @@ read the man page virt-resize(1). > > calculate_target_partitions 1 start ~create_surplus:true partitions in > > + (* For GPT, the part type simply becomes partition name, so we don't > + * handle the case specifically. *) > + let mbr_part_type x = > + if x.p_part.G.part_num <= 4l && x.p_type <> ContentExtendedPartition then "primary&quo...
2014 Oct 30
8
[PATCH v5 REBASE 0/4] virt-resize: add support for resizing logical
Hi Rich, This is rebase of v5 series. Meanwhile, I found a bug when shrinking partitions, and the fix is incuded in this version (patch 2). Regards, Hu changes to v4: 1. add support to resize extended partition (--resize or --expand extended partition) 2. fix the problem of deficit of 512 bytes when expanding a logical partition (this problem can be reproduced in v4 by only expanding a
2014 Sep 26
9
[PATCH v4 0/7] virt-resize: add support for resizing logical partitions
Hi Rich, This is v3 series to add support for resizing MBR logical partitions. changes to v3: 1. merge patch 1 and patch 3 in v3 2. let mbr_part_type return 'primary' for GPT partitions 3. add test for resizing logical partitions 4. fix extending the extended partition (yet). see patch 7. changes to v2: 1. remove p_part_num 2. remove filter_parts 3. name the function
2015 May 14
1
[PATCH] resize: show sector infor in debug_partition
...gth partitions); - List.iter debug_partition partitions + List.iter (debug_partition ~sectsize:sectsize) partitions ); (* Build a data structure describing LVs on the source disk. *) @@ -1119,6 +1123,11 @@ read the man page virt-resize(1). calculate_target_partitions 1 start ~create_surplus:true partitions in + if verbose then ( + printf "After calculate target partitions:\n"; + List.iter (debug_partition ~sectsize:sectsize) partitions + ); + let mbr_part_type x = match parttype, x.p_part.G.part_num <= 4_l, x.p_type with (* for GPT, all partitions a...
2014 Sep 22
0
[PATCH v3 5/7] resize: add function mbr_part_type
...resize.ml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/resize/resize.ml b/resize/resize.ml index 8b43306..c56a91a 100644 --- a/resize/resize.ml +++ b/resize/resize.ml @@ -1091,10 +1091,17 @@ read the man page virt-resize(1). calculate_target_partitions 1 start ~create_surplus:true partitions in + (* For GPT, the part type simply becomes partition name, so we don't + * handle the case specifically. *) + let mbr_part_type x = + if x.p_part.G.part_num <= 4l && x.p_type <> ContentExtendedPartition then "primary" + else if x.p_part....
2014 Sep 26
0
[PATCH v4 3/7] resize: add function mbr_part_type
...resize.ml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/resize/resize.ml b/resize/resize.ml index b52af83..f1861d9 100644 --- a/resize/resize.ml +++ b/resize/resize.ml @@ -1094,10 +1094,17 @@ read the man page virt-resize(1). calculate_target_partitions 1 start ~create_surplus:true partitions in + let mbr_part_type x = + (* for GPT, all partitions are regarded as Primary Partition. *) + if parttype = GPT then "primary" + else if x.p_part.G.part_num <= 4l && x.p_type <> ContentExtendedPartition then "primary" + else if x...
2014 Sep 29
2
Re: [PATCH v4 3/7] resize: add function mbr_part_type
...8 insertions(+), 1 deletion(-) > > diff --git a/resize/resize.ml b/resize/resize.ml > index b52af83..f1861d9 100644 > --- a/resize/resize.ml > +++ b/resize/resize.ml > @@ -1094,10 +1094,17 @@ read the man page virt-resize(1). > > calculate_target_partitions 1 start ~create_surplus:true partitions in > > + let mbr_part_type x = > + (* for GPT, all partitions are regarded as Primary Partition. *) > + if parttype = GPT then "primary" > + else if x.p_part.G.part_num <= 4l && x.p_type <> ContentExtendedPartition then "pri...
2015 May 15
0
[PATCH 3/4] ocaml tools: Use global variables to store trace (-x) and verbose (-v) flags.
...- if verbose then + if verbose () then printf "target partition %d: resize: newsize=%Ld start=%Ld end=%Ld\n%!" partnum newsize start (next -^ 1L); @@ -1119,7 +1115,7 @@ read the man page virt-resize(1). calculate_target_partitions 1 start ~create_surplus:true partitions in - if verbose then ( + if verbose () then ( printf "After calculate target partitions:\n"; List.iter (debug_partition ~sectsize) partitions ); @@ -1232,7 +1228,7 @@ read the man page virt-resize(1). else ( msg (f_"Fixing first NTFS p...
2015 May 15
5
[PATCH 0/4] Only tell people to use -v -x when reporting bugs if they're not using those flags.
.. and a lot of refactoring. https://bugzilla.redhat.com/show_bug.cgi?id=1167623 Rich.