Multithreaded Python Mysql MAC Problems

Discussion in 'Python' started by Raja, Nov 13, 2007.

  1. Raja

    Raja Guest

    Hi All,
    I wrote a multithreaded crawler program in Python 2.4 using
    Mysql 5.045 and MySqldb version as MySql-Python 1.2.2 on MAC OS
    10.4.10 .

    The program strangely segfaults while it is running perfectly in
    Ubuntu and Windows as well.

    The gdb stack trace of program is below:

    LuLu:~/tempdownloads/crawl tspencer$ gdb python
    GNU gdb 6.1-20040303 (Apple version gdb-434) (Wed Nov 2 17:23:33 GMT
    2005)
    Copyright 2004 Free Software Foundation, Inc.
    GDB is free software, covered by the GNU General Public License, and
    you are
    welcome to change it and/or distribute copies of it under certain
    conditions.
    Type "show copying" to see the conditions.
    There is absolutely no warranty for GDB. Type "show warranty" for
    details.
    This GDB was configured as "i386-apple-darwin"...Reading symbols for
    shared libraries .. done

    (gdb) run FinalCrawler.py
    Starting program: /Library/Frameworks/Python.framework/Versions/2.4/
    bin/python FinalCrawler.py
    Reading symbols for shared libraries . done

    Program received signal SIGTRAP, Trace/breakpoint trap.
    0x8fe01010 in __dyld__dyld_start ()
    (gdb) bt
    #0 0x8fe01010 in __dyld__dyld_start ()
    (gdb) info threads
    * 1 process 19802 local thread 0xf03 0x8fe01010 in __dyld__dyld_start
    ()
    (gdb) continue
    Continuing.
    Reading symbols for shared libraries ... done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries .. done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries .. done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries ... done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    Reading symbols for shared libraries . done
    putting
    starting threads now !!!!
    putting
    putting
    putting
    putting
    putting
    putting
    putting
    putting
    putting
    3 Now after Lock acquired
    3 Now releasing lock

    Program received signal EXC_BAD_ACCESS, Could not access memory.
    Reason: KERN_PROTECTION_FAILURE at address: 0x00000090
    [Switching to process 19802 thread 0x1703]
    _db_return_ (_line_=95, _sfunc_=0xb0283f3c, _sfile_=0xb0283f38,
    _slevel_=0xb0283f34) at dbug.c:828
    828 state->framep = (char **) *state->framep;
    (gdb)


    The "putting" and number 3 are program's print statements.

    Can anyone please provide me with a insight into this problem and
    solution to it ? What might be the cause of this problem or how to go
    about further debugging it ?

    Thanks,
    Raja.
     
    Raja, Nov 13, 2007
    #1
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. R
    Replies:
    2
    Views:
    406
    Esmond Pitt
    Mar 15, 2005
  2. Flavio
    Replies:
    10
    Views:
    508
  3. Raja Pradeep Rokkam

    Multithreaded Python Mysql MAC Problems

    Raja Pradeep Rokkam, Nov 13, 2007, in forum: Python
    Replies:
    0
    Views:
    417
    Raja Pradeep Rokkam
    Nov 13, 2007
  4. K Richard Pixley
    Replies:
    3
    Views:
    366
    Ned Deily
    Jan 3, 2012
  5. Martin Kißner
    Replies:
    2
    Views:
    139
    Martin Kißner
    Oct 2, 2006
Loading...

Share This Page