Displaying 11 results from an estimated 11 matches for "primarypartition".
2015 Mar 30
1
[PATCH RFC] resize: add p_mbr_p_type as member of type partition
...t =
| ContentUnknown (* undetermined *)
@@ -73,9 +74,11 @@ and partition_id =
| No_ID (* No identifier. *)
| MBR_ID of int (* MBR ID. *)
| GPT_Type of string (* GPT UUID. *)
-
-type partition_type =
+and partition_type =
| PrimaryPartition
+ | ExtendedPartition
+ | LogicalPartition
+ | NoTypePartition
let rec debug_partition p =
printf "%s:\n" p.p_name;
@@ -99,7 +102,8 @@ let rec debug_partition p =
(match p.p_guid with
| Some guid -> guid
| None -> "(none)"
- )
+ );
+ printf &...
2014 Sep 22
1
Re: [PATCH v3 3/7] resize: add function find_partitions
...s");
> -
> (* Filter out logical partitions. See note above. *)
> let parts =
> + match part_type with
> + (* for GPT, all partitions are regarded as Primary Partition,
> + * e.g. there is no Extended Partition or Logical Partition. *)
> + | PrimaryPartition ->
> List.filter (fun p -> parttype <> MBR || p.G.part_num <= 4_l)
> parts in
>
> @@ -485,11 +486,6 @@ read the man page virt-resize(1).
> p_target_start = 0L; p_target_end = 0L }
> ) parts in
>
> - if verbose then...
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 6/7] resize: add partition type LogicalPartition
...cn.fujitsu.com>
---
resize/resize.ml | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/resize/resize.ml b/resize/resize.ml
index c56a91a..3f804a0 100644
--- a/resize/resize.ml
+++ b/resize/resize.ml
@@ -75,6 +75,7 @@ and partition_id =
type partition_type =
| PrimaryPartition
+ | LogicalPartition
let rec debug_partition p =
eprintf "%s:\n" p.p_name;
@@ -449,13 +450,15 @@ read the man page virt-resize(1).
let find_partitions part_type =
let parts = Array.to_list (g#part_list "/dev/sda") in
- (* Filter out logical partitions. See n...
2014 Sep 26
0
[PATCH v4 1/7] resize: add function find_partitions
...tions(-)
diff --git a/resize/resize.ml b/resize/resize.ml
index 81bb270..cfd02fc 100644
--- a/resize/resize.ml
+++ b/resize/resize.ml
@@ -73,6 +73,9 @@ and partition_id =
| MBR_ID of int (* MBR ID. *)
| GPT_Type of string (* GPT UUID. *)
+type partition_type =
+ | PrimaryPartition
+
let rec debug_partition p =
eprintf "%s:\n" p.p_name;
eprintf "\tpartition data: %ld %Ld-%Ld (%Ld bytes)\n"
@@ -443,14 +446,15 @@ read the man page virt-resize(1).
| MBR_ID _ | GPT_Type _ | No_ID -> false
in
- let partitions : partition list =
+ let find_...
2014 Oct 08
0
[PATCH V5 1/4] resize: add partition type LogicalPartition
...cn.fujitsu.com>
---
resize/resize.ml | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/resize/resize.ml b/resize/resize.ml
index 2090675..cc76aa0 100644
--- a/resize/resize.ml
+++ b/resize/resize.ml
@@ -75,6 +75,7 @@ and partition_id =
type partition_type =
| PrimaryPartition
+ | LogicalPartition
let rec debug_partition p =
eprintf "%s:\n" p.p_name;
@@ -449,13 +450,15 @@ read the man page virt-resize(1).
let find_partitions part_type =
let parts = Array.to_list (g#part_list "/dev/sda") in
- (* Filter out logical partitions. See n...
2014 Sep 22
0
[PATCH v3 3/7] resize: add function find_partitions
...ot;the source disk has no partitions");
-
(* Filter out logical partitions. See note above. *)
let parts =
+ match part_type with
+ (* for GPT, all partitions are regarded as Primary Partition,
+ * e.g. there is no Extended Partition or Logical Partition. *)
+ | PrimaryPartition ->
List.filter (fun p -> parttype <> MBR || p.G.part_num <= 4_l)
parts in
@@ -485,11 +486,6 @@ read the man page virt-resize(1).
p_target_start = 0L; p_target_end = 0L }
) parts in
- if verbose then (
- eprintf "%d partitions fou...
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
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
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