On Thu, Jan 8, 2009 at 03:13, Brian Adams wrote:
>
> Hi,
>
> I just created a new dev box on Fedora 10 and I'm seeing something strange
> with httpd that I built from source. It's segfaulting constantly (even
> though I can get pages and modules to execute). If I look at a coredump I
> see this:
>
> (gdb) where
> #0 apr_pollset_add (pollset=0x0, descriptor=0xbf8aadec) at
> poll/unix/epoll.c:150
> #1 0x080bd161 in child_main (child_num_arg=) at
> prefork.c:532
> #2 0x080bd613 in make_child (s=0x8ee4830, slot=1) at prefork.c:746
> #3 0x080bdc9a in startup_children () at prefork.c:764
> #4 ap_mpm_run (_pconf=0x8edf550, plog=0x8f19638, s=0x8ee4830) at
> prefork.c:985
> #5 0x08069800 in main (argc=Cannot access memory at address 0x0
> ) at main.c:740
>
>
> Looks like apr_pollset_create is failing in prefork.c. Any ideas on why this
> would happen?
Here you have a part of the code of apr_pollset_create.
child_main calls this function with flags = 0 and size =
num_listeners. I don't know how num_listeners is initialised. Anyway,
"man epoll_create" says that the size argument is ignored by
epoll_create.
Anyway, I would recommend you to try a small program calling
epoll_create. It could be that you don't have a kernel compiled with
epoll (epoll_create returns -1).
APR_DECLARE(apr_status_t) apr_pollset_create(apr_pollset_t **pollset,
apr_uint32_t size,
apr_pool_t *p,
apr_uint32_t flags)
{
apr_status_t rv;
int fd;
fd = epoll_create(size);
if (fd < 0) {
*pollset = NULL;
return errno;
}
*pollset = apr_palloc(p, sizeof(**pollset));
// skipped the rest. If we reach here, pollset cannot be NULL anymore.
There's more code but "flags" being 0 makes sure that the code where
*pollset = NULL is not executed.
return APR_SUCCESS;
}
>
> Thanks for the help.
>
> Brian
>
--
A: Because it reverses the logical flow of conversation.
Q: Why is top-posting frowned upon?
A: Top-posting.
Q: What is the most annoying thing in e-mail?