summaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorKarel Klic <kklic@redhat.com>2011-05-12 10:43:57 +0200
committerKarel Klic <kklic@redhat.com>2011-05-12 10:43:57 +0200
commit5f42aa585aa9307872c74cf1bae5a852e3a75005 (patch)
tree7b4b8b1f2951db833e5315c8d448f5a12a3cec7f /src/plugins
parentdc8318402cf793c4bce1a1a5e39c60a2d3bc917e (diff)
parent5f05e82e179275da7b0c29fbba4ab42e32035a9d (diff)
downloadabrt-5f42aa585aa9307872c74cf1bae5a852e3a75005.tar.gz
abrt-5f42aa585aa9307872c74cf1bae5a852e3a75005.tar.xz
abrt-5f42aa585aa9307872c74cf1bae5a852e3a75005.zip
Merge branch 'master' of ssh://git.fedorahosted.org/git/abrt
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/Makefile.am20
-rw-r--r--src/plugins/abrt-Bugzilla.743
-rw-r--r--src/plugins/abrt-Logger.744
-rw-r--r--src/plugins/abrt-Mailx.757
-rw-r--r--src/plugins/abrt-action-bugzilla.txt96
-rw-r--r--src/plugins/abrt-action-list-dsos.txt44
-rw-r--r--src/plugins/abrt-action-mailx.txt2
-rw-r--r--src/plugins/abrt-retrace-client.c4
-rw-r--r--src/plugins/abrt_rh_support.c2
-rw-r--r--src/plugins/analyze_LocalGDB.xml.in1
-rw-r--r--src/plugins/analyze_RetraceServer.xml.in1
-rw-r--r--src/plugins/analyze_xsession_errors.xml.in10
-rw-r--r--src/plugins/ccpp_events.conf54
13 files changed, 195 insertions, 183 deletions
diff --git a/src/plugins/Makefile.am b/src/plugins/Makefile.am
index bfa60903..1ef7fbc2 100644
--- a/src/plugins/Makefile.am
+++ b/src/plugins/Makefile.am
@@ -40,6 +40,7 @@ dist_events_DATA = \
report_Logger.conf \
analyze_LocalGDB.xml \
analyze_RetraceServer.xml \
+ analyze_xsession_errors.xml \
report_Mailx.xml \
report_RHTSupport.xml \
report_Kerneloops.xml
@@ -55,10 +56,7 @@ dist_eventsconf_DATA = \
rhtsupport_events.conf
man_MANS = \
- abrt-Bugzilla.7 \
abrt-KerneloopsReporter.7 \
- abrt-Logger.7 \
- abrt-Mailx.7 \
abrt-Upload.7 \
abrt-plugins.7
@@ -67,13 +65,15 @@ MAN_TXT = \
abrt-action-trim-files.txt \
abrt-action-generate-backtrace.txt \
abrt-action-analyze-backtrace.txt \
- abrt-action-mailx.txt
+ abrt-action-mailx.txt \
+ abrt-action-bugzilla.txt \
+ abrt-action-list-dsos.txt
# Manual pages are generated from .txt via Docbook
man1_MANS = ${MAN_TXT:%.txt=%.1}
%.1 %.5 %.7: %.xml
- $(XMLTO_SILENT) xmlto man $< > /dev/null 2>&1
+ $(XMLTO_SILENT) xmlto man $< 2>&1 | sed '/Note/d'
%.xml: %.txt ../../asciidoc.conf
$(ASCIIDOC_SILENT) asciidoc --backend=docbook --doctype=manpage --conf-file ../../asciidoc.conf -aabrt_version=$(PACKAGE_VERSION) -o $@ $<
@@ -90,11 +90,13 @@ EXTRA_DIST = \
$(man_MANS) \
$(MAN_TXT) \
$(PYTHON_FILES) \
+ $(man1_MANS) \
+ analyze_xsession_errors.xml.in \
+ analyze_LocalGDB.xml.in \
+ analyze_RetraceServer.xml.in \
report_Bugzilla.xml.in \
report_Bugzilla.conf \
report_Logger.conf \
- analyze_LocalGDB.xml.in \
- analyze_RetraceServer.xml.in \
report_Mailx.xml.in \
report_RHTSupport.xml.in \
report_Kerneloops.xml.in
@@ -102,10 +104,6 @@ EXTRA_DIST = \
$(DESTDIR)/$(DEBUG_INFO_DIR):
$(mkdir_p) '$@'
-install-data-hook: $(DESTDIR)/$(DEBUG_INFO_DIR)
- $(LN_S) -f analyze_RetraceServer.xml $(DESTDIR)$(eventsdir)/reanalyze_RetraceServer.xml
- $(LN_S) -f analyze_LocalGDB.xml $(DESTDIR)$(eventsdir)/reanalyze_LocalGDB.xml
-
abrt_dump_oops_SOURCES = \
abrt-dump-oops.c
abrt_dump_oops_CPPFLAGS = \
diff --git a/src/plugins/abrt-Bugzilla.7 b/src/plugins/abrt-Bugzilla.7
deleted file mode 100644
index 708695c7..00000000
--- a/src/plugins/abrt-Bugzilla.7
+++ /dev/null
@@ -1,43 +0,0 @@
-.TH abrt "7" "1 Jun 2009" ""
-.SH NAME
-Bugzilla plugin for abrt(8)
-.SH DESCRIPTION
-.P
-.I abrt
-is a daemon that watches for application crashes. When a crash occurs,
-it collects the problem data and takes action according to
-its configuration. This manual page describes the \fIBugzilla\fP plugin
-for \fIabrt\fP.
-.P
-This plugin is used to report the crash to a Bugzilla instance. The
-plugin will determine the package name and distribution version. The
-problem data is attached to the bug report.
-.SH INVOCATION
-The plugin is invoked in the \fIabrt.conf\fP configuration file.
-No parameters are necessary.
-.SH CONFIGURATION
-The \fIBugzilla.conf\fP configuration file contains several
-entries in the format "Option = Value". The options are:
-.SS BugzillaURL
-The URL of the Bugzilla instance that you want to use, including the
-path to the xmlrpc. The default is https://bugzilla.redhat.com/xmlrpc.cgi
-.SS Login
-Your Bugzilla login. If you have no Bugzilla account, you cannot
-use the plugin.
-.SS Password
-Your Bugzilla password.
-.SH EXAMPLES
-.P
-This is a snippet from the \fIabrt.conf\fP configuration file.
-When something crashes, use the Bugzilla plugin:
-.P
-[common]
-.br
-ActionsAndReporters = Bugzilla
-.SH "SEE ALSO"
-.IR abrt (8),
-.IR abrt.conf (5),
-.IR abrt-plugins (7)
-.SH AUTHOR
-Written by Zdenek Prikryl <zprikryl@redhat.com>.
-Manual page written by Daniel Novotny <dnovotny@redhat.com>.
diff --git a/src/plugins/abrt-Logger.7 b/src/plugins/abrt-Logger.7
deleted file mode 100644
index a9fbae09..00000000
--- a/src/plugins/abrt-Logger.7
+++ /dev/null
@@ -1,44 +0,0 @@
-.TH abrt "7" "1 Jun 2009" ""
-.SH NAME
-Logger plugin for abrt(8)
-.SH DESCRIPTION
-.P
-.I abrt
-is a daemon that watches for application crashes. When a crash occurs,
-it collects the problem data and takes action according to
-its configuration. This manual page describes the \fILogger\fP plugin
-for \fIabrt\fP.
-.P
-This plugin is used to log the crash to a file.
-.P
-The log will contain all the file names as well as their
-content. It also contains "duplicity check": the ID
-of the crash, which is used to tell whether the same
-crash has happened previously.
-.SH INVOCATION
-The plugin is invoked in the \fIabrt.conf\fP configuration file.
-No parameters are necessary.
-.SH CONFIGURATION
-The \fILogger.conf\fP configuration file contains
-several entries in a format "Option = Value". The options are:
-.SS LogPath
-The path to the log file.
-.SS AppendLogs
-If set to "yes" (the default) \fILogger\fP will append
-the report to the file, otherwise it will overwrite the file (so
-only the last crash will be stored).
-.SH EXAMPLES
-.P
-This is a snippet from the \fIabrt.conf\fP configuration file.
-Log all the C/C++ application crashes:
-.P
-[AnalyzerActionsAndReporters]
-.br
-CCpp = Logger
-.SH "SEE ALSO"
-.IR abrt (8),
-.IR abrt.conf (5),
-.IR abrt-plugins (7)
-.SH AUTHOR
-Written by Zdenek Prikryl <zprikryl@redhat.com>. Manual
-page by Daniel Novotny <dnovotny@redhat.com>.
diff --git a/src/plugins/abrt-Mailx.7 b/src/plugins/abrt-Mailx.7
deleted file mode 100644
index 1f2f08fc..00000000
--- a/src/plugins/abrt-Mailx.7
+++ /dev/null
@@ -1,57 +0,0 @@
-.TH abrt "7" "1 Jun 2009" ""
-.SH NAME
-Mailx plugin for abrt(8)
-.SH DESCRIPTION
-.P
-.I abrt
-is a daemon that watches for application crashes. When a crash occurs,
-it collects the problem data and takes action according to
-its configuration. This manual page describes the \fIMailx\fP plugin
-for \fIabrt\fP.
-.P
-This plugin is used to mail the data about the crash
-to a specified mail address.
-.SH INVOCATION
-The plugin is invoked in the \fIabrt.conf\fP configuration file. It can take
-one parameter, a subject of the mail (if it differs from the
-one specified in the \fIMailx.conf\fP configuration file).
-.SH CONFIGURATION
-The \fIMailx.conf\fP configuration file contains
-several entries in a format "Option = Value". The options are:
-.SS Subject
-The subject of the mail.
-.SS Parameters
-The \fIMailx\fP plugin executes the external "mailx" command to
-send the mail. This option defines some additional command line
-parameters, which should be added to the program invocation, if any.
-.SS EmailFrom
-The address from which the email is sent.
-.SS EmailTo
-The address to which the email is sent.
-.SS SendBinaryData
-Can be "yes" or "no". If set to "yes", the email will also
-contain the binary files associated with the crash. Warning:
-this can cause the emails to be large! (several MB)
-.SH EXAMPLES
-.P
-These are snippets from the \fIabrt.conf\fP configuration file.
-.P
-1) Each time a crash happens, a mail is sent
-.PP
-[common]
-.br
-ActionsAndReporters = Mailx("[abrt] a crash occurs")
-.P
-2) When a program in a specific package (in this case "httpd") crashes,
-send a mail about it.
-.PP
-[AnalyzerActionsAndReporters]
-.br
-CCpp:httpd = Mailx("[abrt] Apache crash")
-.SH "SEE ALSO"
-.IR abrt (8),
-.IR abrt.conf (5),
-.IR abrt-plugins (7)
-.SH AUTHOR
-Written by Zdenek Prikryl <zprikryl@redhat.com>. Manual
-page by Daniel Novotny <dnovotny@redhat.com>.
diff --git a/src/plugins/abrt-action-bugzilla.txt b/src/plugins/abrt-action-bugzilla.txt
new file mode 100644
index 00000000..313e5b19
--- /dev/null
+++ b/src/plugins/abrt-action-bugzilla.txt
@@ -0,0 +1,96 @@
+abrt-action-buzilla(1)
+====================
+
+NAME
+----
+abrt-action-bugzilla - Sends problem information to bugzilla.
+
+SYNOPSIS
+--------
+'abrt-action-bugzilla' [-v] [-c CONFFILE] -d DIR
+
+DESCRIPTION
+-----------
+The tool reads a problem dump direcotry. Firstly, the tool is trying to find
+duplication of bug. If duplication is 'not' found, then a new bug is created.
+Otherwise if duplication 'is' found and bug is closed as duplication of the
+other bug, than, so called, 'hoping' begin. It means, that tool is going to try
+track the origin bug.
+
+Example of bug stages are:
+------------
+CLOSED DUPLICATE -> CLOSED DUPLICATE -> NEW
+------------
+Third one is the origin of the same problem. The tool adds a new comment to bug,
+logouts from bugzilla and return link to bug.
+
+Properties of bugzilla can be specified in a configuration file,
+and via environment variables.
+
+Configuration file
+~~~~~~~~~~~~~~~~~~
+Configuration file contains entries in a format "Option = Value".
+
+The options are:
+
+'Login'::
+ Login to Bugzilla account.
+
+'Password'::
+ Password to Bugzilla account.
+
+'BugzillaURL'::
+ Bugzilla http address. (default: https://bugzilla.redht.com)
+
+'SSLVerify'::
+ Use yes/true/on/1 to verify Bugzilla ssl certificate. (default: yes)
+
+Integration with ABRT events
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+'abrt-action-bugzilla' can be used as a reporter, to allow users report
+problems to bugzilla when they decide to do it. This usage is
+pre-configured in /etc/abrt/events.d/ccpp_events.conf and
+/etc/abrt/abrt_events.conf.
+
+For python problems (/etc/abrt/abrt_events.conf)
+------------
+EVENT=report_Bugzilla analyzer=Python
+ abrt-action-bugzilla -c /etc/abrt/plugins/Bugzilla.conf
+------------
+
+For C/C++ problems (/etc/abrt/events.d/ccpp_events.conf)
+------------
+EVENT=report_Bugzilla analyzer=CCpp
+ abrt-action-bugzilla -c /etc/abrt/plugins/Bugzilla.conf
+------------
+
+OPTIONS
+-------
+-d DIR::
+ Path to dump directory.
+
+-c CONFFILE::
+ Path to configration file. When used in ABRT event system, the file
+ contains site-wide configuration. Users can change the values via
+ environment variables.
+
+ENVIRONMENT VARIABLES
+---------------------
+Environment variables take precedence over values provided in
+the configuration file.
+
+'Bugzilla_Login'::
+ Login to Bugzilla account.
+
+'Bugzilla_Password'::
+ Password to Bugzilla account.
+
+'Bugzilla_BugzillaURL'::
+ Bugzilla http address. (default: https://bugzilla.redht.com)
+
+'Bugzilla_SSLVerify'::
+ Use yes/true/on/1 to verify Bugzilla ssl certificate. (default: yes)
+
+AUTHORS
+-------
+* ABRT team
diff --git a/src/plugins/abrt-action-list-dsos.txt b/src/plugins/abrt-action-list-dsos.txt
new file mode 100644
index 00000000..18d10708
--- /dev/null
+++ b/src/plugins/abrt-action-list-dsos.txt
@@ -0,0 +1,44 @@
+abrt-action-list-dsos(1)
+======================
+
+NAME
+----
+abrt-action-list-dsos - Prints out DSO from mapped memory regions.
+
+SYNOPSIS
+--------
+'abrt-action-list-dsos' [-o OUTFILE] -m PROC_PID_MAP_FILE
+
+DESCRIPTION
+-----------
+The tool reads a file containing the mapped memory regions.
+Output is printed to 'stdout' or 'file'.
+
+Output format:
+
+------------
+%p %n %v %i
+------------
+where
+
+'%p'::
+ path to library or binary file, which is mapped in memory region
+'%n'::
+ name, version, release, architecture of package, where '%p' belongs
+'%v'::
+ vendor of package
+'%i'::
+ installation time
+
+OPTIONS
+-------
+-o OUTFILE::
+ Output file, if not specified, it is printed to 'stdout'
+
+-m PROC_PID_MAP_FILE::
+ File containing the mapped memory regions
+
+AUTHORS
+-------
+* ABRT team
+
diff --git a/src/plugins/abrt-action-mailx.txt b/src/plugins/abrt-action-mailx.txt
index 2fb11bef..a12c2bf1 100644
--- a/src/plugins/abrt-action-mailx.txt
+++ b/src/plugins/abrt-action-mailx.txt
@@ -53,7 +53,7 @@ problem happens. When this is desired, modify the event configuration
file to run the tool on the 'post-create' event:
------------
-EVENT=post-create abrt-action-mailx
+EVENT=post-create abrt-action-mailx
------------
OPTIONS
diff --git a/src/plugins/abrt-retrace-client.c b/src/plugins/abrt-retrace-client.c
index aa232475..524fa186 100644
--- a/src/plugins/abrt-retrace-client.c
+++ b/src/plugins/abrt-retrace-client.c
@@ -103,7 +103,7 @@ static int create_archive(bool unlink_temp)
xmove_fd(tar_xz_pipe[0], STDIN_FILENO);
xdup2(tempfd, STDOUT_FILENO);
execvp(xz_args[0], (char * const*)xz_args);
- perror_msg("Can't execute '%s'", xz_args[0]);
+ perror_msg("Can't execute '%s'", xz_args[0]);
}
close(tar_xz_pipe[0]);
@@ -130,7 +130,7 @@ static int create_archive(bool unlink_temp)
xmove_fd(xopen("/dev/null", O_RDWR), STDIN_FILENO);
xmove_fd(tar_xz_pipe[1], STDOUT_FILENO);
execvp(tar_args[0], (char * const*)tar_args);
- perror_msg("Can't execute '%s'", tar_args[0]);
+ perror_msg("Can't execute '%s'", tar_args[0]);
}
close(tar_xz_pipe[1]);
diff --git a/src/plugins/abrt_rh_support.c b/src/plugins/abrt_rh_support.c
index 9a48485b..b83f041e 100644
--- a/src/plugins/abrt_rh_support.c
+++ b/src/plugins/abrt_rh_support.c
@@ -421,7 +421,7 @@ send_report_to_new_case(const char* baseURL,
atch_state->http_resp_code,
errmsg ? ": " : "",
errmsg ? errmsg : ""
- );
+ );
break;
case 200:
diff --git a/src/plugins/analyze_LocalGDB.xml.in b/src/plugins/analyze_LocalGDB.xml.in
index 925f2c41..4f7ccce1 100644
--- a/src/plugins/analyze_LocalGDB.xml.in
+++ b/src/plugins/analyze_LocalGDB.xml.in
@@ -5,4 +5,5 @@
<_long-description>Needs to downloads debuginfo packages, which might take significant time, and take up disk space.
However, unlike RetraceServer, doesn't send coredump to remote machines.
</_long-description>
+ <creates-elements>backtrace</creates-elements>
</event>
diff --git a/src/plugins/analyze_RetraceServer.xml.in b/src/plugins/analyze_RetraceServer.xml.in
index 497fa13e..d2072db5 100644
--- a/src/plugins/analyze_RetraceServer.xml.in
+++ b/src/plugins/analyze_RetraceServer.xml.in
@@ -6,6 +6,7 @@
Pros: no need for debuginfo downloads. Retrace server's database of debuginfos is more complete. Retrace server may generate better backtraces.
Cons: coredump you upload contains all the data from the crashed program, including your private data, if any.
</_long-description>
+ <creates-elements>backtrace</creates-elements>
<options>
<option type="text" name="RETRACE_SERVER_URL">
<_label>Retrace server URL</_label>
diff --git a/src/plugins/analyze_xsession_errors.xml.in b/src/plugins/analyze_xsession_errors.xml.in
new file mode 100644
index 00000000..9f7a46bf
--- /dev/null
+++ b/src/plugins/analyze_xsession_errors.xml.in
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<event>
+ <name>Collect .xsession-errors</name>
+ <_description>Save relevant lines from ~/.xsession-errors file</_description>
+ <_long-description>
+ Scans through ~/.xsession-errors file and saves those lines which contain executable's name.
+ The result is saved as 'xsession_errors' element.
+ </_long-description>
+ <creates-elements>xsession_errors</creates-elements>
+</event>
diff --git a/src/plugins/ccpp_events.conf b/src/plugins/ccpp_events.conf
index 0f574713..eb3384a6 100644
--- a/src/plugins/ccpp_events.conf
+++ b/src/plugins/ccpp_events.conf
@@ -1,31 +1,37 @@
EVENT=post-create analyzer=CCpp
- abrt-action-analyze-c &&
- abrt-action-list-dsos.py -m maps -o dsos
+ abrt-action-analyze-c &&
+ abrt-action-list-dsos.py -m maps -o dsos &&
+ (
+ # Try to save relevant log lines.
+ # Can't do it as analyzer step, non-root can't read log.
+ # It's not an error if /var/log/messages isn't readable:
+ test -f /var/log/messages || exit 0
+ test -r /var/log/messages || exit 0
+ executable=`cat executable` &&
+ base_executable=${executable##*/} &&
+ grep -e "$base_executable" /var/log/messages | tail -999 >var_log_messages &&
+ echo "Element 'var_log_messages' saved"
+ )
+
+EVENT=analyze_xsession_errors analyzer=CCpp
+ test -f ~/.xsession-errors || { echo "No ~/.xsession-errors"; exit 1; }
+ test -r ~/.xsession-errors || { echo "Can't read ~/.xsession-errors"; exit 1; }
+ executable=`cat executable` &&
+ base_executable=${executable##*/} &&
+ grep -e "$base_executable" ~/.xsession-errors | tail -999 >xsession_errors &&
+ echo "Element 'xsession_errors' saved"
-# We run analyze_foo steps only if backtrace is empty (not yet generated):
# TODO: can we still specify additional directories to search for debuginfos,
# or was this ability lost with move to python installer?
-EVENT=analyze_LocalGDB analyzer=CCpp backtrace=
- abrt-action-analyze-core.py --core=coredump -o build_ids &&
- abrt-action-install-debuginfo --size_mb=4096 &&
- abrt-action-generate-backtrace &&
- abrt-action-analyze-backtrace
-
-EVENT=analyze_RetraceServer analyzer=CCpp backtrace=
- abrt-retrace-client batch --dir "$DUMP_DIR" &&
- abrt-action-analyze-backtrace
-
-# Same as "analyze", but executed when user requests "refresh" in GUI
-# It doesn't check that backtrace is empty:
-EVENT=reanalyze_LocalGDB analyzer=CCpp
- abrt-action-analyze-core.py --core=coredump -o build_ids &&
- abrt-action-install-debuginfo --size_mb=4096 &&
- abrt-action-generate-backtrace &&
- abrt-action-analyze-backtrace
+EVENT=analyze_LocalGDB analyzer=CCpp
+ abrt-action-analyze-core.py --core=coredump -o build_ids &&
+ abrt-action-install-debuginfo --size_mb=4096 &&
+ abrt-action-generate-backtrace &&
+ abrt-action-analyze-backtrace
-EVENT=reanalyze_RetraceServer analyzer=CCpp
- abrt-retrace-client batch --dir "$DUMP_DIR" &&
- abrt-action-analyze-backtrace
+EVENT=analyze_RetraceServer analyzer=CCpp
+ abrt-retrace-client batch --dir "$DUMP_DIR" &&
+ abrt-action-analyze-backtrace
EVENT=report_Bugzilla analyzer=CCpp
- abrt-action-bugzilla -c /etc/abrt/plugins/Bugzilla.conf
+ abrt-action-bugzilla -c /etc/abrt/plugins/Bugzilla.conf