Linux Administration, Interview Question, Tips And Tricks
Pages
▼
Monday, January 12, 2015
How to change Apache port in Linux ?
Change the
port number of Apache web server in Linux and Unix?
Some times we
have to change the port for some services such as Apache so that they start
listening on the port.
To change the
port of Apache we have to edit httpd.conf which is located in /etc/httpd/conf
in most Linux distributions. Open httpd.conf file and search for the word
Listen. This Listen entry is to inform Apache where to listen for incoming http
packets so that Apache can start processing the http packets.
Now change
the port assigned to what ever port you want. Listen <port>
Changing the
port to 443 in httpd.conf file. Listen 443
Once you
edited the httpd.conf file save and exit it.
Service httpd
restart
Start the
Apache service to take this change live. Now try to access website with mention
port.
No comments:
Post a Comment