blob: dd60c53dff7e494cd7295a705383dcbc53eac778 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
|
(* libguestfs generated file
* WARNING: THIS FILE IS GENERATED BY 'src/generator.ml'.
* ANY CHANGES YOU MAKE TO THIS FILE WILL BE LOST.
*
* Copyright (C) 2009 Red Hat Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*)
type t
exception Error of string
external create : unit -> t = "ocaml_guestfs_create"
external close : t -> unit = "ocaml_guestfs_create"
type lvm_pv = {
pv_name : string;
pv_uuid : string;
pv_fmt : string;
pv_size : int64;
dev_size : int64;
pv_free : int64;
pv_used : int64;
pv_attr : string;
pv_pe_count : int64;
pv_pe_alloc_count : int64;
pv_tags : string;
pe_start : int64;
pv_mda_count : int64;
pv_mda_free : int64;
}
type lvm_vg = {
vg_name : string;
vg_uuid : string;
vg_fmt : string;
vg_attr : string;
vg_size : int64;
vg_free : int64;
vg_sysid : string;
vg_extent_size : int64;
vg_extent_count : int64;
vg_free_count : int64;
max_lv : int64;
max_pv : int64;
pv_count : int64;
lv_count : int64;
snap_count : int64;
vg_seqno : int64;
vg_tags : string;
vg_mda_count : int64;
vg_mda_free : int64;
}
type lvm_lv = {
lv_name : string;
lv_uuid : string;
lv_attr : string;
lv_major : int64;
lv_minor : int64;
lv_kernel_major : int64;
lv_kernel_minor : int64;
lv_size : int64;
seg_count : int64;
origin : string;
snap_percent : float option;
copy_percent : float option;
move_pv : string;
lv_tags : string;
mirror_log : string;
modules : string;
}
external launch : t -> unit = "ocaml_guestfs_launch"
external wait_ready : t -> unit = "ocaml_guestfs_wait_ready"
external kill_subprocess : t -> unit = "ocaml_guestfs_kill_subprocess"
external add_drive : t -> string -> unit = "ocaml_guestfs_add_drive"
external add_cdrom : t -> string -> unit = "ocaml_guestfs_add_cdrom"
external config : t -> string -> string option -> unit = "ocaml_guestfs_config"
external set_path : t -> string -> unit = "ocaml_guestfs_set_path"
external get_path : t -> string = "ocaml_guestfs_get_path"
external set_autosync : t -> bool -> unit = "ocaml_guestfs_set_autosync"
external get_autosync : t -> bool = "ocaml_guestfs_get_autosync"
external set_verbose : t -> bool -> unit = "ocaml_guestfs_set_verbose"
external get_verbose : t -> bool = "ocaml_guestfs_get_verbose"
external mount : t -> string -> string -> unit = "ocaml_guestfs_mount"
external sync : t -> unit = "ocaml_guestfs_sync"
external touch : t -> string -> unit = "ocaml_guestfs_touch"
external cat : t -> string -> string = "ocaml_guestfs_cat"
external ll : t -> string -> string = "ocaml_guestfs_ll"
external ls : t -> string -> string list = "ocaml_guestfs_ls"
external list_devices : t -> string list = "ocaml_guestfs_list_devices"
external list_partitions : t -> string list = "ocaml_guestfs_list_partitions"
external pvs : t -> string list = "ocaml_guestfs_pvs"
external vgs : t -> string list = "ocaml_guestfs_vgs"
external lvs : t -> string list = "ocaml_guestfs_lvs"
external pvs_full : t -> lvm_pv list = "ocaml_guestfs_pvs_full"
external vgs_full : t -> lvm_vg list = "ocaml_guestfs_vgs_full"
external lvs_full : t -> lvm_lv list = "ocaml_guestfs_lvs_full"
|