import nvme-cli-1.14-3.el9
This commit is contained in:
commit
fa11a65c1d
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
SOURCES/v1.14.tar.gz
|
1
.nvme-cli.metadata
Normal file
1
.nvme-cli.metadata
Normal file
@ -0,0 +1 @@
|
||||
0cdeb36c3a661104f49617fb1b625edab18234b2 SOURCES/v1.14.tar.gz
|
33
SOURCES/0001-default-flush-to-use-block-device-nsid.patch
Normal file
33
SOURCES/0001-default-flush-to-use-block-device-nsid.patch
Normal file
@ -0,0 +1,33 @@
|
||||
From 6abc4f36b38aa6be3c7e4b89e2997e5006e40b37 Mon Sep 17 00:00:00 2001
|
||||
From: Keith Busch <kbusch@kernel.org>
|
||||
Date: Tue, 1 Jun 2021 07:01:44 -0700
|
||||
Subject: [PATCH] default flush to use block device nsid
|
||||
|
||||
Kernel 5.13 added checks to ensure the ioctl path can't be abused to
|
||||
access a different namespace than the one user space has permission to
|
||||
open. This unfortunately breaks the all-nsid flush usage, so user
|
||||
tooling needs to default to the device's namespace id.
|
||||
|
||||
Link: https://lore.kernel.org/linux-nvme/20210518144249.GE2709569@dhcp-10-100-145-180.wdc.com/T/#t
|
||||
Link: https://github.com/linux-nvme/nvme-cli/issues/1066
|
||||
Signed-off-by: Keith Busch <kbusch@kernel.org>
|
||||
---
|
||||
nvme.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/nvme.c b/nvme.c
|
||||
index 87e1a82..1666ba5 100644
|
||||
--- a/nvme.c
|
||||
+++ b/nvme.c
|
||||
@@ -4384,7 +4384,7 @@ static int flush(int argc, char **argv, struct command *cmd, struct plugin *plug
|
||||
};
|
||||
|
||||
struct config cfg = {
|
||||
- .namespace_id = NVME_NSID_ALL,
|
||||
+ .namespace_id = 0,
|
||||
};
|
||||
|
||||
OPT_ARGS(opts) = {
|
||||
--
|
||||
2.31.1
|
||||
|
13
SOURCES/nvme-cli-makefile-dont-install-host-params-patch
Normal file
13
SOURCES/nvme-cli-makefile-dont-install-host-params-patch
Normal file
@ -0,0 +1,13 @@
|
||||
--- nvme-cli-1.9/Makefile.orig 2020-05-27 14:04:56.259961135 -0400
|
||||
+++ nvme-cli-1.9/Makefile 2020-05-27 14:05:22.796185371 -0400
|
||||
@@ -125,8 +125,8 @@
|
||||
$(INSTALL) -m 644 -T ./etc/discovery.conf.in $(DESTDIR)$(SYSCONFDIR)/nvme/discovery.conf; \
|
||||
fi
|
||||
|
||||
-install-spec: install-bin install-man install-bash-completion install-zsh-completion install-etc install-systemd install-udev install-dracut
|
||||
-install: install-spec install-hostparams
|
||||
+install-spec: install-bin install-man install-bash-completion install-zsh-completion install-systemd install-udev install-dracut
|
||||
+install: install-spec
|
||||
|
||||
nvme.spec: nvme.spec.in NVME-VERSION-FILE
|
||||
sed -e 's/@@VERSION@@/$(NVME_VERSION)/g' < $< > $@+
|
189
SPECS/nvme-cli.spec
Normal file
189
SPECS/nvme-cli.spec
Normal file
@ -0,0 +1,189 @@
|
||||
#%%global commit0 bdbb4da0979fbdc079cf98410cdb31cf799e83b3
|
||||
#%%global shortcommit0 %%(c=%%{commit0}; echo ${c:0:7})
|
||||
|
||||
Name: nvme-cli
|
||||
Version: 1.14
|
||||
Release: 3%{?dist}
|
||||
Summary: NVMe management command line interface
|
||||
|
||||
License: GPLv2+
|
||||
URL: https://github.com/linux-nvme/nvme-cli
|
||||
Source0: https://github.com/linux-nvme/%{name}/archive/v%{version}.tar.gz
|
||||
|
||||
Patch0: nvme-cli-makefile-dont-install-host-params-patch
|
||||
Patch1: 0001-default-flush-to-use-block-device-nsid.patch
|
||||
|
||||
BuildRequires: libuuid-devel
|
||||
BuildRequires: gcc
|
||||
BuildRequires: systemd-devel
|
||||
Requires: util-linux
|
||||
|
||||
%description
|
||||
nvme-cli provides NVM-Express user space tooling for Linux.
|
||||
|
||||
%prep
|
||||
#%%setup -qn %%{name}-%%{commit0}
|
||||
%setup -q
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
|
||||
|
||||
%build
|
||||
|
||||
# CFLAGS on the command line breaks the build. It works okay as an
|
||||
# environment variable, though. See:
|
||||
# https://github.com/linux-nvme/nvme-cli/pull/480
|
||||
CFLAGS="%{optflags}" make PREFIX=/usr LDFLAGS="%{__global_ldflags}" %{?_smp_mflags}
|
||||
|
||||
|
||||
%install
|
||||
%make_install PREFIX=/usr UDEVDIR="%{_udevrulesdir}/.." SYSTEMDDIR="%{_unitdir}/.."
|
||||
mkdir -p %{buildroot}%{_sysconfdir}/nvme
|
||||
|
||||
# hostid and hostnqn are supposed to be unique per machine. We obviously
|
||||
# can't package them.
|
||||
#rm -f %{buildroot}%{_sysconfdir}/nvme/hostid
|
||||
#rm -f %{buildroot}%{_sysconfdir}/nvme/hostnqn
|
||||
|
||||
# Do not install the dracut rule yet. See rhbz 1742764
|
||||
rm -f %{buildroot}/usr/lib/dracut/dracut.conf.d/70-nvmf-autoconnect.conf
|
||||
|
||||
|
||||
%files
|
||||
%license LICENSE
|
||||
%doc README.md
|
||||
%{_sbindir}/nvme
|
||||
%{_mandir}/man1/nvme*.gz
|
||||
%{_datadir}/bash-completion/completions/nvme
|
||||
%{_datadir}/zsh/site-functions/_nvme
|
||||
%dir %{_sysconfdir}/nvme
|
||||
%{_unitdir}/nvmefc-boot-connections.service
|
||||
%{_unitdir}/nvmf-autoconnect.service
|
||||
%{_unitdir}/nvmf-connect.target
|
||||
%{_unitdir}/nvmf-connect@.service
|
||||
%{_udevrulesdir}/70-nvmf-autoconnect.rules
|
||||
%{_udevrulesdir}/71-nvmf-iopolicy-netapp.rules
|
||||
# Do not install the dracut rule yet. See rhbz 1742764
|
||||
# /usr/lib/dracut/dracut.conf.d/70-nvmf-autoconnect.conf
|
||||
|
||||
%post
|
||||
if [ $1 -eq 1 ] || [ $1 -eq 2 ]; then
|
||||
if [ ! -s %{_sysconfdir}/nvme/hostnqn ]; then
|
||||
echo $(nvme gen-hostnqn) > %{_sysconfdir}/nvme/hostnqn
|
||||
fi
|
||||
if [ ! -s %{_sysconfdir}/nvme/hostid ]; then
|
||||
uuidgen > %{_sysconfdir}/nvme/hostid
|
||||
fi
|
||||
|
||||
# apply udev and systemd changes that we did
|
||||
systemctl enable nvmefc-boot-connections
|
||||
systemctl daemon-reload
|
||||
udevadm control --reload-rules && udevadm trigger
|
||||
exit 0
|
||||
fi
|
||||
|
||||
%changelog
|
||||
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com>
|
||||
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
||||
Related: rhbz#1991688
|
||||
|
||||
* Mon Jun 14 2021 Maurizio Lombardi <mlombard@redhat.com> - 1.14-2
|
||||
- Fix for bz1962422 (nvme flush failed from from v5.13-rc1)
|
||||
|
||||
* Mon May 03 2021 Maurizio Lombardi <mlombard@redhat.com> - 1.14-1
|
||||
- Update to the latest upstream version
|
||||
|
||||
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com>
|
||||
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
||||
|
||||
* Fri Mar 19 2020 Maurizio Lombardi <mlombard@redhat.com> - 1.12-1
|
||||
- Update to 1.13 and add postin scriptlet
|
||||
|
||||
* Sat Apr 25 2020 luto@kernel.org - 1.11.1-1
|
||||
- Update to 1.11
|
||||
|
||||
* Thu Mar 19 2020 luto@kernel.org - 1.10.1-1
|
||||
- Update to 1.10.1
|
||||
|
||||
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.9-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||
|
||||
* Wed Oct 02 2019 luto@kernel.org - 1.9-1
|
||||
- Update to 1.9
|
||||
- Certain fabric functionality may not work yet due to missing dracut
|
||||
support and missing hostid and hostnqn configuration.
|
||||
|
||||
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.8.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||
|
||||
* Mon Apr 15 2019 luto@kernel.org - 1.8.1-1
|
||||
- Update to 1.8.1-1.
|
||||
- Remove a build hack.
|
||||
|
||||
* Sun Feb 24 2019 luto@kernel.org - 1.7-2
|
||||
- Create /etc/nvme
|
||||
|
||||
* Sun Feb 24 2019 luto@kernel.org - 1.7-1
|
||||
- Bump to 1.7
|
||||
- Clean up some trivial rpmlint complaints
|
||||
|
||||
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.6-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||
|
||||
* Tue Jul 24 2018 luto@kernel.org - 1.6-1
|
||||
- Update to 1.6
|
||||
|
||||
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.4-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||
|
||||
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.4-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||
|
||||
* Wed Nov 22 2017 luto@kernel.org - 1.4-1
|
||||
- Update to 1.4
|
||||
|
||||
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.3-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
|
||||
|
||||
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.3-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||
|
||||
* Mon May 22 2017 luto@kernel.org - 1.3-1
|
||||
- Update to 1.3
|
||||
|
||||
* Wed Apr 19 2017 luto@kernel.org - 1.2-2
|
||||
- Update to 1.2
|
||||
- 1.2-1 never existed
|
||||
|
||||
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||
|
||||
* Wed Feb 01 2017 luto@kernel.org - 1.1-1
|
||||
- Update to 1.1
|
||||
|
||||
* Sun Nov 20 2016 luto@kernel.org - 1.0-1
|
||||
- Update to 1.0
|
||||
|
||||
* Mon Oct 31 2016 luto@kernel.org - 0.9-1
|
||||
- Update to 0.9
|
||||
|
||||
* Thu Jun 30 2016 luto@kernel.org - 0.8-1
|
||||
- Update to 0.8
|
||||
|
||||
* Tue May 31 2016 luto@kernel.org - 0.7-1
|
||||
- Update to 0.7
|
||||
|
||||
* Fri Mar 18 2016 luto@kernel.org - 0.5-1
|
||||
- Update to 0.5
|
||||
|
||||
* Sun Mar 06 2016 luto@kernel.org - 0.4-1
|
||||
- Update to 0.4
|
||||
|
||||
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.2-3.20160112gitbdbb4da
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||
|
||||
* Wed Jan 20 2016 luto@kernel.org - 0.2-2.20160112gitbdbb4da
|
||||
- Update to new upstream commit, fixing #49. "nvme list" now works.
|
||||
|
||||
* Wed Jan 13 2016 luto@kernel.org - 0.2-1.20160112gitde3e0f1
|
||||
- Initial import.
|
Loading…
Reference in New Issue
Block a user