Skip to content

Commit 14ceda4

Browse files
committed
Merge pull request #137 from simonjbeaumont/active-by-default
lvcreate: LVs should be activated by default
2 parents 9b1369a + 1c6c087 commit 14ceda4

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

xenvm/lvcreate.ml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,11 @@ let lvcreate copts lv_name real_size percent_size tags vg_name action =
3535
| e -> fail e
3636
) >>= fun () ->
3737
return info) in
38+
(* Activate the volume by default unless requested otherwise *)
3839
match action with
39-
| Some Xenvm_common.Activate ->
40-
(match info with | Some i -> Lvchange.lvchange_activate copts vg_name lv_name (Some i.local_device) false | None -> ())
41-
| _ -> ()
40+
| Some Xenvm_common.Deactivate -> ()
41+
| _ ->
42+
(match info with Some i -> Lvchange.lvchange_activate copts vg_name lv_name (Some i.local_device) false | None -> ())
4243

4344
let lv_name_arg =
4445
let doc = "Gives the name of the LV to be created. This must be unique within the volume group. " in

0 commit comments

Comments
 (0)