Apache2 server installation under Ubuntu Linux

Apache or Apache HTTP Server is a free open-source Web server developed by the Apache Software Foundation (Apache Software Foundation) to develop and maintain. Its popularity can be judged by the fact that:

About 46% of the global website is supported by Apache. Apache allows website developers to offer their content over a network.

1. Update the system

  sudo  apt  update

2. Install Apache2 service

   sudo  apt  install  apache2

 

3. Go to the directory of Apache2

    cd  /etc/apache2

    You can see apache2.conf, it is the configuration file

4.  vim  apache2.conf 

    In the last line of input: ServerName localhost       below:

 

Guess you like

Origin www.cnblogs.com/duanqibo/p/11206292.html