Now We will see what changes we are going to make in this system that means on master.example.com for launching
single website.
So first of all, we will go to our master system and check whether our Apache packages are available or not.
And what is the default home page directly, whether it is some data is there or it is empty, please.
Remember the Apache servers package name is httpd, Hypertext Transfer Protocol Deamon.
So in certain distributions like ubuntu the Package name is Apache or Apache2.
But in this redhat based distribution, like in our case, we are using centos7.
So the Package name is httpd that when when we are installing httpd Package mean we are
installing the Apache package, a web server, so we will verify with rpm -q query httpd command.
And if it is not installed, you can use the yum install httpd command.
But please remember because we have now given the static address, so internet might is not running.
So again, you have to change those settings from Bridge to NAT.
And in that network adapter settings we are to also change from static to dhcp.
Then you can install the package that we have discussed, already how to set up the lab.
Then we will go to the /var/www/html directory and we will check whether some data is there by default.
Nothing you will be there.
And with the ip a s ens33, we will verify the address also.
So in this is what we are going to do, we are going to check whether packages installed or not or IP
addresses, they are proper or not.
Then what we are going to do, we are going to create one homepage and by default the file name
should be index.html.
Please remember, whenever we are installing the Apache Web Server, one /var/www/html directory will be available
to us in which we are going to check whether anything is there or not.
Initially it is empty.
Now we have to put some contents for our website in this directory. and you can create complex webpages.
But in our case, what we are going to do simple one line page we are going to implement because we
are not interested in learning how to design the website that we are concerned with our Web server.
So even one-Line page will be sufficient for mastering the Apache web server.
So there are now two options for us.
You can use the html for creating the static pages and you can use the php for dynamic pages.
But initially we will be using the html.
Only, later on we will be giving one or two example of php.
Also how to use php along with your Apache.
That means we will be discussing that lamp stack Linux, Apache, MySQL, php briefly also.
So in our case, what we are going to do, we will create some small html page.
We will go to the /var/www/html directly and we are going to create that index html file and we are
going to put some data there.
In our case, that data is going to be welcome to test the website.
And please remember, the name of the file should be always be index.html.
Later on, we will see why we have to keep the name as index html, what will happen if we are going
to change the IP address.
Sorry the name of the file to something else, instead of index.html.
And also we are going to take the back up of our httpd.config, how we are going to take the back
up by using the copy command copy.
/etc/httpd/conf/httpd.conf curly bracket comma dot bak that mean we are going
to back up by using the combination of copy command and other culebras concept.
Then we will verify whether backup has been taken properly or not with which command ls command.
So we will see that.
original file is also there backup is there.
Why we are taking?
Because sometimes we you make so many changes and we have to revert back to the original file.
So if we have taken the backup, we can again go back to our original file.
Then we are going to make the additions.
So now let us see demo of this.