|
auther_bin
auther_bin at 21cn.com
Mon Mar 3 02:27:11 EST 2008
Hi Graham Dumpleton,
And, when I debug in RedHat9 and my embeded envirenment, the main process goes different!?
in Redhat9, run like:
(gdb) b main
Breakpoint 1 at 0x8067a40: file main.c, line 438.
(gdb) run -X
Starting program: /usr/local/apache2/bin/httpd -X
[New Thread 1076592288 (LWP 1049)]
[Switching to Thread 1076592288 (LWP 1049)]
Breakpoint 1, main (argc=134642240, argv=0x2) at main.c:438
438 {
(gdb) n
272 stat = apr_app_initialize(argc, argv, NULL);
and in my embeded system runs like:
Breakpoint 1, main (argc=2, argv=0xbffff294)
at /usr/src/build/snapgear/user/apache/server/main.c:441
441 int configtestonly = 0;
(gdb) n
442 const char *confname = SERVER_CONFIG_FILE;
it seems that, the hosting system doing something for init before the main function run, but embeded system do not?
I thinks is here somthing wrong? or there should be some compiling parameters I missed?
======= 2008-02-27 wrote: =======
>On 27/02/2008, auther_bin <auther_bin at 21cn.com > wrote:
> > Dear friends,
> >
> > When I compiling the apache python mod_python and install it into my uClibc envirentment,
but when I
> > runing httpd -X, send a very little request with index.html it crashed. after some debuging work,
I find there should be something wrong in mod_python.c line(about 1561) which looks like:
> > --------------------------------- with my debug printing :) ------------------------
> > printf("JJJJJJJJ %s - > python_handler\n", phase);
> > printf("JJJJJJJJ %x[%d]\n", &req- >per_dir_config, (&python_module)- >module_index);
> > /* get configuration */
> > conf = (py_config *) ap_get_module_config(req- >per_dir_config,
> > &python_module);
> > printf("JJJJJJJJ a %s conf=%x - > python_handler\n", phase,conf);
> > .............
> > ------------------------------ end source --------------------------------------
> >
> > I guess that, there should be a regester error in it. with some debug message I print:
> > ------------- printing -------------------------------
> > JJJJJJJJJ PythonPostReadRequestHandler
> > JJJJJJJJ PythonInitHandler - > python_handler
> > JJJJJJJJ 820a544[29]
> > Segmentation fault
> > ------------- end printing ---------------------------
> >
> > any advices pls?
>
>Unfortunately that doesn't help much.
>
>You need a stack trace to show the true location in code.
>
>Use procedure documented in section 'Debugging Crashes With GDB' of:
>
> http://code.google.com/p/modwsgi/wiki/DebuggingTechniques
>
>to run up httpd inside of gdb and get a stack trace of where crash is occurring.
>
>This documentation is for mod_wgsi, but same procedure used for mod_python.
>
>There is a similar procedure documented on Apache site, but can't
>remember where.
>
>Graham
>
>
>__________ NOD32 2906 (20080227) Information __________
>
>This message was checked by NOD32 antivirus system.
>http://www.nod32cn.com
>
>
= = = = = = = = = = = = = = = = = = = =
ÖÂ
Àñ£¡
2008-03-03
_______________________________________________
Mod_python mailing list
Mod_python at modpython.org
http://mailman.modpython.org/mailman/listinfo/mod_python
__________ NOD32 2915 (20080303) Information __________
This message was checked by NOD32 antivirus system.
http://www.nod32cn.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mm_cfg_has_not_been_edited_to_set_host_domains/pipermail/mod_python/attachments/20080303/0612e5c0/attachment.html
|