GDB Doesn't Recognize Core File Format

Discussion in 'C Programming' started by J. D. Leach, Dec 18, 2006.

  1. J. D. Leach

    J. D. Leach Guest

    I am not sure whether this would be considered off topic or not, but here
    goes.....don't flame me too bad.

    Running GNU GCC 4.0.1 and GDB 6.3. Was checking my compiler and debugger
    output prior to doing some coding in C when I discovered that GDB doesn't
    recognize the format of core dumps when I inject a segmentation fault. Was
    able to to set ulimit and get the dump OK, but when I tried to gather the
    error info by typing the following command: gdb ./crash_and_burn.c core, I
    get an error stating that the core file is in an unrecognized format.

    Come from a VB6 environment and am trying to learn C using the CLI and basic
    tools and functions. I seem to understand the material a little better when
    typing in the commands, and using a procedural technique, versus point and
    click and objects (must be from when I worked with mainframes with the
    military during the 70's).
    J. D. Leach
    Columbus, Indiana USA

    Linux/Open Source Computer using:
    Mandriva Linux release 2006.0 (Community) for i586 kernel 2.6.12-12mdk
    J. D. Leach, Dec 18, 2006
    1. Advertisements

  2. J. D. Leach

    loic-dev Guest

    Yes, that's OT. This NG is dedicated to the ISO C standard, and
    problems related to C programming. You should post on a dedicated NG
    for Linux development like comp.os.linux.development.apps for instance.

    Wrong. This should be:
    $ gdb executable core

    where /executable/ is the name of the executable (and not the name of
    the source file!) and /core/ the name of the core file.

    loic-dev, Dec 18, 2006
    1. Advertisements

  3. J. D. Leach

    J. D. Leach Guest

    Thanks. That was the problem. Using some old programming texts and the
    examples (this one anyway) are in error. In future will also post to the
    Linux newsgroup.

    I must be getting old and dotty. Incidences of cranio-rectal inversion are
    becoming all too frequent.
    J. D. Leach, Dec 18, 2006
  4. J. D. Leach

    Al Balmer Guest

    I don't know how you could be at all unsure that this is not off topic
    in a newsgroup about the C language. You need a group dealing with the
    implementation and operating system you're using. For lack of any
    other clues, I suggest you do a Google Groups search.
    Al Balmer, Dec 19, 2006
  5. J. D. Leach

    J. D. Leach Guest

    Let's see....hmmmmm. The language I am using is C, the debugger and compiler
    are used extensively for C, the test program was C. The text from which the
    testing procedure was based on, is a C programming volume (albeit heavily
    tilted toward *nix). It seemed reasonable given the veritable plethora of
    NG's from which to choose that a C specific group could at minimum point me
    in the right direction.
    Additionally, after joining this group approximately 3 weeks ago and viewing
    some of the posts, I did not feel the request for information was anymore
    asinine than others I have seen.

    Furthermore, I am slinging a little code as a hobby and as a pleasant
    diversion. An intellectual exercise to keep the synapses in trim, if you
    will. I do not code for a living, nor do I spend great quantities of time
    with my mug affixed to a computer screen, ergo I was not aware
    comp.os.linux.development existed. Due to the kindly advice provided by
    another NG member, I was politely advised of not only my error in posting,
    but of where such requests may be directed. Future posts concerning
    compiling and debugging issues I may encounter will be directed there.
    J. D. Leach, Dec 19, 2006
  6. J. D. Leach

    Al Balmer Guest

    It would take little research in this group to show that this
    particular argument bears no weight here. Your problem has nothing to
    do with the language.
    You have just shown one of the reasons why we try to be strict
    regarding topicality. The more that off-topic questions are allowed,
    the more other correspondents think it's OK.
    Which is precisely why I suggested a Google Groups search. From it,
    you could have learned about not only comp.os.linux.development but
    probably other venues which might be useful and educational. "Teach a
    man to fish ..." Your post did not indicate that you needed perpetual
    You were told only about one possibility. The Usenet universe is large
    and diverse, and exploring can be both usefule and entertaining.
    Al Balmer, Dec 19, 2006
  7. J. D. Leach

    J. D. Leach Guest

    Could you be a little more brusque and belittling? I sometimes don't do
    subtlety very well.

    Your arrogance and condescension is breathtaking. Had a professor at school
    some years back who conducted himself in much the same way as you have
    responded when he addressed student questions. Brilliant and very talented
    man. Published several software books through Sam's and other publishing
    houses. His tact (lack of) promoted a precipitous drop in enrollment in the
    CS classes he conducted. When he finally moved on to another campus, the
    relief of the student body at large was palpable.
    His difficulty in dealing with the kids was that he forgot what it was like
    to learn something new. He had dwelt in the digital world for so long that
    he assumed too much knowledge, experience, and skill, of his charges. What
    he needed to remind himself, and what I had to learn when managing my own
    firm in another industry, is to not assume much at all. Above all else, one
    has to remember that in software, as in virtually all other disciplines, it
    is the people that make it go.
    J. D. Leach, Dec 20, 2006
  8. J. D. Leach said:
    Yes, he can. :)

    It's an easy trap to fall into, as is the opposite - assuming that one's
    students are so dim that one has to go vveerryy sslloowwllyy if they are to
    keep up. Striking the right balance is not easy.
    Richard Heathfield, Dec 20, 2006
  9. J. D. Leach

    Al Balmer Guest

    Well, yes. I could have assumed that you were a dimwit incapable of
    learning. Instead, I'm assuming that you have the intelligence to
    educate yourself with minimal supervision. If you consider that
    belittling, you have problems I'm not qualified to advise on.

    As for brusque, I don't have time for pussy-footing and beating around
    the bush. Sorry.
    Al Balmer, Dec 20, 2006
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.