Beruflich Dokumente
Kultur Dokumente
1 of 3
https://help.ubuntu.com/13.04/serverguide/httpd.html
Ubuntu.com
Ocial Documentation
Community
Support
Partners
04/29/2013 10:34 PM
2 of 3
https://help.ubuntu.com/13.04/serverguide/httpd.html
Previous | Next
Apache is the most commonly used Web Server on Linux systems. Web Servers are used to serve Web Pages requested by client
computers. Clients typically request and view Web Pages using Web Browser applications such as Firefox, Opera, Chromium, or
Mozilla.
Users enter a Uniform Resource Locator (URL) to point to a Web server by means of its Fully Qualied Domain Name (FQDN) and
a path to the required resource. For example, to view the home page of the Ubuntu Web site a user will enter only the FQDN:
www.ubuntu.com
To view the community sub-page, a user will enter the FQDN followed by a path:
www.ubuntu.com/community
The most common protocol used to transfer Web pages is the Hyper Text Transfer Protocol (HTTP). Protocols such as Hyper Text
Transfer Protocol over Secure Sockets Layer (HTTPS), and File Transfer Protocol (FTP), a protocol for uploading and downloading
les, are also supported.
Apache Web Servers are often used in combination with the MySQL database engine, the HyperText Preprocessor (PHP) scripting
language, and other popular scripting languages such as Python and Perl. This conguration is termed LAMP (Linux, Apache,
MySQL and Perl/Python/PHP) and forms a powerful and robust platform for the development and deployment of Web-based
applications.
Installation
Conguration
HTTPS Conguration
Sharing Write Permission
References
Installation
The Apache2 web server is available in Ubuntu Linux. To install Apache2:
1. At a terminal prompt enter the following command:
sudo apt-get install apache2
Conguration
Apache2 is congured by placing directives in plain text conguration les. These directives are separated between the following
les and directories:
1. apache2.conf: the main Apache2 conguration le. Contains settings that are global to Apache2.
2. conf.d: contains conguration les which apply globally to Apache2. Other packages that use Apache2 to serve content may
add les, or symlinks, to this directory.
3. envvars: le where Apache2 environment variables are set.
4. httpd.conf: historically the main Apache2 conguration le, named after the httpd daemon. Now the le does not exist. In
older versions of Ubuntu the le might be present, but empty, as all conguration options have been moved to the below
referenced directories.
5. mods-available: this directory contains conguration les to both load modules and congure them. Not all modules will
have specic conguration les, however.
6. mods-enabled: holds symlinks to the les in /etc/apache2/mods-available. When a module conguration le is symlinked
it will be enabled the next time apache2 is restarted.
7. ports.conf: houses the directives that determine which TCP ports Apache2 is listening on.
8. sites-available: this directory has conguration les for Apache2 Virtual Hosts. Virtual Hosts allow Apache2 to be congured
for multiple sites that have separate congurations.
9. sites-enabled: like mods-enabled, sites-enabled contains symlinks to the /etc/apache2/sites-available directory.
Similarly when a conguration le in sites-available is symlinked, the site congured by it will be active once Apache2 is
restarted.
In addition, other conguration les may be added using the Include directive, and wildcards can be used to include many
04/29/2013 10:34 PM
3 of 3
https://help.ubuntu.com/13.04/serverguide/httpd.html
The material in this document is available under a free license, see Legal for details
For information on contributing see the Ubuntu Documentation Team wiki page. To report a problem, visit the bug page for Ubuntu Documentation
04/29/2013 10:34 PM