On 06/05/2013 03:25 PM, Petr Holasek wrote:
> Hi Denys,
> I have some ideas about rasdaemon abrt hook
> and also following questions.
> Feel free to stop by or ping me, when you'll
> be in office, I'll be there till ~6PM today
> and afternoon tomorrow.
Currently we use Unix domain socket at
to support creation of problem data from crashing python
The socket accepts the following HTTP requests:
DELETE <problem_dir> HTTP/1.1
PUT / HTTP/1.1
DELETE request is straightforward, and anyway, you don't need it.
PUT request has the following form:
PUT / HTTP/1.1<CR><LF>
It appears that we misunderstood HTTP protocol and we should
have used POST instead of PUT. I am going to add POST alias
which works the same as PUT, and remove PUT sometime in the future.
For now, use PUT. The URI in PUT should be just /.
The headers following PUT line are currently ignored.
The body is NUL-delimited (not newline delimited!) set
of name-value pairs which describe the problem.
You can use any names which make sense for your problem
(for example, if someone is reporting an out-of-paper
problem with a printer, sending "printer_name=FOO" would make sense).
Some names *have* to be in the problem:
"type" describes what kind of the problem it is. Say, "Python"
is used by python crashes. You need to invent your own identifier(s)
for the problems you want to report. Say, "mem_error" for ECC/cache
errors, "bus_error" for PCI errors?
This field is used to differentiate abrt's response to a problem.
We don't want ECC errors reported to Bugzilla, right? :)
"reason" is a short, one-line, human-readable description of the problem,
suitable, for example, for showing in the list of problems. Examples
we currently see or use:
"<module>:ZeroDivisionError: integer division or modulo by zero"
"Segmentation fault at address 0x7ff6bf09e010"
"Process %s was killed by signal %s"
time=<unixtime in seconds> will be added automatically unless you supply it.
I looked thru the list of names we use and many don't make sense for you
(say, "uid" makes no sense for ECC errors :), but the following ones
may be useful:
comment=<long, multi-line description of the problem (if "reason" isn't enough)>
As I said, if you have more data to report, create your own name=value pair
to be saved.
Server will respond with
HTTP/1.1 <http_code> <CR><LF>
http_code will be 201 ("Created") on success.
Do you think you can use this interface from rasdaemon?
Once upon a time it was meant to allow addressing problems with @N
instead of full name. However, it is problematic - what the numbering
should be if e.g. --since DATE was used? Should we scan all directories
regardless because we want to show the same @N's as in full list?
Same problem with "--full List even reported problems" versus
I think git had a right idea: "shortcut" ID should be based on
substring match, not a numbering.
Signed-off-by: Denys Vlasenko <dvlasenk(a)redhat.com>
src/cli/list.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/src/cli/list.c b/src/cli/list.c
index 840d621..4ca334f 100644
@@ -82,7 +82,6 @@ static void print_crash_list(vector_of_problem_data_t *crash_list, int detailed,
- printf("@%i\n", i);
print_crash(crash, detailed, text_size);
if (i != crash_list->len - 1)