• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to determine the port

 
Chandramohan
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

How can i find the port on which the application server is running.? I have the ip address of the different servers. How to find out the port on which these servers are running.
[ June 28, 2007: Message edited by: Bear Bibeault ]
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Chandramohan",
Welcome to the JavaRanch.

We're a friendly group, but we do require members to have valid display names.

Display names must be two words: your first name, a space, then your last name. Fictitious names are not allowed.

Please edit your profile and correct your display name since accounts with invalid display names get deleted, often without warning

thanks,
Dave
 
Rahul Bhattacharjee
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Chandramohan:

How can i find the port on which the application server is running.? I have the ip address of the different servers. How to find out the port on which these servers are running.


The question is not very clear to me.

How can i find the port on which the application server is running.?

From within the server or from outside the server (as client).If you want to know ,in which port the server is running from within the servlet , then follow what Ben suggested.

If you have IP of machines where the servers are running , but you do not know the port and what to know the port numbers.

I do not think its possible in a clean way.

You can try this , But its illegal (port scanning).

You can take up an IP address where you know that a application server is hosted.

Keep sending HTTP requests (probably HTTP OPTIONS) to it starting from least port , until you get a proper HTTP response back.That would be the port.

What is your requirement exactly ?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!