-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DAOS-15079 test: VMD Hot Plug - Support rpc.py in spdk-tools package (#…
…61) Update packaging/. We need to support rpc.py from spdk-tools package (RPM) so that we can use the script in CI. Make the changes in spdk.spec so that rpc.py is included in the RPM. After installing the RPM, we should be able to use the script by calling: /usr/share/spdk/scripts/rpc.py Skip CentOS7 build. Fix rpmlint error. Add examples installation for Debian to spdk-tools. Install all scripts from spdk-tools. Skip-list-master: test_daos_rebuild_ec:DAOS-14982 test_daos_degraded_ec:DAOS-14982 test_ms_failover:DAOS-16103 test_cart_rpc:DAOS-15989 Skip-list-release/2.6: test_dfuse_daos_build_wb:DAOS-16168 test_osa_offline_reintegration_without_checksum:DAOS-15608 test_daos_extend_simple:DAOS-15640 Signed-off-by: Tomasz Gromadzki <[email protected]> Signed-off-by: Makito Kano <[email protected]> Signed-off-by: Gromadzki, Tomasz <[email protected]> Signed-off-by: Jan Michalski <[email protected]> Co-authored-by: Tomasz Gromadzki <[email protected]> Co-authored-by: Jan Michalski <[email protected]>
- Loading branch information
1 parent
0deb13d
commit b7381a5
Showing
16 changed files
with
221 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,11 @@ | ||
spdk (22.01.2-6) unstable; urgency=medium | ||
|
||
[ Tomasz Gromadzki ] | ||
* Add rpc.py to spdk-tools package. | ||
* Synchronize Debian package with RPMs by adding examples to spdk-tools package. | ||
|
||
-- Tomasz Gromadzki <[email protected]> Tue, 23 Apr 2024 00:00:00 +0000 | ||
|
||
spdk (22.01.2-3) unstable; urgency=medium | ||
|
||
[ Tom Nabarro ] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ Priority: optional | |
Maintainer: daos-stack <[email protected]> | ||
Build-Depends: | ||
debhelper, | ||
python, | ||
python3, | ||
libdpdk-dev (>= 21.11.2), | ||
librdmacm-dev, | ||
libibverbs-dev, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
usr/include/* | ||
lib/x86_64-linux-gnu/lib*.so | ||
lib/x86_64-linux-gnu/lib*.a | ||
lib/x86_64-linux-gnu/pkgconfig/* | ||
lib/x86_64-linux-gnu/pkgconfig/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
lib/x86_64-linux-gnu/lib*.so.* | ||
lib/x86_64-linux-gnu/lib*.so.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
usr/share/spdk-tools/scripts | ||
usr/include/spdk | ||
usr/share/spdk-tools/python | ||
usr/share/spdk-tools/python/rpc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,7 @@ | ||
usr/bin/* | ||
usr/bin/* | ||
scripts/{setup,common}.sh usr/share/spdk-tools/scripts | ||
include/spdk/pci_ids.h usr/include/spdk | ||
scripts/rpc.py usr/share/spdk-tools/python | ||
scripts/rpc/*.py usr/share/spdk-tools/python/rpc | ||
build/examples/spdk_lsvmd usr/bin/ | ||
build/examples/spdk_nvme_manage usr/bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
From e87d916d7f49ea4949973adf0f09e9e5bf891e03 Mon Sep 17 00:00:00 2001 | ||
From: "Brian J. Murrell" <[email protected]> | ||
Date: Tue, 30 Jan 2024 11:03:12 -0500 | ||
Subject: [PATCH 1/2] Show ccache stats at the end of the build | ||
|
||
Zero the ccache stats at the beginning of the build and then display the | ||
ccache stats at the end of the build to see how effective ccache was. | ||
|
||
Signed-off-by: Brian J. Murrell <[email protected]> | ||
--- | ||
mock/py/mockbuild/plugins/ccache.py | 11 +++++++++++ | ||
1 file changed, 11 insertions(+) | ||
|
||
diff --git a/mock/py/mockbuild/plugins/ccache.py b/mock/py/mockbuild/plugins/ccache.py | ||
index 2666ad9fc..1080ffe68 100644 | ||
--- a/mock/py/mockbuild/plugins/ccache.py | ||
+++ b/mock/py/mockbuild/plugins/ccache.py | ||
@@ -35,6 +35,7 @@ def __init__(self, plugins, conf, buildroot): | ||
buildroot.preexisting_deps.append("ccache") | ||
plugins.add_hook("prebuild", self._ccacheBuildHook) | ||
plugins.add_hook("preinit", self._ccachePreInitHook) | ||
+ plugins.add_hook("postbuild", self._ccachePostBuildHook) | ||
buildroot.mounts.add( | ||
BindMountPoint(srcpath=self.ccachePath, bindpath=buildroot.make_chroot_path("/var/tmp/ccache"))) | ||
|
||
@@ -47,6 +48,9 @@ def __init__(self, plugins, conf, buildroot): | ||
@traceLog() | ||
def _ccacheBuildHook(self): | ||
self.buildroot.doChroot(["ccache", "-M", str(self.ccache_opts['max_cache_size'])], shell=False) | ||
+ # zero ccache stats | ||
+ getLog().info("Zero ccache stats:") | ||
+ self.buildroot.doChroot(["ccache", "--zero-stats"], printOutput=True, shell=False) | ||
|
||
# set up the ccache dir. | ||
# we also set a few variables used by ccache to find the shared cache. | ||
@@ -61,3 +65,10 @@ def _ccachePreInitHook(self): | ||
file_util.mkdirIfAbsent(self.buildroot.make_chroot_path('/var/tmp/ccache')) | ||
file_util.mkdirIfAbsent(self.ccachePath) | ||
self.buildroot.uid_manager.changeOwner(self.ccachePath, recursive=True) | ||
+ | ||
+ # get some cache stats | ||
+ def _ccachePostBuildHook(self): | ||
+ # show the cache hit stats | ||
+ getLog().info("ccache stats:") | ||
+ self.buildroot.doChroot(["ccache", "--show-stats"], printOutput=True, shell=False) | ||
++ | ||
|
||
From bfd3a7e1bb47d28ee60a94cb5985c1f66476475f Mon Sep 17 00:00:00 2001 | ||
From: "Brian J. Murrell" <[email protected]> | ||
Date: Tue, 30 Jan 2024 11:17:48 -0500 | ||
Subject: [PATCH 2/2] Remove extraneous line | ||
|
||
Signed-off-by: Brian J. Murrell <[email protected]> | ||
--- | ||
mock/py/mockbuild/plugins/ccache.py | 1 - | ||
1 file changed, 1 deletion(-) | ||
|
||
diff --git a/mock/py/mockbuild/plugins/ccache.py b/mock/py/mockbuild/plugins/ccache.py | ||
index 1080ffe68..1a20846d3 100644 | ||
--- a/mock/py/mockbuild/plugins/ccache.py | ||
+++ b/mock/py/mockbuild/plugins/ccache.py | ||
@@ -71,4 +71,3 @@ def _ccachePostBuildHook(self): | ||
# show the cache hit stats | ||
getLog().info("ccache stats:") | ||
self.buildroot.doChroot(["ccache", "--show-stats"], printOutput=True, shell=False) | ||
-+ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#!/bin/bash | ||
|
||
# find the base branch of the current branch | ||
|
||
set -eux -o pipefail | ||
IFS=' ' read -r -a add_bases <<< "${1:-}" | ||
origin=origin | ||
mapfile -t all_bases < <(echo "master" | ||
git branch -r | sed -ne "/^ $origin\\/release\\/[0-9]/s/^ $origin\\///p") | ||
all_bases+=("${add_bases[@]}") | ||
TARGET="master" | ||
min_diff=-1 | ||
for base in "${all_bases[@]}"; do | ||
git rev-parse --verify "$origin/$base" &> /dev/null || continue | ||
commits_ahead=$(git log --oneline "$origin/$base..HEAD" | wc -l) | ||
if [ "$min_diff" -eq -1 ] || [ "$min_diff" -gt "$commits_ahead" ]; then | ||
TARGET="$base" | ||
min_diff=$commits_ahead | ||
fi | ||
done | ||
echo "$TARGET" | ||
exit 0 |
Oops, something went wrong.