Now, let us rename the file index.html as i.html, then we will see what will happen, because now in DirectoryIndex
it is specified that by default, it will display the index.html.
Now we are changing the file from index.html to i.html and then we will go to our C10
system and will try to elinks --.
dump http://172.24.0.1 and because it is going to show a lot of large output.
So we are just concerned with the five lines so we are specifying head -5 by default head
shows 10 lines.
So with, you can specify how many lines you want.
In our case, we want just five lines.
So here you will get some message testing.
123.
That means now, it is not displaying that i.html.
It is displaying some other page.
So please remember if the Web server will not find that index.html, it will not display the
contents of the file that you have created i.html.
Instead, it is going to display the contents of one file called by default /usr/share/httpd
/noindex/index.html file that mean it is going to display this page.
So let us go to our master system and we will go into our /var/www/html directory.
the file here is index.html and we will rename it with.
i.html, that mean we want to check if we are not going to create the default page, what will
happen.
So we are simulating that now.
our file name is i.html.
So now what we are going to do, we will go to any of our client in our case.
We are going to our C10 client, what we are going to do, we will go to our elinks.
We will run this command and we want just initial five lines.
So it is saying testing that mean our web server is running, but it is not able to find that default
index.html file.
So that is the problem.
And you could have a view in this way also, that mean if you are going to elinks, so again, it is showing
you a lot of output it is showing and what it is saying Apache test page powered by
centos.
So it is showing you a lot of information.
That is why we use the command, which command, so that it is going to show us very few lines.
So, that mean by default our page should be index.html if that page is not there, then it
is going to show you some other page and from where it supplies Data, it is this that can be configured.
Also, we will see why it is displaying this page.