httpd request processing is slowed in mod_negotiation
Issue
- httpd has long running requests. Debug logs of a request shows a large gap of no logs between the request being received and proceeding through initial authorization checks:
[Mon Jul 31 14:34:27.110516 2023] [ssl:debug] [pid 3211807:tid 139728774756096] ssl_engine_kernel.c(422): [client 127.0.0.1:52278] AH02034: Initial (No.1) HTTPS request received for child 1763 (server localhost:443)
[Mon Jul 31 14:39:21.756522 2023] [authz_core:debug] [pid 3211807:tid 139728774756096] mod_authz_core.c(820): [client 127.0.0.1:52278] AH01626: authorization result of Require valid-user : denied (no authenticated user yet)
- pstack traces of the process in such a time shows the request in mod_negotiation calls:
#0 0x00007f0f93b5b36b in __getdents64 () from target:/lib64/libc.so.6
#1 0x00007f0f93b5b5f8 in readdir_r () from target:/lib64/libc.so.6
#2 0x00007f0f942699ec in apr_dir_read () from target:/lib64/libapr-1.so.0
#3 0x00007f0f8cc90ffb in read_types_multi () from target:/etc/httpd/modules/mod_negotiation.so
#4 0x00007f0f8cc91541 in handle_multi () from target:/etc/httpd/modules/mod_negotiation.so
#5 0x0000562a98bd8108 in ap_run_type_checker ()
#6 0x0000562a98bda730 in ap_process_request_internal ()
#7 0x0000562a98bf9a70 in ap_process_async_request ()
Environment
- Red Hat Enterprise Linux (RHEL)
- Apache httpd
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.