47940b
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
47940b
47940b
%global auditversion 0.3
47940b
47940b
Summary: A set of tools to gather troubleshooting information from a system
47940b
Name: sos
92cd8f
Version: 4.2
1dc99f
Release: 8%{?dist}
47940b
Group: Applications/System
47940b
Source0: https://github.com/sosreport/sos/archive/%{version}/sos-%{version}.tar.gz
47940b
Source1: sos-audit-%{auditversion}.tgz
47940b
License: GPLv2+
47940b
BuildArch: noarch
47940b
Url: https://github.com/sosreport/sos
47940b
BuildRequires: python3-devel
47940b
BuildRequires: gettext
47940b
Requires: libxml2-python3
47940b
#Requires: python3-rpm
47940b
Requires: tar
47940b
Requires: bzip2
47940b
Requires: xz
47940b
Recommends: python3-pexpect
47940b
Conflicts: vdsm < 4.40
47940b
Obsoletes: sos-collector <= 1.9
92cd8f
Recommends: python3-pexpect
92cd8f
Recommends: python3-requests
92cd8f
Patch1: sos-bz1869561-cpuX-individual-sizelimits.patch
92cd8f
Patch2: sos-bz2011533-unpackaged-recursive-symlink.patch
92cd8f
Patch3: sos-bz2011534-opacapture-under-allow-system-changes.patch
92cd8f
Patch4: sos-bz2011535-kernel-psi.patch
92cd8f
Patch5: sos-bz2011538-iptables-save-under-nf_tables-kmod.patch
92cd8f
Patch6: sos-bz2011537-estimate-only-option.patch
92cd8f
Patch7: sos-bz2011536-iptables-based-on-ntf.patch
92cd8f
Patch8: sos-bz2011507-foreman-puma-status.patch
92cd8f
Patch9: sos-bz2012858-dryrun-uncaught-exception.patch
92cd8f
Patch10: sos-bz2019697-openvswitch-offline-analysis.patch
92cd8f
Patch11: sos-bz2012859-plugin-timeout-unhandled-exception.patch
92cd8f
Patch12: sos-bz2023481-plugin-timeouts-proper-handling.patch
92cd8f
Patch13: sos-bz2020778-filter-namespace-per-pattern.patch
1dc99f
Patch14: sos-bz2024893-cleaner-hostnames-improvements.patch
1dc99f
Patch15: sos-bz2025611-RHTS-api-change.patch
1dc99f
Patch16: sos-bz2034001-nvidia-GPU-info.patch
1dc99f
Patch17: sos-bz2031777-rhui-logs.patch
47940b
47940b
%description
47940b
Sos is a set of tools that gathers information about system
47940b
hardware and configuration. The information can then be used for
47940b
diagnostic purposes and debugging. Sos is commonly used to help
47940b
support technicians and developers.
47940b
47940b
%prep
47940b
%setup -qn %{name}-%{version}
47940b
%setup -T -D -a1 -q
47940b
%patch1 -p1
47940b
%patch2 -p1
47940b
%patch3 -p1
47940b
%patch4 -p1
47940b
%patch5 -p1
47940b
%patch6 -p1
47940b
%patch7 -p1
47940b
%patch8 -p1
47940b
%patch9 -p1
47940b
%patch10 -p1
47940b
%patch11 -p1
47940b
%patch12 -p1
47940b
%patch13 -p1
1dc99f
%patch14 -p1
1dc99f
%patch15 -p1
1dc99f
%patch16 -p1
1dc99f
%patch17 -p1
47940b
47940b
%build
47940b
%py3_build
47940b
47940b
%install
47940b
%py3_install '--install-scripts=%{_sbindir}'
47940b
47940b
install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}
47940b
install -d -m 700 %{buildroot}%{_sysconfdir}/%{name}/cleaner
47940b
install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}/presets.d
47940b
install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}/groups.d
47940b
install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}/extras.d
47940b
install -m 644 %{name}.conf %{buildroot}%{_sysconfdir}/%{name}/%{name}.conf
47940b
47940b
rm -rf %{buildroot}/usr/config/
47940b
47940b
%find_lang %{name} || echo 0
47940b
47940b
cd %{name}-audit-%{auditversion}
47940b
DESTDIR=%{buildroot} ./install.sh
47940b
cd ..
47940b
47940b
%files -f %{name}.lang
47940b
%{_sbindir}/sos
47940b
%{_sbindir}/sosreport
47940b
%{_sbindir}/sos-collector
47940b
#%dir /etc/sos/cleaner
47940b
%dir /etc/sos/presets.d
47940b
%dir /etc/sos/extras.d
47940b
%dir /etc/sos/groups.d
47940b
%{python3_sitelib}/*
47940b
%{_mandir}/man1/*
47940b
%{_mandir}/man5/sos.conf.5.gz
47940b
%doc AUTHORS README.md
47940b
%license LICENSE
47940b
%config(noreplace) %{_sysconfdir}/sos/sos.conf
47940b
%config(noreplace) %{_sysconfdir}/sos/cleaner
47940b
47940b
47940b
%package audit
47940b
Summary: Audit use of some commands for support purposes
47940b
License: GPLv2+
47940b
Group: Application/System
47940b
47940b
%description audit
47940b
47940b
Sos-audit provides configuration files for the Linux Auditing System
47940b
to track the use of some commands capable of changing the configuration
47940b
of the system.  Currently storage and filesystem commands are audited.
47940b
47940b
%post audit
47940b
%{_sbindir}/sos-audit.sh
47940b
47940b
%files audit
47940b
%defattr(755,root,root,-)
47940b
%{_sbindir}/sos-audit.sh
47940b
%defattr(644,root,root,-)
47940b
%config(noreplace) %{_sysconfdir}/sos/sos-audit.conf
47940b
%defattr(444,root,root,-)
47940b
%{_prefix}/lib/sos/audit/*
47940b
%{_mandir}/man5/sos-audit.conf.5.gz
47940b
%{_mandir}/man8/sos-audit.sh.8.gz
47940b
%ghost /etc/audit/rules.d/40-sos-filesystem.rules
47940b
%ghost /etc/audit/rules.d/40-sos-storage.rules
47940b
47940b
47940b
%changelog
1dc99f
* Sun Dec 19 2021 Pavel Moravec <pmoravec@redhat.com> = 4.2-8
1dc99f
- [rhui] New log folder
1dc99f
  Resolves: bz2031777
1dc99f
- nvidia]:Patch to update nvidia plugin for GPU info
1dc99f
  Resolves: bz2034001
1dc99f
- [hostname] Fix edge case for new hosts in a known subdomain
1dc99f
  Resolves: bz2024893
1dc99f
1dc99f
* Wed Dec 08 2021 Pavel Moravec <pmoravec@redhat.com> = 4.2-7
1dc99f
- [hostname] Simplify case matching for domains
1dc99f
  Resolves: bz2024893
1dc99f
1dc99f
* Tue Nov 30 2021 Pavel Moravec <pmoravec@redhat.com> = 4.2-6
1dc99f
- [redhat] Fix broken URI to upload to customer portal
1dc99f
  Resolves: bz2025611
1dc99f
1dc99f
* Mon Nov 22 2021 Pavel Moravec <pmoravec@redhat.com> = 4.2-5
1dc99f
- [clean,hostname_parser] Source /etc/hosts for obfuscation
1dc99f
  Resolves: bz2024893
1dc99f
- [clean, hostname] Fix unintentionally case sensitive
1dc99f
  Resolves: bz2024892
1dc99f
- [redhat] update SFTP API version to v2
1dc99f
  Resolves: bz2025611
1dc99f
92cd8f
* Tue Nov 16 2021 Pavel Moravec <pmoravec@redhat.com> = 4.2-4
92cd8f
- [report] Calculate sizes of dirs, symlinks and manifest in
92cd8f
  Resolves: bz2011537
92cd8f
- [report] shutdown threads for timeouted plugins
92cd8f
  Resolves: bz2012859
92cd8f
- [report] fix filter_namespace per pattern
92cd8f
  Resolves: bz2020778
92cd8f
- Ensure specific plugin timeouts are only set
92cd8f
  Resolves: bz2023481
92cd8f
92cd8f
* Wed Nov 03 2021 Pavel Moravec <pmoravec@redhat.com> = 4.2-2
92cd8f
- [firewall_tables] call iptables -t  based on nft
92cd8f
  Resolves: bz2011536
92cd8f
- [report] Count with sos_logs and sos_reports in
92cd8f
  Resolves: bz2011537
92cd8f
- [foreman] Collect puma status and stats
92cd8f
  Resolves: bz2011507
92cd8f
- [report] Overwrite pred=None before refering predicate
92cd8f
  Resolves: bz2012858
92cd8f
- [openvswitch] add commands for offline analysis
92cd8f
  Resolves: bz2019697
92cd8f
92cd8f
* Wed Oct 06 2021 Pavel Moravec <pmoravec@redhat.com> = 4.2-1
92cd8f
- Rebase on upstream 4.2
92cd8f
  Resolves: bz1998134
92cd8f
- [report] Implement --estimate-only
92cd8f
  Resolves: bz2011537
92cd8f
- [omnipath_client] Opacapture to run only with allow changes
92cd8f
  Resolves: bz2011534
92cd8f
- [unpackaged] deal with recursive loop of symlinks properly
92cd8f
  Resolves: bz2011533
92cd8f
- [networking] prevent iptables-save commands to load nf_tables
92cd8f
  Resolves: bz2011538
92cd8f
- [kernel] Capture Pressure Stall Information
92cd8f
  Resolves: bz2011535
92cd8f
- [processor] Apply sizelimit to /sys/devices/system/cpu/cpuX
92cd8f
  Resolves: bz1869561
92cd8f
47940b
* Wed Aug 11 2021 Pavel Moravec <pmoravec@redhat.com> = 4.1-8
47940b
- [report,collect] unify --map-file arguments
47940b
  Resolves: bz1985985
47940b
- [rhui] add new plugin for RHUI 4
47940b
  Resolves: bz1992859
47940b
- [username parser] Load usernames from `last` for LDAP users
47940b
  Resolves: bz1992861
47940b
47940b
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 4.1-7
47940b
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
47940b
  Related: rhbz#1991688
47940b
47940b
* Tue Jul 27 2021 Pavel Moravec <pmoravec@redhat.com> - 4.1-6
47940b
- [networking] collect also tc filter show ingress
47940b
  Resolves: bz1985976
47940b
- [cleaner] Only skip packaging-based files for the IP parser
47940b
  Resolves: bz1985982
47940b
- [sssd] sssd plugin when sssd-common
47940b
  Resolves: bz1967718
47940b
- Various OCP/cluster/cleanup enhancements
47940b
  Resolves: bz1985983
47940b
- [options] allow variant option names in config file
47940b
  Resolves: bz1985985
47940b
- [plugins] Set default predicate instead of None
47940b
  Resolves: bz1938874
47940b
- [MigrationResults] collect info about conversions and
47940b
  Resolves: bz1959779
47940b
47940b
* Wed Jun 02 2021 Pavel Moravec <pmoravec@redhat.com> - 4.1-4
47940b
- [archive] skip copying SELinux context for /proc and /sys everytime
47940b
  Resolves: bz1965002
47940b
- Load maps from all archives before obfuscation
47940b
  Resolves: bz1967110
47940b
- Multiple fixes in man pages
47940b
  Resolves: bz1967111
47940b
- [ds] Mask password and encryption keys in ldif files
47940b
  Resolves: bz1967112
47940b
- [report] add --cmd-timeout option
47940b
  Resolves: bz1967113
47940b
- [cups] Add gathering cups-browsed logs
47940b
  Resolves: bz1967114
47940b
- [sssd] Collect memory cache / individual logfiles
47940b
  Resolves: bz1967115
47940b
- Collect ibmvNIC dynamic_debugs
47940b
  Resolves: bz1967116
47940b
- [pulpcore] add plugin for pulp-3
47940b
  Resolves: bz1967117
47940b
- [saphana] remove redundant unused argument of get_inst_info
47940b
  Resolves: bz1967118
47940b
- [networking] Add nstat command support
47940b
  Resolves: bz1967119
47940b
- [snapper] add a new plugin
47940b
  Resolves: bz1967120
47940b
47940b
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 4.1-4
47940b
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
47940b
47940b
* Thu Apr 01 2021 Pavel Moravec <pmoravec@redhat.com> - 4.1-3
47940b
- adding sos-audit
47940b
- [gluster] Add glusterd public keys and status files
47940b
  Resolves: bz1925419 
47940b
47940b
* Wed Mar 10 2021 Sandro Bonazzola <sbonazzo@redhat.com> - 4.1-1
47940b
- Rebase to 4.1
47940b