Re: debugger question

From: "Murali M(dot) Krishna" <murali1729(at)yahoo(dot)com>
To: tomas(at)tuxteam(dot)de
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: debugger question
Date: 2010-04-13 05:32:11
Message-ID: 999599.216.qm@web52808.mail.re2.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

The OS is

Fedora 12.

-----------------------------------------------------------------
Please visit NumberFest.com for educational number puzzles & mind exercises for all ages! And please tell your friends about it. Thank You!

--- On Mon, 4/12/10, tomas(at)tuxteam(dot)de <tomas(at)tuxteam(dot)de> wrote:

From: tomas(at)tuxteam(dot)de <tomas(at)tuxteam(dot)de>
Subject: Re: [HACKERS] debugger question
To: "Murali M. Krishna" <murali1729(at)yahoo(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Date: Monday, April 12, 2010, 9:28 PM

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Mon, Apr 12, 2010 at 08:31:38PM -0700, Murali M. Krishna wrote:
> Hello:
>
> I am brand new to Postgresql.
>
> I ran the following commands.
> ./configure
> gmake
> su
> gmake install
> adduser postgres
> mkdir /usr/local/pgsql/data
> chown postgres /usr/local/pgsql/data
> su - postgres
> /usr/local/pgsql/bin/initdb -D /usr/local/pgsql/data
> /usr/local/pgsql/bin/postmaster -D /usr/local/pgsql/data >logfile 2>&1 &
> /usr/local/pgsql/bin/createdb test
> /usr/local/pgsql/bin/psql test
>
> I would like to start using gdb.
>
> What is the simplest way of doing this? I read the instructions
> on this page
>
> http://sites.google.com/a/cs.berkeley.edu/cs186-fa09/home/assignments/assignment2/pggdb
>
> , but this is what I get.
>
>
> gdb) attach 1731
> Attaching to program: /usr/local/pgsql/bin/postgres, process 1731
> ptrace: Operation not permitted.
> (gdb) break cost_seqscan
> Breakpoint 1 at 0x81cdf97: file costsize.c, line 163.
> (gdb) c
> The program is not being run.

Hm. Seems you got the right PID (gdb finds the executable after all).
Are you perhaps running under SELinux? (i just boldly assumed some
GNU/Linux). Which distribution, which kernel version (there seems to be
a bug in 2.4-ish Linux kernels which manifests itself like that, but
that's quite a while ago).

Next time, please tell us what OS is under you (although it might be fun
to watch people make wild guesses :)

Regards
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFLw/LTBcgs9XrR2kYRArYMAJ9JHu/Sl5JWSAv77om9HXHIzZtrDACZAWWu
fpk1yLbio8KOcWjTEWCXrK4=
=z0qo
-----END PGP SIGNATURE-----

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2010-04-13 05:44:19 Re: testing HS/SR - 1 vs 2 performance
Previous Message Greg Smith 2010-04-13 05:20:08 Re: GSoC - proposal - Materialized Views in PostgreSQL