Debugging Cherokee

If you need to debug the behavior of the web server (or an application), there are some helpful tools available for you.

Now, when you are going to launch the web server, just add the CHEROKEE_TRACE variable, with the desired options:

cherokee# CHEROKEE_TRACE="common" cherokee
Cherokee Web Server 0.7.0 (May 21 2008): Listening on port 80, TLS disabled
IPv6 enabled, using epoll, 1024 fds system limit, max. 507 connections
5 threads, 206 fds per thread, standard scheduling policy
handler_common.c:0143 (                     stat_file): /var/www//images/powered_by_cherokee.png, use_iocache=0 re=0
handler_common.c:0190 (   cherokee_handler_common_new): request: '/images/powered_by_cherokee.png', local: '/var/www//images/powered_by_cherokee.png', exists 1
handler_common.c:0236 (   cherokee_handler_common_new): going for handler_file
handler_common.c:0143 (                     stat_file): /var/www//images/default-bg.png, use_iocache=0 re=0
handler_common.c:0190 (   cherokee_handler_common_new): request: '/images/default-bg.png', local: '/var/www//images/default-bg.png', exists 1
handler_common.c:0236 (   cherokee_handler_common_new): going for handler_file
handler_common.c:0143 (                     stat_file): /var/www//images/cherokee-logo.png, use_iocache=0 re=0
handler_common.c:0190 (   cherokee_handler_common_new): request: '/images/cherokee-logo.png', local: '/var/www//images/cherokee-logo.png', exists 1
handler_common.c:0236 (   cherokee_handler_common_new): going for handler_file

Of course, you can trace all the modules (handlers, loggers..) you need:

CHEROKEE_TRACE="common,static,io_cache" /usr/bin/cherokee
CHEROKEE_TRACE="all" /usr/bin/cherokee