Hi, Richard
I'm a college student and this is my first time submitting codes to the community.
I reduced the timeout period during the test,
and so sorry that I have provided an unclean patch to you.
I've remade a new patch set, May i trouble you to review the attachment ?
thanks.
wangguoquan03(a)foxmail.com
From: Richard W.M. Jones
Date: 2024-09-09 20:26
To: wangguoquan03
CC: guestfs; Wei Jiangang
Subject: [Libguestfs] Re: [PATCH] suport openEuler
On Sun, Sep 08, 2024 at 04:17:28AM +0800, wangguoquan03(a)foxmail.com wrote:
From: Wei Jiangang <wei.jiangang(a)foxmail.com>
Signed-off-by: Wei Jiangang <wei.jiangang(a)foxmail.com>
diff --git a/appliance/init b/appliance/init
index 19aa151..28e0e77 100755
--- a/appliance/init
+++ b/appliance/init
@@ -101,12 +101,12 @@ fi
$UDEVD --daemon #--debug
udevadm trigger
-udevadm settle --timeout=600
+udevadm settle --timeout=300
# Disk optimizations.
# Increase the SCSI timeout so we can read remote images.
shopt -s nullglob
-for f in /sys/block/sd*/device/timeout; do echo 300 > $f; done
+for f in /sys/block/sd*/device/timeout; do echo 150 > $f; done
Why reduce these numbers?
I guess the rest below should have been part of the previous patch?
diff --git a/daemon/inspect_fs.ml b/daemon/inspect_fs.ml
index 9c73d97..4ca2433 100644
--- a/daemon/inspect_fs.ml
+++ b/daemon/inspect_fs.ml
@@ -265,6 +265,7 @@ and check_package_format { distro } =
| Some DISTRO_MANDRIVA
| Some DISTRO_MEEGO
| Some DISTRO_NEOKYLIN
+ | Some DISTRO_OPENEULER
| Some DISTRO_OPENMANDRIVA
| Some DISTRO_OPENSUSE
| Some DISTRO_ORACLE_LINUX
@@ -377,6 +378,9 @@ and check_package_management { distro; version } =
| Some DISTRO_VOID_LINUX ->
Some PACKAGE_MANAGEMENT_XBPS
+ | Some DISTRO_OPENEULER->
+ Some PACKAGE_MANAGEMENT_DNF
+
| Some DISTRO_OPENMANDRIVA ->
Some PACKAGE_MANAGEMENT_DNF
diff --git a/daemon/inspect_fs_unix.ml b/daemon/inspect_fs_unix.ml
index 8045ef0..2f5bf6c 100644
--- a/daemon/inspect_fs_unix.ml
+++ b/daemon/inspect_fs_unix.ml
@@ -151,6 +151,7 @@ and distro_of_os_release_id = function
| "kylin" -> Some DISTRO_KYLIN
| "mageia" -> Some DISTRO_MAGEIA
| "neokylin" -> Some DISTRO_NEOKYLIN
+ | "openEuler" -> Some DISTRO_OPENEULER
| "openmandriva" -> Some DISTRO_OPENMANDRIVA
| "opensuse" -> Some DISTRO_OPENSUSE
| s when String.is_prefix s "opensuse-" -> Some DISTRO_OPENSUSE
diff --git a/daemon/inspect_types.ml b/daemon/inspect_types.ml
index 9395c51..5d66d6e 100644
--- a/daemon/inspect_types.ml
+++ b/daemon/inspect_types.ml
@@ -88,6 +88,7 @@ and distro =
| DISTRO_NEOKYLIN
| DISTRO_NETBSD
| DISTRO_OPENBSD
+ | DISTRO_OPENEULER
| DISTRO_OPENMANDRIVA
| DISTRO_OPENSUSE
| DISTRO_ORACLE_LINUX
@@ -222,6 +223,7 @@ and string_of_distro = function
| DISTRO_NEOKYLIN -> "neokylin"
| DISTRO_NETBSD -> "netbsd"
| DISTRO_OPENBSD -> "openbsd"
+ | DISTRO_OPENEULER -> "openEuler"
| DISTRO_OPENMANDRIVA -> "openmandriva"
| DISTRO_OPENSUSE -> "opensuse"
| DISTRO_ORACLE_LINUX -> "oraclelinux"
diff --git a/daemon/inspect_types.mli b/daemon/inspect_types.mli
index 29c76e8..9cf61f3 100644
--- a/daemon/inspect_types.mli
+++ b/daemon/inspect_types.mli
@@ -95,6 +95,7 @@ and distro =
| DISTRO_NEOKYLIN
| DISTRO_NETBSD
| DISTRO_OPENBSD
+ | DISTRO_OPENEULER
| DISTRO_OPENMANDRIVA
| DISTRO_OPENSUSE
| DISTRO_ORACLE_LINUX
diff --git a/generator/actions_inspection.ml b/generator/actions_inspection.ml
index f8b7449..4721033 100644
--- a/generator/actions_inspection.ml
+++ b/generator/actions_inspection.ml
@@ -250,6 +250,10 @@ NetBSD.
OpenBSD.
+=item \"openeuler\"
+
+openEuler.
+
=item \"openmandriva\"
OpenMandriva Lx.
--
2.43.0
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
Read my programming and virtualization blog:
http://rwmj.wordpress.com
nbdkit - Flexible, fast NBD server with plugins
https://gitlab.com/nbdkit/nbdkit
_______________________________________________
Libguestfs mailing list -- guestfs(a)lists.libguestfs.org
To unsubscribe send an email to guestfs-leave(a)lists.libguestfs.org