search for: check_filesystem

Displaying 20 results from an estimated 67 matches for "check_filesystem".

2023 May 19
1
[libguestfs PATCH 3/3] LUKS-on-LVM inspection test: test /dev/mapper/VG-LV translation
On Fri, May 19, 2023 at 04:08:49PM +0200, Laszlo Ersek wrote: > In the LUKS-on-LVM inspection test, call the "check_filesystems" function > yet another time, now with such "--key" options that exercise the recent > "/dev/mapper/VG-LV" -> "/dev/VG/LV" translation (unescaping) from > libguestfs-common. > > Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2168506 >...
2016 Mar 17
2
[PATCH] inspect: improve UsrMove detection (RHBZ#1186935)
...mlink, check it points to "usr/bin". --- src/inspect-fs.c | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/src/inspect-fs.c b/src/inspect-fs.c index 02fdb2a..0714ae1 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -43,6 +43,7 @@ static int check_filesystem (guestfs_h *g, const char *mountable, int whole_device); static void extend_fses (guestfs_h *g); static int get_partition_context (guestfs_h *g, const char *partition, int *partnum_ret, int *nr_partitions_ret); +static int is_symlink_to (guestfs_h *g, const char *fil...
2013 Feb 07
2
[PATCH 1/2] Fix bogus partition number passed to guestfs___check_for_filesystem_on
...*str); extern int guestfs___parse_major_minor (guestfs_h *g, struct inspect_fs *fs); diff --git a/src/inspect-fs.c b/src/inspect-fs.c index ce075db..0069dc6 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -79,47 +79,47 @@ free_regexps (void) pcre_free (re_major_minor); } -static int check_filesystem (guestfs_h *g, const char *device, int is_block, int is_partnum); +static int check_filesystem (guestfs_h *g, const char *device, + int whole_device); static int extend_fses (guestfs_h *g); /* Find out if 'device' contains a filesystem. If it does, add * a...
2016 Dec 06
9
[PATCH 0/5] Improve inspection of /usr filesystems
Hi, this patch series improves the way /usr filesystems are handled: tag them appropriately, so later on we can find them and merge results they contain directly back for the root filesystem. The series includes also a new private debug API, and its usage to fix the resolution of /dev/mapper/.. devices found in fstab; without it, LVM /usr filesystems are not recognized as belonging to their
2016 Feb 24
2
[PATCH] inspect: check also /etc/hosts for detecting Linux root (RHBZ#1203898)
...latter might not exist in smaller/special installations like Docker images. --- src/inspect-fs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/inspect-fs.c b/src/inspect-fs.c index 02fdb2a..ad175f8 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -217,7 +217,8 @@ check_filesystem (guestfs_h *g, const char *mountable, (is_dir_bin || (guestfs_is_symlink (g, "/bin") > 0 && guestfs_is_dir (g, "/usr/bin") > 0)) && - guestfs_is_file (g, "/etc/fstab") > 0) { + (guestfs...
2023 May 19
3
[libguestfs PATCH 0/3] test "/dev/mapper/VG-LV" with "--key"
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2168506 This small set covers the new /dev/mapper/VG-LV "--key" ID format in the libguestfs LUKS-on-LVM inspection test. Thanks, Laszlo Laszlo Ersek (3): update common submodule LUKS-on-LVM inspection test: rename VGs and LVs LUKS-on-LVM inspection test: test /dev/mapper/VG-LV translation common
2014 Nov 27
2
[PATCH 1/1] inspect: Fix a bug in the *BSD root detection
...imary_partition, "^/dev/(?:h|s|v)d.[1234]$", 0); COMPILE (re_major_minor, "(\\d+)\\.(\\d+)", 0); } static void free_regexps (void) { - pcre_free (re_first_partition); + pcre_free (re_primary_partition); pcre_free (re_major_minor); } @@ -84,6 +84,39 @@ static int check_filesystem (guestfs_h *g, const char *mountable, int whole_device); static int extend_fses (guestfs_h *g); +/* On *BSD systems, sometimes /dev/sda[1234] is a shadow of the real root + * filesystem that is probably /dev/sda5 + * (see: http://www.freebsd.org/doc/handbook/disk-or...
2014 Dec 09
0
[PATCH] inspection: Not an installer if there are multiple partitions (RHBZ#1171666).
...s_device_index (g, device) == -1) { - guestfs_pop_error_handler (g); - return 0; - } - - guestfs_pop_error_handler (g); - - return 1; -} diff --git a/src/inspect-fs.c b/src/inspect-fs.c index e9cc2e9..7b116db 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -48,6 +48,7 @@ static int check_filesystem (guestfs_h *g, const char *mountable, const struct guestfs_internal_mountable *m, int whole_device); static int extend_fses (guestfs_h *g); +static int get_partition_context (guestfs_h *g, const char *partition, int *partnum_ret, int *nr_...
2015 Jun 04
3
[PATCH] Use safe_realloc() in favor of realloc overall.
...0; } /* Compute a uuid hash as a simple xor of of its 4 32bit components */ diff --git a/src/inspect-fs.c b/src/inspect-fs.c index 09a7005..073ae57 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -47,7 +47,7 @@ COMPILE_REGEXP (re_major_minor, "(\\d+)\\.(\\d+)", 0) static int check_filesystem (guestfs_h *g, const char *mountable, const struct guestfs_internal_mountable *m, int whole_device); -static int extend_fses (guestfs_h *g); +static void extend_fses (guestfs_h *g); static int get_partition_context (guestfs_h *g, const ch...
2016 Mar 17
0
Re: [PATCH] inspect: improve UsrMove detection (RHBZ#1186935)
.... > --- > src/inspect-fs.c | 20 ++++++++++++++++++-- > 1 file changed, 18 insertions(+), 2 deletions(-) > > diff --git a/src/inspect-fs.c b/src/inspect-fs.c > index 02fdb2a..0714ae1 100644 > --- a/src/inspect-fs.c > +++ b/src/inspect-fs.c > @@ -43,6 +43,7 @@ static int check_filesystem (guestfs_h *g, const char *mountable, > int whole_device); > static void extend_fses (guestfs_h *g); > static int get_partition_context (guestfs_h *g, const char *partition, int *partnum_ret, int *nr_partitions_ret); > +static int is_symlink_to (guestfs_h...
2011 Mar 22
1
[PATCH] inspect: Don't fail for Windows guests with multiple disks (RHBZ#674130).
...FS_CONTENT_LINUX_ROOT, FS_CONTENT_WINDOWS_ROOT, + FS_CONTENT_WINDOWS_VOLUME, FS_CONTENT_LINUX_BOOT, FS_CONTENT_LINUX_USR, FS_CONTENT_LINUX_USR_LOCAL, diff --git a/src/inspect.c b/src/inspect.c index 20e8806..716d592 100644 --- a/src/inspect.c +++ b/src/inspect.c @@ -366,9 +366,13 @@ check_filesystem (guestfs_h *g, const char *device, guestfs_is_dir (g, "/run") > 0 && guestfs_is_dir (g, "/spool") > 0) fs->content = FS_CONTENT_LINUX_VAR; - /* Windows root? */ + /* Windows root? + * Note that if a Windows guest has multiple dis...
2018 Feb 07
2
[PATCH] daemon: add inspector support for MS-DOS distro
...ml | 14 ++++++++++++++ daemon/inspect_types.ml | 2 ++ daemon/inspect_types.mli | 1 + 3 files changed, 17 insertions(+) diff --git a/daemon/inspect_fs.ml b/daemon/inspect_fs.ml index 13ed127cd..a20de6761 100644 --- a/daemon/inspect_fs.ml +++ b/daemon/inspect_fs.ml @@ -220,6 +220,18 @@ and check_filesystem mountable = *) data.arch <- Some "i386" ) + (* MS-DOS *) + else if is_dir_nocase "/DOS" && + is_file_nocase "/DOS/COMMAND.COM" then ( + debug_matching "MS-DOS"; + role := `Root; + data.os_type <- Some OS_TYPE_DO...
2013 Feb 12
7
Remaining btrfs patches
[PATCH 1/7] mount: Add mount_vfs_nochroot This is significantly reworked from before. umount is gone as discussed, and variable motion is minimised. [PATCH 2/7] btrfs: Update btrfs_subvolume_list to take Already provisionally ACKed. Previous comment was that cleanup could be tidier. I looked into creating a new cleanup function for fs_buf, but it isn't possible (or simple, anyway) in this
2013 Nov 28
3
[PATCH 1/3] inspect: recognise Debian live images as such
Check for filesystem.squashfs also in /live, since it is where live-build places it. --- src/inspect-fs-cd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/inspect-fs-cd.c b/src/inspect-fs-cd.c index 407e4f8..eaeaa6f 100644 --- a/src/inspect-fs-cd.c +++ b/src/inspect-fs-cd.c @@ -429,7 +429,8 @@ guestfs___check_installer_root (guestfs_h *g, struct inspect_fs *fs) *
2014 Dec 02
0
[PATCH 2/5] inspect_os: Add support for detecting OpenBSD
...+ 5); + } else if ((part = match1 (g, spec, re_diskbyid)) != NULL) { r = resolve_fstab_device_diskbyid (g, part, &device); free (part); diff --git a/src/inspect-fs.c b/src/inspect-fs.c index fe82132..aaddb49 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -177,6 +177,7 @@ check_filesystem (guestfs_h *g, const char *mountable, if (guestfs___check_freebsd_root (g, fs) == -1) return -1; } + /* NetBSD root? */ else if (is_dir_etc && is_dir_bin && guestfs_is_file (g, "/netbsd") > 0 && @@ -187,6 +188,17 @@ che...
2014 Dec 03
1
[PATCH 1/4] inspect_os: Add support for detecting OpenBSD
...+ 5); + } else if ((part = match1 (g, spec, re_diskbyid)) != NULL) { r = resolve_fstab_device_diskbyid (g, part, &device); free (part); diff --git a/src/inspect-fs.c b/src/inspect-fs.c index fe82132..aaddb49 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -177,6 +177,7 @@ check_filesystem (guestfs_h *g, const char *mountable, if (guestfs___check_freebsd_root (g, fs) == -1) return -1; } + /* NetBSD root? */ else if (is_dir_etc && is_dir_bin && guestfs_is_file (g, "/netbsd") > 0 && @@ -187,6 +188,17 @@ che...
2013 Nov 28
3
Re: [PATCH 3/3] inspect: improve detection of FreeBSD install discs
...e if (guestfs_is_file (g, "/amd64/txtsetup.sif") > 0) { > fs->arch = safe_strdup (g, "x86_64"); > diff --git a/src/inspect-fs.c b/src/inspect-fs.c > index 0473e92..89c9335 100644 > --- a/src/inspect-fs.c > +++ b/src/inspect-fs.c > @@ -320,7 +320,8 @@ check_filesystem (guestfs_h *g, const char *mountable, > guestfs_is_file (g, "/.discinfo") > 0 || > guestfs_is_file (g, "/i386/txtsetup.sif") > 0 || > guestfs_is_file (g, "/amd64/txtsetup.sif") > 0 || > - guestfs_is...
2015 Jun 02
1
[PATCH 2/3] inspection: Add support for CoreOS
...fs->mountable, "/usr") == -1) + return -1; + + return 0; +} + static void check_architecture (guestfs_h *g, struct inspect_fs *fs) { diff --git a/src/inspect-fs.c b/src/inspect-fs.c index a2913d6..0fbd26c 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -232,6 +232,17 @@ check_filesystem (guestfs_h *g, const char *mountable, if (guestfs_int_check_linux_root (g, fs) == -1) return -1; } + /* CoreOS root? */ + else if (is_dir_etc && + guestfs_is_dir (g, "/root") > 0 && + guestfs_is_dir (g, "/home") > 0 &amp...
2015 May 29
2
[PATCH 2/3] inspection: Add support for CoreOS
...fs->mountable, "/usr") == -1) + return -1; + + return 0; +} + static void check_architecture (guestfs_h *g, struct inspect_fs *fs) { diff --git a/src/inspect-fs.c b/src/inspect-fs.c index 5f55f1d..64f904f 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -232,6 +232,17 @@ check_filesystem (guestfs_h *g, const char *mountable, if (guestfs_int_check_linux_root (g, fs) == -1) return -1; } + /* CoreOS root? */ + else if (is_dir_etc && + guestfs_is_dir (g, "/root") > 0 && + guestfs_is_dir (g, "/home") > 0 &amp...
2013 Jun 05
3
[PATCH 1/3] inspection: Refactor windows systemroot detection to allow re-use
...k above in get_windows_systemroot. */ CLEANUP_FREE char *cmd_exe_path = guestfs_case_sensitive_path (g, cmd_exe); if (!cmd_exe_path) return -1; diff --git a/src/inspect-fs.c b/src/inspect-fs.c index d220634..0473e92 100644 --- a/src/inspect-fs.c +++ b/src/inspect-fs.c @@ -175,6 +175,9 @@ check_filesystem (guestfs_h *g, const char *mountable, const struct guestfs_internal_mountable *m, int whole_device) { + /* Not CLEANUP_FREE, as it will be cleaned up with inspection info */ + char *windows_systemroot = NULL; + if (extend_fses (g) == -1) return -1;...