Forum Moderators: phranque

Message Too Old, No Replies

Virtual host

Port changing

         

roomapache

12:23 am on Mar 16, 2014 (gmt 0)

10+ Year Member



Apache2.2.22
After changing ports on ports.conf and sites-enabled default
I get error can't connect to server
If I put after server ip xxx.xx.xx.x : port
This way it works
adding name server to httpd.conf and listen to port not solve this issue
any suggestion would be helpful

mack

12:44 am on Mar 16, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Did you restart Apache after you made the changes?

Mack.

roomapache

12:54 am on Mar 16, 2014 (gmt 0)

10+ Year Member



Yes I restart
apache itworks ! Index html works if I put new port # after IP address
It works only this way xx.xx.x.x:8080/index.html
xx.xx.x.x/index.html no access log or error log on logs
Firefox can not open because it could not connect to server

mack

1:26 am on Mar 16, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Is this not expected behaviour? If you change the port on the vhost entry you would need to add it to the url. If you leave it blank it will always use the default of port 80. The only real way round this is to alter the settings on your firewall. to port all http requests to 8080.

Correct me if I’m wrong.

Mack.

roomapache

2:12 am on Mar 16, 2014 (gmt 0)

10+ Year Member



No NameVirtualHost does not imply a socket will be opened on the given IP:PORT combination [httpd.apache.org...] I turned off ipv6 and use only 4 to test on local network
I can't ping without firewall in local network even

mack

6:23 pm on Mar 16, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Does the port value not determine the type of transfer being used. I get mixed up with this from time to time. The firewall only adds a new dimension.

My thinking was www.example.com would default to port 80. If you use a different port number within your name based virtual host. The server would listen only on that port?

Mack.

ergophobe

5:18 pm on Mar 19, 2014 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Like Mack, I would thin that in a default Apache setup, port 80 would only serve up standard http traffic and 8080 would only serve up encrypted (TLS, SSL) traffic via https (and assuming a certificate is present).