wk2 apache Flashcards
To find the port that Apache is listening on, you should first check …
“Apache non-SSL IP/port” and “ Apache SSL Port” options in WHM Home»_space; Server Configuration»_space; Tweak Settings.
SSP (a script that runs) will tell you if Apache is listening on an alternate port. If neither tweak settings nor SSP can find the alternative port, then what?
use lsof or netstat
What are the two ways apache can extend its basic functionality
It can either use compiled-in extra modules, or it can hand tasks off to external programs using the Common Gateway Interface (CGI).
How are compiled-in modules run?
Compiled in modules are run inside Apache as the Apache user (usually the user “nobody”) and can be configured using the Apache configuration files (including .htaccess files).
How to see what modules are installed?
httpd -M
Give an example of a module used to extend basic php functionality
An example of a module used to extend basic Apache functionality is when PHP is compiled in with Apache as a dynamic shared object (when you use the DSO handler for PHP).
Other examples include items that we think of as being part of Apache, like mod_userdir and helper extensions like mod_speling.
When is the CGI (Common Gateway Interface) used?
The Common Gateway Interface is used when Apache hands off to external programs.
How is the mod_lsapi module unique?
The mod_lsapi module hands off the work to lsphp processes. While these processes are spawned as needed by Apache, they are not Apache children.
Additionally, each user’s lsphp processes are kept in their own LVE/CageFS, so users cannot interfere with each other. If there are no requests for sites from that user in lsapi_backend_pgrp_max_idle seconds, the process will be terminated and need to be respawned when the next request comes in.
Note:
mod_lsapi is only available with CloudLinux.
The Apache binary file.
/usr/sbin/httpd —
This directory contains all the logs for the apache2 file and all the access logs.
/var/log/apache2/ —
This directory contains the configuration directory for Apache and contains all directories for Apache includes, modules, and configuration files. This directory does not contain log files.
/etc/apache2/ —
The primary Apache configuration file.
/etc/apache2/conf/httpd.conf —
This directory contains an alias to the /var/log/apache2/ directory.
/etc/apache2/logs/ —
This directory contains all of the dynamic modules for Apache.
/usr/lib64/apache2/modules/ —
This file contains HTTP requests that the server received and that did not go to a domain.
/etc/apache2/logs/access_log/ —
The primary Apache configuration file directory.
/etc/apache2/conf.d/ —
The directory that contains the include files that add content to the httpd.conf file. You can modify these configuration files via the command line interface (CLI) or WHM’s Include Editor interface (WHM»_space; Home»_space; Service Configuration»_space; Apache Configuration»_space; Include Editor).
/etc/apache2/conf.d/includes/ —
This file contains error information.
/etc/apache2/logs/error_log/ —
This directory contains an alias to the /usr/lib64/apache2/modules/ directory.
/etc/apache2/modules/ —