From: Eckard Brauer <e.brauer@intershop.de>
To: gentoo-user-de@lists.gentoo.org
Subject: Re: [gentoo-user-de] Stacktrace einschalten?
Date: Mon, 26 Sep 2005 09:18:05 +0200 [thread overview]
Message-ID: <200509260918.14488.e.brauer@intershop.de> (raw)
In-Reply-To: <200509231437.51833.erik.wasser@iquer.net>
[-- Attachment #1: Type: text/plain, Size: 1711 bytes --]
Am Freitag, 23. September 2005 14:37 schrieb Erik Wasser:
> Stacktraces werden normalerweise vom Compiler mitgeführt, deshalb meine
> Frage nach den entsprechenden Compile-Optionen.
Bin kein Programmierer mehr und der Meinung, daß Stacktraces vom
Betriebssystem beim Eintreffen bestimmter Signale
(Speichersegment-Verletzung, unerlaubte Opcodes, Adressierungsfehler - also
alles Sachen, die auf systematische Fehler hinweisen und deshalb untersucht
werden sollten) erzeugt werden. Dabei wird das gesamte Prozeßabbild, d.h.
Code (Text) und initialisierte und allokierte Datenbereiche des Prozesses
(ausgeführtes Binary und Bibliotheken) auf Platte geschrieben (ggf. von ALLEN
Threads). Da das i.d.R. 'ne Menge Platz braucht, ist das normalerweise
ausgeschalten.
Der Compiler wird allerdings die Symboltabellen, die die Zuordnung
Speicherplatz <-> Symbolnamen ermöglichen, entfernen, wenn man nicht mit der
Option "-g" übersetzt hat. Debugging (von core-Dumps) ist dann immer noch
möglich, aber schwierig.
> Einen Stacktrace sieht man zum Beispiel unter http://tinyurl.com/8hayz
Is'n Backtrace, und damit normalerweise das erste, was man dem Debugger
entlockt. Hilft oft schon weit genug, aber beim core-Debugging kommt oft noch
'ne Menge mehr zur Anwendung...
zum "Einschalten": siehe "man ulimit; man proc"
# core-Dumps beliebiger Größe zulassen
ulimit -c unlimited
# das ganze etwas komfortabler machen :)
mkdir -p /tmp/cores
chmod 777 /tmp/cores
echo "/tmp/cores/core.%e.%p" > /proc/sys/kernel/core_pattern
Wenn noch 'was zu klären ist, ggf. per Privatmail, ich nehm' nicht an, daß das
viele Leute interessiert...
Viele Grüße
Eckard
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
prev parent reply other threads:[~2005-09-26 7:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-09-23 7:23 [gentoo-user-de] Stacktrace einschalten? Erik Wasser
2005-09-23 12:06 ` Peter Bossy
2005-09-23 12:37 ` Erik Wasser
2005-09-26 7:18 ` Eckard Brauer [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200509260918.14488.e.brauer@intershop.de \
--to=e.brauer@intershop.de \
--cc=gentoo-user-de@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox