Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Is there any command/utility which would help me to ping a network device from solaris box by providing port number as the argument along with the ipaddress.
I tried the following :
/usr/sbin/ping -p <port> <ipaddress>
But this dint work.
Requirement :
I am using an application which would be doing provisioning of some services on a network device. This application works on Sun Solaris.
This application would access the network device using a user mentioned free port. Hence I need to know if the device is accessible on that particular port.
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660
Rep:
If you're writing an application to do this, why wouldn't you just use the socket API to attempt to communicate over the given port? If it's accepted, you know the port is in use. If it times-out, it's being blocked by a firewall. If the connection is refused, you know it's not in use.
Of course, this only works for TCP. You can see if UDP packets are refused, but if they aren't refused it could be either because they were accepted, or because a firewall blocked them.
On the other hand, if you're checking to see whether your service is listening, why wouldn't you just build a test function into it that would respond to a status query?
harisudhan originally asked if there was an external ping method
remote terminal inquires if a server is up ,
there is a new thread and the method is to use TELNET to the port
and if you do not get a timeout response, its a good sign the (remote)
port is responding (with something), i.e. "TELNET aaa.bbb.ccc.ddd 80<CR>"
icmp, tracert, port activity all aside as they don't help to t-shoot that remote
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.