Now why, by default, your Apache Web server is listing on 80 port, that is decided by
one Listen directive and you can search the directive in your configuration file by using the grep
command.
When we are going to search for Listen parameter, by default, it is showing that our Web server is running
on 80 port.
So we will open this configuration file and we will change that port to 90.
Then we will reload our http and before that, or you can check the configtest whether our configuration
file is OK, although, you should run this command before reloading the http server
now that mean, Listen parameter decides on which port your Web server is going to listen.
So in our case, we have now changed the port to 90, so we will see what will happen when we are going
test this Web site from client side, when we are going to run this command, elinks --dump.
http, it will show that connection refused, why it is giving this error
Because when we run this command by default, your request is sent to the 80 port.
now our Web server is not running on 80 port, so it will display the error.
So how you are going to access, you can access in this way elinks dump.
You have to specify the port.
In this way you will be able to access the website sometime purposefully.
We change the port of our site when we do not want the other people to access or for some security
purpose.
We can change the port.
generlly, You only know about that port so you can access your site according to that.
So in our case, let us see how this Listen directive works.