diff options
Diffstat (limited to 'doc')
-rw-r--r-- | doc/DESIGN | 20 | ||||
-rw-r--r-- | doc/IMPLEMENTATION | 6 |
2 files changed, 13 insertions, 13 deletions
@@ -47,25 +47,25 @@ it to achieve design goals. Since currently we do not know how to dump oops on demand, we can only poll for it. There is a small daemon which polls kernel message buffer and dumps oopses when it sees them. -The dump is written into /var/cache/abrt/DIR. -After this, daemon spawns "abrt-process -d /var/cache/abrt/DIR" +The dump is written into /var/spool/abrt/DIR. +After this, daemon spawns "abrt-process -d /var/spool/abrt/DIR" which processes it according to configuration in /etc/abrt/*.conf. In order to catch binary crashes, we install a handler for it in /proc/sys/kernel/core_pattern (by setting it to -"|/usr/libexec/abrt-hook-ccpp /var/cache/abrt %p %s %u"). -When process dumps core, the dump is written into /var/cache/abrt/DIR. -After this, abrt-hook-ccpp spawns "abrt-process -d /var/cache/abrt/DIR" +"|/usr/libexec/abrt-hook-ccpp /var/spool/abrt %p %s %u"). +When process dumps core, the dump is written into /var/spool/abrt/DIR. +After this, abrt-hook-ccpp spawns "abrt-process -d /var/spool/abrt/DIR" and terminates. When python program crashes, it invokes internel python subroutine which dumps crash info into ~/abrt/cache/DIR. -[this is a tentative plan, currently we dump in /var/cache/abrt/DIR] +[this is a tentative plan, currently we dump in /var/spool/abrt/DIR] After this, it spawns "abrt-process -d ~/abrt/cache/DIR" and terminates. -[Problem: dumping to /var/cache/abrt/DIR needs world-writable -/var/cache/abrt and allows user to go way over his +[Problem: dumping to /var/spool/abrt/DIR needs world-writable +/var/spool/abrt and allows user to go way over his disk quota. Dumping to ~/abrt/cache/DIR makes it difficult to present a list of all crashes which happened on the machine - for example, root-owned processes cannot even access user data @@ -88,7 +88,7 @@ The key dbus calls served by abrt-process are: of crashes for given uid v[N]["executable"/"uid"/"kernel"/"backtrace"][N] = "contents" [see above the problem with producing this list] -- CreateReport(UUID): starts creating a report for /var/cache/abrt/DIR with this UUID. +- CreateReport(UUID): starts creating a report for /var/spool/abrt/DIR with this UUID. Returns job id (uint64). After it returns, when report creation thread has finished, JobDone(client_dbus_ID,UUID) dbus signal is emitted. @@ -101,7 +101,7 @@ The key dbus calls served by abrt-process are: - Report(map_crash_data_t (map_vector_string_t)): "Please report this crash": calls Report() of all registered reporter plugins Returns report_status_t (map_vector_string_t) - the status of each call -- DeleteDebugDump(UUID): delete corresponding /var/cache/abrt/DIR. Returns bool +- DeleteDebugDump(UUID): delete corresponding /var/spool/abrt/DIR. Returns bool Development plan diff --git a/doc/IMPLEMENTATION b/doc/IMPLEMENTATION index 62ad5786..72f12c72 100644 --- a/doc/IMPLEMENTATION +++ b/doc/IMPLEMENTATION @@ -8,7 +8,7 @@ the coredump of crashing app: * helper source code: http://git.fedorahosted.org/git/abrt.git?p=abrt.git;a=blob_plain;f=src/Hooks/abrt-hook-python.cpp the code responsible for this: - #define CORE_PATTERN "|/usr/libexec/abrt-hook-ccpp" "/var/cache/abrt" %p %s %u" + #define CORE_PATTERN "|/usr/libexec/abrt-hook-ccpp" "/var/spool/abrt" %p %s %u" ofstream fOutCorePattern; fOutCorePattern.open(CORE_PATTERN_IFACE); if (fOutCorePattern.is_open()) @@ -33,7 +33,7 @@ cmdline: char path[sizeof("/proc/%u/cmdline") + sizeof(int)*3]; sprintf(path, "/proc/%u/cmdline", (int)pid); -both is saved to file in /var/cache/abrt/ccpp-<time>-<pid> readable +both is saved to file in /var/spool/abrt/ccpp-<time>-<pid> readable only by owner the crashed process: int fd = open(pPath, O_WRONLY | O_TRUNC | O_CREAT, 0666); if(fd){ @@ -82,7 +82,7 @@ abrt-debuginfo-install is a shell script using elfutils to get build-ids from co - gdb is run with the same privileges as the crashed app (setregid, setreuid) d) BT is saved to same directory where the coredump is -Once the backtrace is processed all data from the /var/cache/abrt/ccpp-<time>-<pid> is sent +Once the backtrace is processed all data from the /var/spool/abrt/ccpp-<time>-<pid> is sent over dbus to the client and then user can edit the backtrace. When user is happy about the report and command the client (gui, tui) to send the it, the client sends the data back to the daemon calling the Report(data) method over the dbus. The actual reporting is done by |