diff --git a/SOURCES/0308-plugins-a-a-g-machine-id-use-dmidecode-command.patch b/SOURCES/0308-plugins-a-a-g-machine-id-use-dmidecode-command.patch new file mode 100644 index 0000000..7117ac7 --- /dev/null +++ b/SOURCES/0308-plugins-a-a-g-machine-id-use-dmidecode-command.patch @@ -0,0 +1,87 @@ +From 685bf3a4a05e02f628c19f23a60107b98b52d199 Mon Sep 17 00:00:00 2001 +From: Martin Kutlak +Date: Wed, 18 Apr 2018 17:12:17 +0200 +Subject: [PATCH] plugins: a-a-g-machine-id use dmidecode command + +python-dmidecode is broken on aarch64 [1] and the issue won't be fixed. +Recommendation is to use regular dmidecode command instead. + +Related to BZ#1566707 + +[1] https://bugzilla.redhat.com/show_bug.cgi?id=1509938 + +Signed-off-by: Martin Kutlak +--- + src/plugins/abrt-action-generate-machine-id | 40 ++++++++------------- + 1 file changed, 15 insertions(+), 25 deletions(-) + +diff --git a/src/plugins/abrt-action-generate-machine-id b/src/plugins/abrt-action-generate-machine-id +index 6f43258c..f843d773 100644 +--- a/src/plugins/abrt-action-generate-machine-id ++++ b/src/plugins/abrt-action-generate-machine-id +@@ -20,8 +20,10 @@ + """This module provides algorithms for generating Machine IDs. + """ + ++import os + import sys + from argparse import ArgumentParser ++from subprocess import check_output + import logging + + import hashlib +@@ -35,38 +37,26 @@ def generate_machine_id_dmidecode(): + + """ + +- try: +- import dmidecode +- except ImportError as ex: +- raise RuntimeError("Could not import dmidecode module: {0}" +- .format(str(ex))) +- +- dmixml = dmidecode.dmidecodeXML() +- # Fetch all DMI data into a libxml2.xmlDoc object +- dmixml.SetResultType(dmidecode.DMIXML_DOC) +- xmldoc = dmixml.QuerySection('all') ++ if not os.path.isfile("/usr/sbin/dmidecode"): ++ raise RuntimeError("Could not find dmidecode. It might not be available for this " \ ++ "architecture.") + +- # Do some XPath queries on the XML document +- dmixp = xmldoc.xpathNewContext() +- +- # What to look for - XPath expressions +- keys = ['/dmidecode/SystemInfo/Manufacturer', +- '/dmidecode/SystemInfo/ProductName', +- '/dmidecode/SystemInfo/SerialNumber', +- '/dmidecode/SystemInfo/SystemUUID'] ++ # What to look for ++ keys = ['system-manufacturer', ++ 'system-product-name', ++ 'system-serial-number', ++ 'system-uuid'] + + # Create a sha256 of ^ for machine_id + machine_id = hashlib.sha256() + +- # Run xpath expressions ++ # Run dmidecode command + for k in keys: +- data = dmixp.xpathEval(k) +- for d in data: +- # Update the hash as we find the fields we are looking for +- machine_id.update(d.get_content()) ++ data = check_output(["dmidecode", "-s", k]).strip() ++ ++ # Update the hash as we find the fields we are looking for ++ machine_id.update(data) + +- del dmixp +- del xmldoc + # Create sha256 digest + return machine_id.hexdigest() + +-- +2.17.1 + diff --git a/SOURCES/0310-a-a-s-p-data-fix-segfault-if-GPGKeysDir-isn-t-config.patch b/SOURCES/0310-a-a-s-p-data-fix-segfault-if-GPGKeysDir-isn-t-config.patch new file mode 100644 index 0000000..f531b88 --- /dev/null +++ b/SOURCES/0310-a-a-s-p-data-fix-segfault-if-GPGKeysDir-isn-t-config.patch @@ -0,0 +1,28 @@ +From c306d5e8681990f2aa9a56bca2866bd47d1c784f Mon Sep 17 00:00:00 2001 +From: Jakub Filak +Date: Tue, 10 Nov 2015 13:22:21 +0100 +Subject: [PATCH] a-a-s-p-data: fix segfault if GPGKeysDir isn't configured + +Related to #1591141 + +Signed-off-by: Jakub Filak +--- + src/daemon/abrt-action-save-package-data.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/daemon/abrt-action-save-package-data.c b/src/daemon/abrt-action-save-package-data.c +index ef2007ee..ef492c28 100644 +--- a/src/daemon/abrt-action-save-package-data.c ++++ b/src/daemon/abrt-action-save-package-data.c +@@ -88,7 +88,7 @@ static void load_gpg_keys(void) + } + + const char *gpg_keys_dir = get_map_string_item_or_NULL(settings, "GPGKeysDir"); +- if (strcmp(gpg_keys_dir, "") != 0) ++ if (gpg_keys_dir != NULL && strcmp(gpg_keys_dir, "") != 0) + { + log_debug("Reading gpg keys from '%s'", gpg_keys_dir); + GList *gpg_files = get_file_list(gpg_keys_dir, NULL /* we don't care about the file ext */); +-- +2.17.1 + diff --git a/SOURCES/0311-plugin-general-from-sos-has-been-split-into-two-new-.patch b/SOURCES/0311-plugin-general-from-sos-has-been-split-into-two-new-.patch new file mode 100644 index 0000000..56c98fd --- /dev/null +++ b/SOURCES/0311-plugin-general-from-sos-has-been-split-into-two-new-.patch @@ -0,0 +1,39 @@ +From f148242412cdffaf98150f3c85b717f06b0b312b Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Miroslav=20Such=C3=BD?= +Date: Fri, 17 Aug 2018 16:18:21 +0200 +Subject: [PATCH] plugin "general" from sos has been split into two new plugins + +This resolves BZ 1608444 +--- + abrt.spec.in | 1 + + src/daemon/abrt_event.conf | 2 +- + 2 files changed, 2 insertions(+), 1 deletion(-) + +diff --git a/abrt.spec.in b/abrt.spec.in +index 33e50005..44b06683 100644 +--- a/abrt.spec.in ++++ b/abrt.spec.in +@@ -79,6 +79,7 @@ BuildRequires: libselinux-devel + + Requires: libreport >= %{libreport_ver} + Requires: satyr >= 0.11 ++Requires: sos >= 3.6 + # these only exist on suse + %if 0%{?suse_version} + BuildRequires: dbus-1-glib-devel +diff --git a/src/daemon/abrt_event.conf b/src/daemon/abrt_event.conf +index 76d544ca..a8d03381 100644 +--- a/src/daemon/abrt_event.conf ++++ b/src/daemon/abrt_event.conf +@@ -73,7 +73,7 @@ EVENT=post-create + --only=filesys --only=hardware --only=kernel --only=libraries \ + --only=memory --only=networking --only=nfsserver --only=pam \ + --only=process --only=rpm -k rpm.rpmva=off --only=ssh \ +- --only=services --only=yum --only=general --only=x11 \ ++ --only=services --only=yum --only=date --only=host --only=x11 \ + --only=cups --only=logs --only=grub2 --only=cron --only=pci \ + --only=auditd --only=selinux --only=lvm2 --only=sar \ + --only=processor \ +-- +2.17.1 + diff --git a/SOURCES/event-don-t-run-the-reporter-bugzilla-h-on-RHEL-and-.patch b/SOURCES/event-don-t-run-the-reporter-bugzilla-h-on-RHEL-and-.patch deleted file mode 100644 index 334986f..0000000 --- a/SOURCES/event-don-t-run-the-reporter-bugzilla-h-on-RHEL-and-.patch +++ /dev/null @@ -1,29 +0,0 @@ -From 6c95ae2bf1c80530442a516f23b7cd8e82dcae12 Mon Sep 17 00:00:00 2001 -From: Matej Habrnal -Date: Thu, 22 Jan 2015 02:23:21 +0100 -Subject: [PATCH 88/91] event: don't run the 'reporter-bugzilla -h' on RHEL and - CentOS - -Running the 'reporter-bugzilla -h' makes sense only on Fedora because of bodhi. - -Signed-off-by: Matej Habrnal ---- - src/plugins/ccpp_event.conf | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/plugins/ccpp_event.conf b/src/plugins/ccpp_event.conf -index 62ff08a..cd75ee2 100644 ---- a/src/plugins/ccpp_event.conf -+++ b/src/plugins/ccpp_event.conf -@@ -71,7 +71,7 @@ EVENT=analyze_LocalGDB analyzer=CCpp - # Run GDB plugin to see if crash looks exploitable - abrt-action-analyze-vulnerability - # Run GDB to genereate backtrace -- abrt-action-analyze-ccpp-local --without-bodhi -+ abrt-action-analyze-ccpp-local --without-bz - - - # Bugzilla requires nonempty duphash --- -1.8.3.1 - diff --git a/SOURCES/plugin-set-URL-to-retrace-server.patch b/SOURCES/plugin-set-URL-to-retrace-server.patch deleted file mode 100644 index b2dc31a..0000000 --- a/SOURCES/plugin-set-URL-to-retrace-server.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 81181a893b91a229e05a5a915cc98347126e3834 Mon Sep 17 00:00:00 2001 -From: Matej Habrnal -Date: Fri, 30 Jan 2015 17:52:25 +0100 -Subject: [PATCH 90/91] plugin: set URL to retrace server - -Changed default retrace server URL from localhost to retrace.fedoraproject.org. - -Signed-off-by: Matej Habrnal ---- - src/plugins/analyze_CCpp.xml.in | 2 +- - src/plugins/analyze_RetraceServer.xml.in | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/src/plugins/analyze_CCpp.xml.in b/src/plugins/analyze_CCpp.xml.in -index 6f02692..a7ce4dd 100644 ---- a/src/plugins/analyze_CCpp.xml.in -+++ b/src/plugins/analyze_CCpp.xml.in -@@ -26,7 +26,7 @@ - - -diff --git a/src/plugins/analyze_RetraceServer.xml.in b/src/plugins/analyze_RetraceServer.xml.in -index cf1d25a..e437cac 100644 ---- a/src/plugins/analyze_RetraceServer.xml.in -+++ b/src/plugins/analyze_RetraceServer.xml.in -@@ -12,7 +12,7 @@ - - --- -1.8.3.1 - diff --git a/SOURCES/turn-sosreport-off.patch b/SOURCES/turn-sosreport-off.patch deleted file mode 100644 index e570138..0000000 --- a/SOURCES/turn-sosreport-off.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 2b02dc85753e4b11f10bfa2d660aa493ae80c52b Mon Sep 17 00:00:00 2001 -From: Jakub Filak -Date: Thu, 20 Nov 2014 11:24:39 +0100 -Subject: [PATCH] turn sosreport off - ---- - src/daemon/abrt_event.conf | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/daemon/abrt_event.conf b/src/daemon/abrt_event.conf -index 380b312..eafee17 100644 ---- a/src/daemon/abrt_event.conf -+++ b/src/daemon/abrt_event.conf -@@ -67,7 +67,7 @@ EVENT=post-create runlevel= - # Example: if you want to save sosreport immediately at the moment of a crash: - # (alternatively, you can add similar command to EVENT=analyze_foo's, - # if you would rather perform this collection later): --EVENT=post-create -+#EVENT=post-create - nice sosreport --tmp-dir "$DUMP_DIR" --batch \ - --only=anaconda --only=boot --only=devicemapper \ - --only=filesys --only=hardware --only=kernel --only=libraries \ --- -1.8.3.1 - diff --git a/SPECS/abrt.spec b/SPECS/abrt.spec index 4562ddb..f66dfbc 100644 --- a/SPECS/abrt.spec +++ b/SPECS/abrt.spec @@ -33,7 +33,7 @@ Summary: Automatic bug detection and reporting tool Name: abrt Version: 2.1.11 -Release: 50%{?dist} +Release: 52%{?dist} License: GPLv2+ Group: Applications/System URL: https://abrt.readthedocs.org/ @@ -54,6 +54,7 @@ Patch12: 0012-configui-show-Close-button-in-the-dialog.patch Patch13: 0013-applet-do-not-say-the-report-is-anonymous-when-urepo.patch #Patch14: 0014-spec-abrt-cli-requires-a-pkg-providing-workflows.patch #Patch15: 0015-testsuite-encourage-users-to-create-a-case-in-RHTS.patch +Patch16: 0016-cli-list-show-a-hint-about-creating-a-case-in-RHTS.patch Patch17: 0017-harvest-vmcore-properly-handle-inaccessible-dir-erro.patch Patch18: 0018-don-t-break-the-event-run-by-failures-of-abrt-action.patch Patch19: 0019-Fix-handling-of-Machine-Check-Exceptions.patch @@ -116,6 +117,7 @@ Patch75: 0075-Translation-updates.patch Patch76: 0076-Revert-gdb-disable-loading-of-auto-loaded-files.patch Patch77: 0077-gdb-make-gdb-aware-of-the-abrt-s-debuginfo-dir.patch #Patch78: 0078-spec-update-the-required-gdb-version.patch +Patch79: 0079-cli-mark-the-suggestion-text-for-translation.patch Patch80: 0080-auto-reporting-add-options-to-specify-auth-type.patch #Patch81: 0081-testsuite-abrt-auto-reporting-uReport-authentication.patch Patch82: 0082-translations-pull-the-newest-PO-files.patch @@ -375,11 +377,13 @@ Patch287: 0287-a-a-ureport-add-check-if-crash-is-from-packaged-exec.patch #Patch304: 0304-tests-cli-sanity-re-enable-report-non-reportable-pha.patch #Patch305: 0305-testsuite-fix-backtrace-verification-on-power.patch Patch306: 0306-a-harvest-vmcore-fix-regresion.patch -Patch307: event-don-t-run-the-reporter-bugzilla-h-on-RHEL-and-.patch -Patch308: plugin-set-URL-to-retrace-server.patch -Patch309: turn-sosreport-off.patch -# git format-patch 2.1.11-50.el7 -N --start-number 306 --topo-order - +# git format-patch 2.1.11-50.el7 -N --start-number 307 --topo-order +#Patch307: 0307-spec-use-dmidecode-instead-of-python-dmidecode.patch +Patch308: 0308-plugins-a-a-g-machine-id-use-dmidecode-command.patch +#Patch309: 0309-spec-turn-on-enable-native-unwinder-aarch64.patch +Patch310: 0310-a-a-s-p-data-fix-segfault-if-GPGKeysDir-isn-t-config.patch +# git format-patch 2.1.11-51.el7 -N --start-number 311 --topo-order +Patch311: 0311-plugin-general-from-sos-has-been-split-into-two-new-.patch # git is need for '%%autosetup -S git' which automatically applies all the # patches above. Please, be aware that the patches must be generated @@ -410,7 +414,7 @@ BuildRequires: libselinux-devel Requires: abrt-python = %{version}-%{release} Requires: libreport >= %{libreport_ver} Requires: satyr >= %{satyr_ver} -Requires: sos +Requires: sos >= 3.6 %if %{with systemd} Requires: systemd-units @@ -421,7 +425,9 @@ Requires: %{name}-python = %{version}-%{release} Requires(pre): shadow-utils Requires: python-augeas Requires: python-dbus -Requires: python-dmidecode +%ifarch aarch64 i686 x86_64 +Requires: dmidecode +%endif Requires: libreport-plugin-ureport >= %{libreport_ver} %if 0%{?rhel} Requires: libreport-plugin-rhtsupport @@ -492,8 +498,10 @@ Group: System Environment/Libraries Requires: cpio Requires: gdb >= 7.6.1-63 Requires: elfutils +%if 0%{!?rhel:1} # abrt-action-perform-ccpp-analysis wants to run analyze_RetraceServer: Requires: %{name}-retrace-client +%endif Requires: %{name} = %{version}-%{release} Requires: abrt-libs = %{version}-%{release} Requires: libreport-python @@ -608,13 +616,8 @@ Requires: abrt-addon-ccpp Requires: abrt-addon-python Requires: abrt-addon-xorg %if 0%{?rhel} -%if 0%{?centos_ver} -Requires: libreport-centos >= %{libreport_ver} -Requires: libreport-plugin-mantisbt >= %{libreport_ver} -%else Requires: libreport-rhel >= %{libreport_ver} Requires: libreport-plugin-rhtsupport >= %{libreport_ver} -%endif %else Requires: abrt-retrace-client Requires: libreport-plugin-bugzilla >= %{libreport_ver} @@ -647,13 +650,8 @@ Requires: elfutils Requires: abrt-gui Requires: gnome-abrt %if 0%{?rhel} -%if 0%{?centos_ver} -Requires: libreport-centos >= %{libreport_ver} -Requires: libreport-plugin-mantisbt >= %{libreport_ver} -%else Requires: libreport-rhel >= %{libreport_ver} Requires: libreport-plugin-rhtsupport >= %{libreport_ver} -%endif %else Requires: abrt-retrace-client Requires: libreport-plugin-bugzilla >= %{libreport_ver} @@ -732,7 +730,7 @@ autoconf CFLAGS="%{optflags} -Werror -Wno-error=deprecated-declarations" %configure --enable-doxygen-docs \ --disable-silent-rules \ --without-bodhi \ -%ifnarch arm armhfp armv7hl armv7l aarch64 +%ifnarch %{arm} --enable-native-unwinder \ %endif --enable-dump-time-unwind \ @@ -1213,14 +1211,16 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %config(noreplace) %{_sysconfdir}/profile.d/abrt-console-notification.sh %changelog -* Tue Apr 10 2018 CentOS Sources - 2.1.11-50.el7.centos -- Drop RHTS hint -- Change by David Mansfield -- Per http://bugs.centos.org/view.php?id=7192 -- Remove cli suggestion text patch -- set URL to retrace server -- update to not run sosreport -- Per http://bugs.centos.org/view.php?id=7913 +* Mon Aug 20 2018 Matej Habrnal - 2.1.11-52 +- plugin "general" from sos has been split into two new plugins +- Related: #1608444 + +* Mon Jun 25 2018 Matej Marusak - 2.1.11-51 +- a-a-s-p-data: fix segfault if GPGKeysDir isn't configured +- spec: turn on --enable-native-unwinder aarch64 +- plugins: a-a-g-machine-id use dmidecode command +- spec: use dmidecode instead of python-dmidecode +- Related: #1566707, #1566707, #1260074, #1591141 * Thu Feb 8 2018 Martin Kutlak - 2.1.11-50 - vmcore: fix analyzer regression