Foros de discusión

How to avoid port number in url

Subhagnanam A, modificado hace 7 años.

How to avoid port number in url

Junior Member Mensajes: 50 Fecha de incorporación: 25/02/16 Mensajes recientes
I need to avoid port number in url ,for example test.com/home instead of test.com:8088/home
thumbnail
David H Nebinger, modificado hace 7 años.

RE: How to avoid port number in url

Liferay Legend Mensajes: 14917 Fecha de incorporación: 2/09/06 Mensajes recientes
The only time the port number will not be specified is when you use a standard port number.

That means 80 for http and 443 for https.

Any other port must be included in the url so the browser knows what port the server is available on.






Come meet me at the LSNA!
Subhagnanam A, modificado hace 7 años.

RE: How to avoid port number in url

Junior Member Mensajes: 50 Fecha de incorporación: 25/02/16 Mensajes recientes
In windows i used 80 and 443 port and avoided port number in url.
But in linux it doesn't work.The page is not loading.
thumbnail
David H Nebinger, modificado hace 7 años.

RE: How to avoid port number in url

Liferay Legend Mensajes: 14917 Fecha de incorporación: 2/09/06 Mensajes recientes
Subhagnanam A:
But in linux it doesn't work.The page is not loading.


On linux often only root can open ports less than 1024; are you sure tomcat is able to listen on that port? It could be that tomcat starts but cannot listen and therefore will not respond to requests.
Subhagnanam A, modificado hace 7 años.

RE: How to avoid port number in url

Junior Member Mensajes: 50 Fecha de incorporación: 25/02/16 Mensajes recientes
Then how could I avoid port number in URL.
There is no other service running on server except tomcat,so I think I can make use of port 80.
So is there any way to use port 80 and 443 in tomcat in Linux.
thumbnail
David H Nebinger, modificado hace 7 años.

RE: How to avoid port number in url

Liferay Legend Mensajes: 14917 Fecha de incorporación: 2/09/06 Mensajes recientes
Sure, use root to start tomcat. Root can open these lower ports.
thumbnail
Olaf Kock, modificado hace 7 años.

RE: How to avoid port number in url

Liferay Legend Mensajes: 6403 Fecha de incorporación: 23/09/08 Mensajes recientes
David H Nebinger:
Sure, use root to start tomcat. Root can open these lower ports.

Who are you and what did you do to David?

Don't listen to this. Rather have a port redirection or add an Apache to the game. Check this article to get a starting point (check the whole series). Comment if it works (or if it doesn't). There are numerous instructions on the web that go more into detail if you need them.
thumbnail
David H Nebinger, modificado hace 7 años.

RE: How to avoid port number in url

Liferay Legend Mensajes: 14917 Fecha de incorporación: 2/09/06 Mensajes recientes
Olaf Kock:
David H Nebinger:
Sure, use root to start tomcat. Root can open these lower ports.

Who are you and what did you do to David?


Aw, come on, Olaf, I was just answering his question in the way that he asked it. Clearly the OP is not a system admin and is not going through all of the proper steps to set up a production Unix-based system or that would have been part of his question.

I assumed he was doing some sort of dev or test environment and just wanted to keep things really simple. But if he was asking about setting up his production server this way, well then I would suggest that perhaps his team should find a proper system administrator to set up a solid production environment.
thumbnail
Olaf Kock, modificado hace 7 años.

RE: How to avoid port number in url

Liferay Legend Mensajes: 6403 Fecha de incorporación: 23/09/08 Mensajes recientes
David H Nebinger:
Olaf Kock:
Who are you and what did you do to David?


Aw, come on, Olaf, I was just answering his question in the way that he asked it....


I know. But any time I'm seeing someone suggesting "sudo startup.sh" I willingly use nondiplomatic language and keep my fingers away from any character that might end up in a smiley - to send the unmistakeable message to the original poster (and everybody who comes along afterwards) that this is a particularly bad idea. The safepoints (dev-system et al) weren't there, so I shot.

@everybody and @Subhagnanam A : Listen to everything David says - just not to the "sudo" part above. Unless you know what you're doing. But if you need this advice, you probably don't.
thumbnail
David H Nebinger, modificado hace 7 años.

RE: How to avoid port number in url

Liferay Legend Mensajes: 14917 Fecha de incorporación: 2/09/06 Mensajes recientes
Olaf Kock:
But any time I'm seeing someone suggesting "sudo startup.sh"...


Ha! I didn't give them the command, though, you did! emoticon
Subhagnanam A, modificado hace 7 años.

RE: How to avoid port number in url (Respuesta)

Junior Member Mensajes: 50 Fecha de incorporación: 25/02/16 Mensajes recientes
I got the solution,i used ip table prerouting method and rerouted the port 8080 to 80
thumbnail
Mohammad Azharuddin, modificado hace 7 años.

RE: How to avoid port number in url

Expert Mensajes: 492 Fecha de incorporación: 17/09/12 Mensajes recientes
Subhagnanam A:
I need to avoid port number in url ,for example test.com/home instead of test.com:8088/home



may be map to a domain .