Apache HTTPD
Classes | Macros | Typedefs | Enumerations | Functions | Variables
mpm_unix.c File Reference
#include "apr.h"
#include "apr_thread_proc.h"
#include "apr_signal.h"
#include "apr_strings.h"
#include "apr_want.h"
#include "apr_getopt.h"
#include "apr_optional.h"
#include "apr_allocator.h"
#include "httpd.h"
#include "http_config.h"
#include "http_core.h"
#include "http_log.h"
#include "http_main.h"
#include "mpm_common.h"
#include "ap_mpm.h"
#include "ap_listen.h"
#include "scoreboard.h"
#include "util_mutex.h"

Go to the source code of this file.

Classes

struct  extra_process_t
 

Macros

#define APR_WANT_STRFUNC
 
#define APLOG_MODULE_INDEX   AP_CORE_MODULE_INDEX
 

Typedefs

typedef struct extra_process_t extra_process_t
 

Enumerations

enum  action_t {
  DO_NOTHING , SEND_SIGTERM , SEND_SIGTERM_NOLOG , SEND_SIGKILL ,
  GIVEUP
}
 

Functions

void ap_register_extra_mpm_process (pid_t pid, ap_generation_t gen)
 
int ap_unregister_extra_mpm_process (pid_t pid, ap_generation_t *old_gen)
 
static int reclaim_one_pid (pid_t pid, action_t action)
 
void ap_reclaim_child_processes (int terminate, ap_reclaim_callback_fn_t *mpm_callback)
 
void ap_relieve_child_processes (ap_reclaim_callback_fn_t *mpm_callback)
 
apr_status_t ap_mpm_safe_kill (pid_t pid, int sig)
 
int ap_process_child_status (apr_proc_t *pid, apr_exit_why_e why, int status)
 
apr_status_t ap_mpm_pod_open (apr_pool_t *p, ap_pod_t **pod)
 
apr_status_t ap_mpm_pod_check (ap_pod_t *pod)
 
apr_status_t ap_mpm_pod_close (ap_pod_t *pod)
 
static apr_status_t pod_signal_internal (ap_pod_t *pod)
 
apr_status_t ap_mpm_podx_open (apr_pool_t *p, ap_pod_t **pod)
 
int ap_mpm_podx_check (ap_pod_t *pod)
 
apr_status_t ap_mpm_podx_close (ap_pod_t *pod)
 
static apr_status_t podx_signal_internal (ap_pod_t *pod, ap_podx_restart_t graceful)
 
apr_status_t ap_mpm_podx_signal (ap_pod_t *pod, ap_podx_restart_t graceful)
 
void ap_mpm_podx_killpg (ap_pod_t *pod, int num, ap_podx_restart_t graceful)
 
static apr_status_t dummy_connection (ap_pod_t *pod)
 
apr_status_t ap_mpm_pod_signal (ap_pod_t *pod)
 
void ap_mpm_pod_killpg (ap_pod_t *pod, int num)
 
static int send_signal (pid_t pid, int sig)
 
int ap_signal_server (int *exit_status, apr_pool_t *pconf)
 
void ap_mpm_rewrite_args (process_rec *process)
 
static void sig_coredump (int sig)
 
apr_status_t ap_fatal_signal_child_setup (server_rec *s)
 
static apr_status_t fatal_signal_cleanup (void *unused)
 
apr_status_t ap_fatal_signal_setup (server_rec *s, apr_pool_t *in_pconf)
 

Variables

static extra_process_textras
 
static const chardash_k_arg = NULL
 
static const chardash_k_arg_noarg = "noarg"
 
static pid_t parent_pid
 
static pid_t my_pid
 
static apr_pool_tpconf
 

Macro Definition Documentation

◆ APLOG_MODULE_INDEX

#define APLOG_MODULE_INDEX   AP_CORE_MODULE_INDEX

Definition at line 64 of file mpm_unix.c.

◆ APR_WANT_STRFUNC

#define APR_WANT_STRFUNC

Definition at line 34 of file mpm_unix.c.

Typedef Documentation

◆ extra_process_t

Enumeration Type Documentation

◆ action_t

Enumerator
DO_NOTHING 
SEND_SIGTERM 
SEND_SIGTERM_NOLOG 
SEND_SIGKILL 
GIVEUP 

Definition at line 66 of file mpm_unix.c.

Function Documentation

◆ dummy_connection()

static apr_status_t dummy_connection ( ap_pod_t pod)
static

Definition at line 625 of file mpm_unix.c.

◆ fatal_signal_cleanup()

static apr_status_t fatal_signal_cleanup ( void *  unused)
static

Definition at line 1020 of file mpm_unix.c.

◆ pod_signal_internal()

static apr_status_t pod_signal_internal ( ap_pod_t pod)
static

Definition at line 504 of file mpm_unix.c.

◆ podx_signal_internal()

static apr_status_t podx_signal_internal ( ap_pod_t pod,
ap_podx_restart_t  graceful 
)
static

Definition at line 578 of file mpm_unix.c.

◆ reclaim_one_pid()

static int reclaim_one_pid ( pid_t  pid,
action_t  action 
)
static

Definition at line 119 of file mpm_unix.c.

◆ send_signal()

static int send_signal ( pid_t  pid,
int  sig 
)
static

Definition at line 774 of file mpm_unix.c.

◆ sig_coredump()

static void sig_coredump ( int  sig)
static

Definition at line 976 of file mpm_unix.c.

Variable Documentation

◆ dash_k_arg

const char* dash_k_arg = NULL
static

Definition at line 771 of file mpm_unix.c.

◆ dash_k_arg_noarg

const char* dash_k_arg_noarg = "noarg"
static

Definition at line 772 of file mpm_unix.c.

◆ extras

extra_process_t* extras
static

Definition at line 80 of file mpm_unix.c.

◆ my_pid

pid_t my_pid
static

Definition at line 929 of file mpm_unix.c.

◆ parent_pid

pid_t parent_pid
static

Definition at line 929 of file mpm_unix.c.

◆ pconf

apr_pool_t* pconf
static

Definition at line 930 of file mpm_unix.c.