Apache MCQs

Apache MCQs

These Apache multiple-choice questions and their answers will help you strengthen your grip on the subject of Apache. You can prepare for an upcoming exam or job interview with these 60 Apache MCQs.
So scroll down and start answering.

1: Apache is?

A.   A scripting language

B.   A machine language

C.   A database language

D.   Web Server Software

2: The authorization providers implemented by mod_authz_host serve what purpose?

A.   They control access to particular parts of the server based on the client hostname or IP address.

B.   They allow administrators to indicate routing information for proxy servers.

C.   None of these

D.   They control visitor access to parts of the server though it is deprecated in favor of the new mod_access_compat module.

3: What purpose does the mod_status module serve?

A.   It allows the server to display a web page containing statistics about the web server's current state, including worker processes and active connections.

B.   If the server has too many File Descriptors open or exceeds certain memory limits(specified by the admininistrator), an entry will be included in the logs.

C.   None of these

D.   The mod_status module has been deprecated in favor of the new mod_server_info module

4: What is MIME?

A.   A network protocol

B.   An email standard

C.   A web standard used to to determine the type of a file from its extension

D.   A web standard for the handling of user credentials

5: Which of the following is considered the main Apache configuration file?

A.   httpd.conf

B.   .htaccess

C.   apache.conf

D.   server.conf

6: With SSI, it is possible to configure output format of which of the following?

A.   Format of error messages

B.   Format in which file sizes are returned

C.   Format in which time isreturned

D.   All of the above

7: The DocumentRoot directive is set in which of the following configuration files?

A.   httpd.conf

B.   server.conf

C.   apache.conf

8: What does TCP/IP stand for?

A.   Transmission Control Protocol/Internet Protocol

B.   Textual Control Protocol/Internet Protocol

C.   Tracking Control Protocol/Internal Protocol

D.   Transmission Control Protocol/Infrastructure Protocol

9: True or false: Apache can only be run on Windows.


B.   False

10: What is a good reason to log user activity?

A.   All of these

B.   Know how ofter content is viewed

C.   Know who is repeatedly visiting the site

D.   Illuminate marketing problems

11: The Apache HTTP Server ("httpd") is a project of which of the following groups:

A.   The Apache Software Foundation.

B.   Gnu Free Software Foundation

C.   Jakarta Open Source Community

D.   the Linux Open Source Community

12: The AllowOverride directive works only in which of the following sections?

A.   <Files>

B.   <Directory>

C.   <Proxy>

D.   <Location>

13: What character(s) in a configuration file is used to indicate a comment?

A.   "//"

B.   "!"

C.   "\\"

D.   "#"

14: The Apache binary under Unix is called:

A.   htdocs

B.   httpd

C.   cgi-bin

D.   apache.exe

15: Why is it important to set up a proxy?

A.   Improves the aesthetic of the website

B.   It doesn't require the use of a firewall

C.   Better performance/improved security

D.   Helps clear the cache

16: Which of the following is true about the Apache HTTP Server?

A.   It comes with an unrestricted license

B.   All of these

C.   It is actively being developed

D.   It is not an Application Server

17: True or False? The files and directories underneath the DocumentRoot make up the basic document tree which will be visible from the web.

A.   True

B.   False

18: Who is the default user that has permission to the ServerRoot Directories?

A.   A user group

B.   All users on the network

C.   The root user

D.   Anyone with internet access

19: What does the Trace method do?

A.   An HTTP request method that returns a diagnostic trace of actions it takes

B.   An HTTP request method that asks proxy to relay the content of another host

C.   A SSL method that logs errors

D.   A SSL method that tracks cookies

20: mod_rewrite provides a way to modify incoming URL requests, dynamically, based on which of the following criteria?

A.   regular expression rules

B.   CGI scripts

C.   None of these

D.   environment variables

21: What does the directive <VirtualHost> do?

A.   Introduces a block of text containing directives to one host

B.   All of these

C.   Specifies whcih IP address the site is hosting

D.   Specifies the port that is in use

22: What can be done to make a server with AuthType Basic more secure?

A.   Nothing can be done because the authentication credentials are always passed openly with Basic authentication

B.   Include the mod_ssl module

C.   Include the XBitHack directive

D.   None of these

23: If you are in a hosting situation where you only have .htaccess files to work with, you may need use which of the following modules?

A.   mod_rewrite

B.   None of these

C.   mod_alias

D.   authn_file_module

24: The function of AllowOverride directive is

A.   Allows users to change the default Log format

B.   Tells Apache to process or not the .htaccess file and what kind of directives are allowed in it

C.   Tells Apache to overwrite the default environment variables

D.   Allows users to overwrite exiting server name and port number

25: Which should always be used as the path separator in Apache httpd configuration files, even for Windows?

A.   "/"

B.   ","

C.   "\"

D.   ":"

26: A beta test site should:

A.   Be the real site

B.   Be separate and identical to the real site

C.   Be scaled up from the real site

D.   Be separate but have differing features from a the real site

27: Which of the following must be true for the "Require local" directive to allows access to the server?

A.   You are proxying content to your server.

B.   The client address matches

C.   None of these

D.   The client and the server address of the connection are different.

28: Of the following, which is the most effective tool to mitigate Denial of Service attacks?

A.   use of a threaded mpm

B.   lowering the KeepAliveTimeout directive

C.   lowering the timeout directive

D.   a firewall

29: What does the DirectoryIndex command do?

A.   Configures the Index Directory

B.   Specifies a list of resources to look for when the client requests an index of the directory name

C.   Gives users more control of information sorted

D.   Sorts the directory when a client requests an index of a directory

30: Why can't Apache logs be rotated by moving or deleting existing logs while the server is running?

A.   Using the mod_logio module, the httpd server CAN actually rotate logs files while running.

B.   None of these

C.   Chunks of the Apache logs are stored in memory before being written to the file system. Therefore, moving or deleting log files will lead inconsistent logging.

D.   The Apache httpd will continue writing to the old log file as long as it holds the file open. Therefore, the files cannot be deleted or moved.

31: Which directive provides mapping from a URI to a directory - usually a directory outside of your DocumentRoot?

A.   CacheRoot

B.   Directory

C.   Alias

D.   AccessFileName

32: What directive must be used to set the order of the Allow and Deny commands?

A.   Order

B.   Bind Address

C.   Port

D.   None, they are applied by the order in which they appear in your file

33: What character may be used as the last character on a line in a configuration file to indicate that the directive continues onto the next line?

A.   "/"

B.   ":"

C.   "\"

D.   ";"

34: Which of the following are characteristics of IP-based Virtual Hosting?

A.   server has a different IP address/port combination for each IP-based virtual host.

B.   The machine hosting the server has several physical network connections

C.   The machine hosting the server has several virtual interfaces

D.   Any of these

35: Which of the following is a module compiled separately from the Apache httpd binary and can be loaded on-demand?

A.   Handler

B.   DSO

C.   SSI

D.   Directive

36: Which of the follow directives cannot be overridden in a .htaccess file?

A.   LogFormat

B.   Allow

C.   AuthType

D.   DirectoryIndex

37: Which of the following is not a freeware database manager?


B.   NoSQL

C.   Firebird

D.   MySQL

38: The directive RewriteLog does what?

A.   Enables/Disables the rewriting engine

B.   Sends logging to the specified Filename

C.   Controls the verbostiy of logging

D.   Defines an external mapname file

39: You can tell Apache to parse any file with a particular file extension, such as .shtml, with the following directives: AddType text/html .shtml AddOutputFilter INCLUDES .shtml. What is the disadvantage to this approach?

A.   if you wanted to add SSI directives to an existing page, you would have to change the name of that page, and all links to that page, in order to give it a .shtml extension

B.   None of these

C.   Any change made to the .shtml will require a server restart

D.   Every new extension included through the filter requires a new DSO to be compiled into the Apache core.

40: Which of the following is an effect of using DSO's?

A.   There is no noticeable affect

B.   It increases the server startup time.

C.   None of these

D.   It decreases the server startup time.

41: The UserDir directive:

A.   Specifies a directory under which all files can only be accessed by a specific user

B.   Specifies a directory underneath the user's home directory where web files are located

C.   Allows a user's home directory to be accessible.

D.   None of these

42: What security risk arises when users have write access to directories where Apache writes its logs?

A.   None of these

B.   Write access to log directories indirectly opens access to the Apache server bin/ directory.

C.   Someone can gain access to the uid that the server is started as, which is normally root.

D.   Write permissions to the log directory does not pose a significant security risk.

43: What is the result of Options +Includes?

A.   It tells Apache that you want to permit files to be parsed for SSI directives

B.   It tells Apache to allow system environment variables to override httpd command line variables.

C.   None of these

D.   It tells Apache that you want to permit remote content into a web page

44: Which of the following is not a result of using .htaccess files?

A.   None of these

B.   Users can make configuration changes and to access directories for which they wouldn't normally have access, provided the directory is not owned by ''root''.

C.   The .htaccess file is loaded every time a document is requested.

D.   httpd will look in every directory for .htaccess files

45: What is the drawback for using the <IfModule> directive?

A.   it can suppress useful error messages about missing modules.

B.   It ignores DSO's

C.   None of these

D.   It only functions for statically compiled modules.

46: What is the result of using the directive: XBitHack ON ?

A.   None of these

B.   XBitHack tells Apache to parse files for SSI directives if they have the execute bit set

C.   XBitHack ON directive allows CGI scripts to load and run text files as if the executable bit were set.

D.   XBitHack ON directive allows CGI scripts to run executable scripts on the file system.

47: Which of the following is true regarding Apache server and te <VirtualHost> directive?

A.   The Apache HTTP Server should be configured in a way such that it relies on DNS for parsing of the configuration files.

B.   When the server is not configured for DNS parsing of config files, the server is more prone to denial and theft of service attacks.

C.   All of these

D.   None of these

48: The directive Alias can be used for:

A.   Rationalizing directories spread throughout the system/the storage of documents in other directories

B.   Assigning directories an Alias

C.   Hiding a directory from the user

D.   Allows you to run CGI scripts

49: Httpd is a modular server. By default, a base set of modules is included in the server at:

A.   There are no base set of modules because Apache is dynamic.

B.   Compile time

C.   Runtime

D.   None of these

50: Which of the following is not an essential subdirectory of a web site?

A.   htdocs

B.   logs

C.   cgi-bin

D.   conf