Let's see quick steps to install Apache Server on Ubuntu Linux,
Steps:
- Run Command: sudo update,
- Now Run Command: sudo apt install apache2,
- Type Y if you are asked to install dependent packages or note disk space usage,
After this operation, 109 MB of additional disk space will be used. Do you want to continue? [Y/n]
- You might be asked to select the Geographical region,
Please select the geographic area in which you live. Subsequent configuration questions will narrow this down by presenting a list of cities, representing the time zones in which they are located. 1. Africa 3. Antarctica 5. Arctic 7. Atlantic 9. Indian 11. SystemV 13. Etc 2. America 4. Australia 6. Asia 8. Europe 10. Pacific 12. US Geographic area:
- You will also be asked to select the timezone,
Please select the city or region corresponding to your time zone. 1. Aden 16. Brunei 31. Hong_Kong 46. Kuala_Lumpur 61. Pyongyang 76. Tehran 2. Almaty 17. Chita 32. Hovd 47. Kuching 62. Qatar 77. Tel_Aviv 3. Amman 18. Choibalsan 33. Irkutsk 48. Kuwait 63. Qostanay 78. Thimphu 4. Anadyr 19. Chongqing 34. Istanbul 49. Macau 64. Qyzylorda 79. Tokyo .. .. .. 14. Beirut 29. Hebron 44. Kolkata 59. Phnom_Penh 74. Tashkent 89. Yekaterinburg 15. Bishkek 30. Ho_Chi_Minh 45. Krasnoyarsk 60. Pontianak 75. Tbilisi 90. Yerevan If you have selected Region as America 1. Adak 33. Cancun 65. Halifax 97. Mexico_City 129. Rio_Branco 2. Anchorage 34. Caracas 66. Havana 98. Miquelon 130. Santa_Isabel 3. Anguilla 35. Cayenne 67. Hermosillo 99. Moncton 131. Santarem .. .. 9. Argentina/Jujuy 41. Creston 73. Indiana/Vevay 105. New_York 137. Sitka 10. Argentina/La_Rioja 42. Cuiaba 74. Indiana/Vincennes 106. Nipigon 138. St_Barthelemy 11. Argentina/Mendoza 43. Curacao 75. Indiana/Winamac 107. Nome 139. St_Johns
- Now you should be retured to the prompt.
Testing apache2 server by deploying sample html page
Lets to to /var/www/html location and create a sample html page,
# nano /var/www/html/sample.html
Start apache2 server:root@c2c:/var/www/html# sudo service apache2 start
* Starting Apache httpd web server apache2
AH00558: apache2: Could not reliably determine the server's fully qualified domain name,
using 172.17.0.2. Set the 'ServerName' directive globally to suppress this message
*
To test the server is up, lets try doing curl at localhost/sample.html or 172.17.0.2/sample.html (in my case, the IP may vary for your case)
root@c2c:/var/www/html# curl 172.17.0.2/sample.html
<html>
<head>
<title>Apache2 Example</title>
</head>
<body>
<h1>Hello from Apache2 on Ubuntu!</h1>
</body>
</html>

- Install Oh My Zsh on Ubuntu Docker complete steps
- Installing Home-brew on Ubuntu
- Install Golang (Go) on Ubuntu
- Install specific JRE on Ubuntu using apt
- How to stop/start/restart apache server using command [Ubuntu]
- How to install zsh shell on Ubuntu
- Quick steps to install Nginx on Ubuntu Linux
- How to know current Ubuntu Linux version via terminal command
- Add new user in Ubuntu Linux using Terminal Command
- Fix Ubuntu /bin/sh: 1: zsh: not found error
- How to install Python on Ubuntu
- [Fix] Ubuntu E: Unable to locate package sudo error
- How to stop MongoDB Server running on Ubuntu
- Install postgres Client using apt-get command
- How to kill service running on a port on Ubuntu Linux
- [fix] openssl No such file or directory error C++
- Fix - sudo: systemctl: command not found
- Access Windows share folder in Ubuntu Device in Network
- Add or remove users from sudo group - Ubuntu
- Quickly install Apache Server on Ubuntu Linux
- Fix: Ubuntu (Linux) - bash: sudo: command not found error
- How to turn off CR LF CRLF in Notepad++ - NotepadPlusPlus
- [fix] Docker Desktop App not starting on Mac (macOS) - Docker
- Java JDBC with Join Queries Example - Java
- Safari Full Screen Shortcut using Keyboard [macOS] - MacOS
- Simple Struts 2 Tutorial in eclipse with tomcat 7 server - Java
- Hyperlink in html (anchor tag) without a underline - Html
- How to Update Microsoft Teams to the latest Version - Teams
- Ways to Show Git Logs in better way using pretty formatting - Git