search for: mbr_part_type

Displaying 20 results from an estimated 22 matches for "mbr_part_type".

2014 Sep 19
1
Re: [PATCH v2 08/13] resize: add function mbr_part_type
On Fri, Sep 19, 2014 at 03:39:10PM +0800, Hu Tao wrote: > Function mbr_part_type returns one of "primary", "extended" and > "logical". The type is used by parted when adding partitions. > > Signed-off-by: Hu Tao <hutao@cn.fujitsu.com> > --- > resize/resize.ml | 12 +++++++++--- > 1 file changed, 9 insertions(+), 3 deletion...
2014 Sep 22
1
Re: [PATCH v3 5/7] resize: add function mbr_part_type
On Mon, Sep 22, 2014 at 03:47:38PM +0800, Hu Tao wrote: > Function mbr_part_type returns one of "primary", "extended" and > "logical". The type is used by parted when adding partitions. > > Signed-off-by: Hu Tao <hutao@cn.fujitsu.com> > --- > resize/resize.ml | 9 ++++++++- > 1 file changed, 8 insertions(+), 1 deletion(-)...
2014 Sep 29
2
Re: [PATCH v4 3/7] resize: add function mbr_part_type
On Fri, Sep 26, 2014 at 11:04:07AM +0800, Hu Tao wrote: > Function mbr_part_type returns one of "primary", "extended" and > "logical". The type is used by parted when adding partitions. > > Signed-off-by: Hu Tao <hutao@cn.fujitsu.com> > --- > resize/resize.ml | 9 ++++++++- > 1 file changed, 8 insertions(+), 1 deletion(-)...
2014 Sep 22
0
[PATCH v3 5/7] resize: add function mbr_part_type
Function mbr_part_type returns one of "primary", "extended" and "logical". The type is used by parted when adding partitions. Signed-off-by: Hu Tao <hutao@cn.fujitsu.com> --- resize/resize.ml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/resize/resize.ml...
2014 Sep 26
0
[PATCH v4 3/7] resize: add function mbr_part_type
Function mbr_part_type returns one of "primary", "extended" and "logical". The type is used by parted when adding partitions. Signed-off-by: Hu Tao <hutao@cn.fujitsu.com> --- resize/resize.ml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/resize/resize.ml...
2014 Sep 29
0
Re: [PATCH v4 3/7] resize: add function mbr_part_type
... and I'm *still* looking at it. Firstly I wrote a test suite (see attached) which randomly generates disk images for virt-resize to test. This reveals a bug in the way we resized the MBR extended partition. The new mbr_part_type function causes virt-resize to fail, but in fact mbr_part_type is *not* to blame - it just exposes the existing bug. Anyway, will continue looking at this tomorrow. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog...
2014 Sep 22
13
[PATCH v3 0/7] add support to resize MBR logical partitions
...end the content of logical partitions 4. refactor to make logical partitions a seperate list Hu Tao (7): resize: introduce partition_type resize: simplify the code to filter parts resize: add function find_partitions resize: add function calculate_target_partitions resize: add function mbr_part_type resize: add partition type LogicalPartition resize: add support to resize logical partitions resize/resize.ml | 145 +++++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 110 insertions(+), 35 deletions(-) -- 1.9.3
2014 Sep 19
22
[PATCH v2 00/13] virt-resize: add support for resizing MBR logical partitions
...3): resize: convert sectsize to int64 add function div_roundup64 resize: introduce partition type resize: introduce filter_part resize: add function find_partition resize: add function print_summmary resize: expose loop to calculate new partitions' positions resize: add function mbr_part_type resize: add function copy_partition resize: add function set_partition_bootable_and_id resize: add function expand_partition_content resize: add partition type LogicalPartition resize: add support to resize logical partitions mllib/common_utils.ml | 1 + mllib/common_utils.mli | 1...
2015 Mar 30
1
[PATCH RFC] resize: add p_mbr_p_type as member of type partition
Add p_mbr_p_type as member of type partition to describe mbr partition type. Currently we use: List.filter (fun p -> parttype <> MBR || p.G.part_num <= 4_l) to filter out logical partitions. Commit 0c396a4bce578486dfc4a38e1f8c47fd5c2836ea introduce API part_get_mbr_part_type, we could use this to know the part_type. Furthermore, we could also use p_mbr_p_type for resizing logical partitions. Signed-off-by: Chen Hanxiao <chenhanxiao@cn.fujitsu.com> --- resize/resize.ml | 47 +++++++++++++++++++++++++++++++---------------- 1 file changed, 31 insertions(+), 16 del...
2014 Oct 30
8
[PATCH v5 REBASE 0/4] virt-resize: add support for resizing logical
...when expanding a logical partition (this problem can be reproduced in v4 by only expanding a logical partition, without resizing any other partitions) 3. update the test script to support logical partitions and extended partition 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 calculate_target_partitions 4. remove the code to restart...
2014 Oct 08
6
[PATCH V5 0/4] virt-resize: add support for resizing logical
...when expanding a logical partition (this problem can be reproduced in v4 by only expanding a logical partition, without resizing any other partitions) 3. update the test script to support logical partitions and extended partition 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 calculate_target_partitions 4. remove the code to restart...
2014 Sep 22
0
[PATCH v3 7/7] resize: add support to resize logical partitions
...(* align logical partitions, too *) + let start = roundup64 (start +^ 1L) alignment in + calculate_target_partitions 5 start ~create_surplus:false logical_partitions in + (* For GPT, the part type simply becomes partition name, so we don't * handle the case specifically. *) let mbr_part_type x = @@ -1109,6 +1163,11 @@ read the man page virt-resize(1). g#part_add "/dev/sdb" (mbr_part_type p) p.p_target_start p.p_target_end ) partitions; + List.iter ( + fun p -> + g#part_add "/dev/sdb" "logical" p.p_target_start p.p_target_end + ) lo...
2014 Oct 08
0
[PATCH V5 2/4] resize: add support to resize logical partitions
...tentExtendedPartition -> total +^ p.p_target_start + | _ -> total +^ 0L + ) 0L partitions in + (* align logical partitions, too *) + let start = roundup64 (start +^ 1L) alignment in + calculate_target_partitions 5 start ~create_surplus:false logical_partitions in + let mbr_part_type x = match parttype, x.p_part.G.part_num <= 4_l, x.p_type with (* for GPT, all partitions are regarded as Primary Partition. *) @@ -1115,6 +1171,11 @@ read the man page virt-resize(1). g#part_add "/dev/sdb" (mbr_part_type p) p.p_target_start p.p_target_end ) partitio...
2014 Jul 15
2
Re: virt-resize: support to MBR logical partitions and some question
Hi Rich, On Wed, Jun 04, 2014 at 10:02:55AM +0100, Richard W.M. Jones wrote: > > On Wed, Jun 04, 2014 at 10:21:41AM +0800, Hu Tao wrote: > > Hi, > > > > I'm adding support to resizing logical partitions(patch is in progess). > > But encounter an error when adding a logical partition in dest image: > > > > virt-resize: libguestfs error: part_add:
2014 Jul 16
2
Re: virt-resize: support to MBR logical partitions and some question
...e 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 `lsof'. Something like this: > > try > g#part_add "/dev/sdb" (mbr_part_type p) p.p_target_start p.p_target_end; > if p.p_type = ContentExtendedPartition then > List.iter ( > fun p -> > g#part_add "/dev/sdb" "logical" p.p_target_start p.p_target_end > ) p.p_partitions > with > G.Error msg -&...
2015 May 14
1
[PATCH] resize: show sector infor in debug_partition
...) @@ -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 are regarded as Primary Partition. *) -- 2.1.0
2014 Oct 21
0
Re: [PATCH V5 0/4] virt-resize: add support for resizing logical
...ition > (this problem can be reproduced in v4 by only expanding a logical partition, without resizing any other partitions) > 3. update the test script to support logical partitions and extended partition > > 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 calculate_target_partitio...
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 calculate_target_partitions 4. remove the code to restart...
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