httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Charles Randall <crand...@matchlogic.com>
Subject RE: Solaris 2.7 and getting a clean coredump
Date Thu, 02 Dec 1999 21:28:09 GMT
Here's what I do on Solaris 2.6 servers...

First, deploy a debuggable server.

Then, as root, issue this use the truss command with the undocumented -S
flag and the pid from /logs/httpd.pid (in this case 19669) and wait until
you get output that looks like the following:

% truss -f -l -t\!all -S SIGSEGV -p 19669 2>&1 | grep SEGV
25321/1:              siginfo: SIGSEGV SEGV_MAPERR addr=0x00000000
25321/1:            Received signal #11, SIGSEGV [caught]
25321/1:              siginfo: SIGSEGV SEGV_MAPERR addr=0x00000000

Hit Ctrl-C to interrupt your truss process and do what you wish with 25321.

For example, use pstack and gcore as shown here.

% /usr/proc/bin/pstack 25321
...

% gcore -o /tmp/httpd.core 25321 
gcore: /tmp/httpd.core.25321 dumped

Then kill 25321,

% kill -KILL 25321

If you don't kill the ones you stopped, they'll hang around forever (very,
very, bad).

Repeat until you have enough core files to find the problem.

FYI,
Charles

-----Original Message-----
From: Dirk-Willem van Gulik [mailto:dirkx@webweaving.org]
Sent: Thursday, December 02, 1999 1:58 PM
To: new-httpd@apache.org
Subject: Solaris 2.7 and getting a clean coredump



Anyone have any hints as how to proceed... apache bombs out with a
bus/segv's quite often.. and I'd like a core.

As we have 200+ active processes and 50 req/second attaching a debuger to
PID's is not an option.. kind of difficult to guess which one :-)

Now I've set/tried

	ulimit -c unlimited

	cd to the core-directory before startup

	CoreDumpDirectory ...
		

	the coredump directory is rw for the world. There is
	enough disk space.
	
A 'kill -SEGV' does not yield core's either, but a CGI like

	#/usr/local/bin/perl
	$|++;
	print "Content-type: text/plain\n\n"
	exec "ulimit -a; kill -SIGV $$";

produces one (of sh) just fine. Kind of suggesting that the inherited
child environment is fine. 

Of course the log nicely log's the child SIGV-ing in both cases. Even
though the SEGV of apache causes no core.

Any hints. Same setup dumps fine on BSD.

Any and all suggestions appreciated !

Dw

Mime
View raw message