How to Set Up Apache or Nginx Web Server on Rocky Linux in VirtualBox | Complete Guide

Опубликовано: 25 Январь 2025
на канале: TechOps Tutorials
27
like

In this step-by-step guide, you’ll learn how to set up both Apache and Nginx web servers on a Rocky Linux VM running in VirtualBox. Whether you're building a website or just getting started with server management, this tutorial covers everything you need to know!

✔️ Prerequisites
Ensure you have VirtualBox installed and a Rocky Linux virtual machine set up. Don't forget to update your system with the latest packages!
✔️ Installing Apache Web Server
Step-by-step instructions on installing Apache, starting the service, and testing the server.
✔️ Firewall Configuration for Apache
Learn how to configure your firewall to allow HTTP/HTTPS traffic for smooth web access.
✔️ Installing Nginx Web Server
Switching to Nginx? We’ll show you how to uninstall Apache and install Nginx for better performance.
✔️ Testing Apache & Nginx
How to confirm that both Apache and Nginx are working by accessing their default web pages.

🔥 Boost Your Server Skills and become an expert in Linux web server management!
💬 Leave your thoughts in the comments below and let us know which web server you prefer: Apache or Nginx.
🔔 Subscribe for more tutorials on Linux and server management!

📚 Chapters
0:02 - 🎉 Introduction - Overview of setting up a web server using Apache or Nginx on Rocky Linux 9.5 in VirtualBox.
0:25 - ⚙️ Prerequisites - Ensure VirtualBox, Rocky Linux VM setup, and internet connectivity before starting the installation process.
0:49 - 🔄 Updating System - Run the update command on Rocky Linux to ensure all packages are up to date before installation.
2:02 - 🛠️ Installing Apache - Step-by-step guide to installing Apache web server on Rocky Linux.
2:39 - 🚀 Starting Apache - Enable and start Apache service to make the web server operational.
3:07 - ✅ Verifying Apache - Confirm Apache is running correctly and HTTP service is enabled.
3:26 - 🌐 Testing Apache - Test the Apache setup by entering the IP address in a browser to verify the web page is loading.
4:04 - 🔥 Configuring Firewall - Resolve potential firewall issues by checking if HTTP and HTTPS ports are open and adding the necessary rules.
6:28 - 🔓 Opening Ports - Open HTTP and HTTPS ports in the firewall for proper web server access.
7:23 - 🔄 Verifying Firewall - Ensure the firewall is properly configured with the necessary HTTP and HTTPS rules.
7:29 - 🌍 Testing Apache Again - Refresh the browser to confirm Apache web server is accessible after firewall adjustments.
7:41 - 🔄 Installing Nginx - Learn how to remove Apache and install Nginx web server on Rocky Linux.
8:05 - 🛑 Stopping Apache - Stop Apache service before proceeding with Nginx installation.
8:23 - ❌ Removing Apache - Uninstall Apache from the system to prepare for Nginx installation.
9:01 - 🏗️ Installing Nginx - Step-by-step guide to installing Nginx web server on Rocky Linux.
9:33 - 🚀 Starting Nginx - Enable and start the Nginx service to activate the web server.
9:49 - 🌐 Testing Nginx - Verify the Nginx installation by entering the IP address in a browser and confirming the page loads.
10:22 - 🔄 Refreshing Nginx Page - See the change from Apache to Nginx on the webpage after removing Apache.
10:43 - ✅ Conclusion - Successfully set up either Apache or Nginx on Rocky Linux in VirtualBox, ready for hosting websites or applications.
11:02 - 👋 Closing - Final thoughts and thanks for watching the tutorial.

#RockyLinux #ApacheWebServer #NginxWebServer #LinuxTutorial #VirtualBox #WebServerSetup