search for: is_read_only_lv

Displaying 15 results from an estimated 15 matches for "is_read_only_lv".

2015 Jan 28
1
Re: [PATCH 3/3] sparsify: Ignore read-only LVs (RHBZ#1185561).
...x 8d77964..165dd6e 100644 > --- a/sparsify/copying.ml > +++ b/sparsify/copying.ml > @@ -216,9 +216,11 @@ You can ignore this warning or change it to a hard failure using the > List.exists (fun fs' -> fs = g#canonical_device_name fs') ignores > in > > + let is_read_only_lv = is_read_only_lv g in > + > List.iter ( > fun fs -> > - if not (is_ignored fs) then ( > + if not (is_ignored fs) && not (is_read_only_lv fs) then ( > if List.mem fs zeroes then ( > if not quiet then > printf (f_&...
2015 Jan 28
4
[PATCH 0/3] sparsify: Ignore read-only LVs (RHBZ#1185561).
virt-sparsify shouldn't die if sparsifying a filesystem that contains read-only LVs. https://bugzilla.redhat.com/show_bug.cgi?id=1185561 I thought about trying to make the LV writable temporarily, but I suspect that if the sysadmin has made the LV read-only, then they probably did it for a reason, so we shouldn't touch it. Rich.
2015 Jan 28
0
[PATCH 3/3] sparsify: Ignore read-only LVs (RHBZ#1185561).
...pying.ml b/sparsify/copying.ml index 8d77964..165dd6e 100644 --- a/sparsify/copying.ml +++ b/sparsify/copying.ml @@ -216,9 +216,11 @@ You can ignore this warning or change it to a hard failure using the List.exists (fun fs' -> fs = g#canonical_device_name fs') ignores in + let is_read_only_lv = is_read_only_lv g in + List.iter ( fun fs -> - if not (is_ignored fs) then ( + if not (is_ignored fs) && not (is_read_only_lv fs) then ( if List.mem fs zeroes then ( if not quiet then printf (f_"Zeroing %s ...\n%!") fs; diff...
2016 Jul 07
0
[PATCH 2/3] sparsify: fix btrfs subvolume processing in is_read_only_lv
.... Here we workaround it by returning 'false' for subvolumes. --- sparsify/utils.ml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sparsify/utils.ml b/sparsify/utils.ml index 9a49504..8d99db1 100644 --- a/sparsify/utils.ml +++ b/sparsify/utils.ml @@ -34,7 +34,8 @@ let is_read_only_lv (g : G.guestfs) = if lv_attr.[1] = 'r' then Some lv_uuid else None ) lvs in fun fs -> - if g#is_lv fs then ( + (* Btrfs subvolumes are NOT read-only LVs *) + if not (is_btrfs_subvolume g fs) && g#is_lv fs then ( let uuid = g#lvuuid fs in List.e...
2015 Nov 04
1
[PATCH 0/1] sparsify: Let --in-place capture ^C and shut down gracefully
This patch is easier to read if you use the 'git show -w' option. Also observe that: fun a -> ( fun () -> (* code *) ) (ie. returning a closure) is identical to: fun a () -> (* code *) Rich.
2016 Jul 07
7
[PATCH 0/3] fix btrfs subvolume procession in tools
...uestfs API? Also I found an issue. In 'virt-sysprep fs-uuids', the uuids for ALL filesystems are regenerated as many times as many roots are in guest. Is it done intentionally? Maxim Perevedentsev (3): mllib: add checking for btrfs subvolume sparsify: fix btrfs subvolume processing in is_read_only_lv sysprep: fix btrfs subvolume processing in fs-uuids mllib/common_utils.ml | 10 ++++++++++ mllib/common_utils.mli | 3 +++ sparsify/utils.ml | 3 ++- sysprep/sysprep_operation_fs_uuids.ml | 16 +++++++++------- 4 files changed, 24 insertions(...
2016 Dec 08
3
[PATCH 0/2] mllib: Add quote function to Common_utils module.
Doing this allows us to remove the Customize_utils module completely, since it becomes empty. Rich.
2017 Oct 04
0
[PATCH 2/9] ocaml: Replace pattern matching { field = field } with { field }.
...be committed to disk. This is a problem if qemu is * immediately used afterwards with cache=none (which uses O_DIRECT diff --git a/sparsify/utils.ml b/sparsify/utils.ml index 27723c3a2..facf466a8 100644 --- a/sparsify/utils.ml +++ b/sparsify/utils.ml @@ -28,7 +28,7 @@ module G = Guestfs let is_read_only_lv (g : G.guestfs) = let lvs = Array.to_list (g#lvs_full ()) in let ro_uuids = filter_map ( - fun { G.lv_uuid = lv_uuid; lv_attr = lv_attr } -> + fun { G.lv_uuid; lv_attr } -> if lv_attr.[1] = 'r' then Some lv_uuid else None ) lvs in fun fs -> diff --git a/sys...
2017 Nov 21
2
[PATCH v3 0/2] common/mlstdutils: Extend the List module.
v2 -> v3: - Renamed List.assoc_ -> List.assoc_lbl. - Rebased on top of current master branch. Rich.
2017 Oct 04
11
[PATCH 0/9] build: Require OCaml >= 4.02.
Per my previous email: https://www.redhat.com/archives/libguestfs/2017-September/msg00203.html I'd like to talk about requiring a more modern version of the OCaml compiler. These commits show some of the code changes which would be possible with OCaml >= 3.12 [which it turns out we already require by accident] and also with OCaml >= 4.02. The latter is my favoured option. Rich.
2017 Sep 20
8
[PATCH v2 0/6] Fix OCaml dependencies.
v1 -> v2: - Fixed everything mentioned in patch review. - Libdir module is removed as a separate commit. Rich.
2017 Oct 08
4
[PATCH 0/3] common/mlstdutils: Add Std_utils List and Option modules.
In Std_utils we already extend Char and String. These commits take it a little further by extending List and adding a new Option submodule. All basically simple refactoring. Rich.
2017 Oct 08
7
[[PATCH v2 0/4] common/mlstdutils: Add Std_utils List and Option modules.
This time including the first commit ...
2017 Sep 18
0
[PATCH 2/5] Make sure every *.ml file has a corresponding *.mli file.
...s. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + *) + +(** Utilities/common functions used in virt-sparsify only. *) + +val is_read_only_lv : Guestfs.guestfs -> string -> bool +(* Return true if the filesystem is a read-only LV (RHBZ#1185561). *) diff --git a/sysprep/Makefile.am b/sysprep/Makefile.am index ee0b3e5dc..0acd1ddbf 100644 --- a/sysprep/Makefile.am +++ b/sysprep/Makefile.am @@ -70,7 +70,9 @@ operations = \ utmp yum_u...
2017 Sep 18
6
[PATCH 0/5] Fix OCaml dependencies.
This works reliably for me ... Rich.