Running gdb on Ubuntu 9.10 Apache2 Install

Posted by AJ on Server Fault See other posts from Server Fault or by AJ
Published on 2010-01-07T16:32:39Z Indexed on 2010/06/17 8:33 UTC
Read the original article Hit count: 532

Filed under:
|
|

Hi all,

I am trying to run gdb to debug my Ubuntu 9.10 Apache2 install and having a couple of problems:

  1. It seems like the package installed by Ubuntu for Apache2 does not include debugging symbols; is there a different version of the package I should be using for developing/debugging?

  2. When I try to run gdb, I get an error that looks to be caused by some missing environment variable. Are there additional options I should pass to "run" to get this to work?

Here is the output of the debugger session:

root@aj-ubuntu:/usr/sbin# gdb apache2
GNU gdb (GDB) 7.0-ubuntu
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /usr/sbin/apache2...(no debugging symbols found)...done.
(gdb) run -X
Starting program: /usr/sbin/apache2 -X
[Thread debugging using libthread_db enabled]
apache2: bad user name ${APACHE_RUN_USER}

Program exited with code 01.
(gdb)

Thanks in advance, -aj

© Server Fault or respective owner

Related posts about apache2

Related posts about ubuntu-9.10