bug reproduced, happens pretty quickly once I stressed httpd2 with siege ...

On 16 January 2016 at 19:48, Pedro de Oliveira <falsov...@gmail.com> wrote:
> Ignore what I said in the earlier email about "mpm_prefork", I wasnt
> using it. Sorry.
>
> It still crashes after a few requests. This is the backtrace from
> apache build with -O0 and -ggdb.
>
> # gdb --args httpd2 -X
> (gdb) run
> Starting program: /usr/local/sbin/httpd2 -X
> ...
> Program received signal SIGSEGV, Segmentation fault.
> 0x000018a9b2875638 in ap_mpm_pod_check (pod=0x0) at mpm_unix.c:459
> 459         rv = apr_file_read(pod->pod_in, &c, &len);
> (gdb) bt full
> #0  0x000018a9b2875638 in ap_mpm_pod_check (pod=0x0) at mpm_unix.c:459
>         c = -1 '▒'
>         len = 1
>         rv = 2
> #1  0x000018ac9892d3bb in child_main (child_num_arg=0, child_bucket=0)
> at prefork.c:732
>         current_conn = (conn_rec *) 0x18abbed08f00
>         csd = (void *) 0x18abb4508000
>         thd = (apr_thread_t *) 0x18ac9e058b40
>         osthd = 0x18abeee85920
>         ptrans = (apr_pool_t *) 0x18abc3acce00
>         allocator = (apr_allocator_t *) 0x18abe0001700
>         status = 0
>         i = -1
>         lr = (ap_listen_rec *) 0x18abfdd7be00
>         pollset = (apr_pollset_t *) 0x18abb4509e00
>         sbh = (ap_sb_handle_t *) 0x18abed2a6e40
>         bucket_alloc = (apr_bucket_alloc_t *) 0x18ac537a7028
>         last_poll_idx = 1
>         lockfile = 0x7f7ffffd4d20 "▒▒▒▒"
> #2  0x000018ac9892d4d5 in make_child (s=0x18ac45b90d00, slot=0,
> bucket=0) at prefork.c:767
>         pid = 1
> #3  0x000018ac9892dc2d in prefork_run (_pconf=0x18abc7307d00,
> plog=0x18abc7307700, s=0x18ac45b90d00) at prefork.c:979
>         index = 6316
>         remaining_children_to_start = 2134903585
>         i = 6315
> #4  0x000018a9b283a8b7 in ap_run_mpm (pconf=0x18abc7307d00,
> plog=0x18abc7307700, s=0x18ac45b90d00) at mpm_common.c:94
>         pHook = (ap_LINK_mpm_t *) 0x18abd5664000
>         n = 0
>         rv = -1
> #5  0x000018a9b28324a3 in main (argc=2, argv=0x7f7ffffd5158) at main.c:777
>         c = 88 'X'
>         showcompile = 0
>         showdirectives = 0
>         confname = 0x18a9b299083b "/etc/apache2/httpd2.conf"
>         def_server_root = 0x18a9b2990854 "/var/www"
>         temp_error_log = 0x0
>         error = 0x0
>         process = (process_rec *) 0x18ac9cb312c0
>         pconf = (apr_pool_t *) 0x18abc7307d00
>         plog = (apr_pool_t *) 0x18abc7307700
>         ptemp = (apr_pool_t *) 0x18abbb0bb800
>         pcommands = (apr_pool_t *) 0x18ac5cf89500
>         opt = (apr_getopt_t *) 0x18ac48aed600
>         rv = 0
>         mod = (module **) 0x18a9b2cac518
>         opt_arg = 0x0
>         signal_server = (apr_OFN_ap_signal_server_t *) 0x18a9b2875ee5
> <ap_signal_server>
>
>
>
> On Sat, Jan 16, 2016 at 7:28 PM, Michael McConville <mm...@mykolab.com> wrote:
>> Pedro de Oliveira wrote:
>>> Following your tips I built Apache with -O0 and the segfaults in
>>> "mpm_prefork" no longer happen. Maybe its a gcc optimization issue. I
>>> dont know which -O OpenBSD uses by default, but I will try it also
>>> with -O1 and report back.
>>
>> Remember, compiler optimizations can worsen the impact of undefined
>> behavior. That seems more likely than a compiler bug to me.
>

Reply via email to