I was trying to understand what the –numeric/-n flag of netstat does? Manual says the following about –numeric/-n –numeric , -n Show numerical addresses instead of trying to determine symbolic host, port or user names. Following is a line of output with “-n” option Following is the same line as in A but without “-n” option port 8080 in my
Tag: tcp
How to find a free TCP port
How do I find a completely free TCP port on a server? I have tried the command line; but I am told the ones with a status of LISTENING are already being used. I also tried a tool called TCPView but again it only showed which TCP ports were being used. I know how to telnet to a port to
Linux/Unix Socket Self-connection
When a client try to connect to a server, if client and server are both localhost, self-connection may happen(source port and destination port happened to be the same.). But my problem is, client is not listening to that port, how can self-connection be possible? Answer We can simple reproduce this phenomenon with the following python program when we try to
What should TCP/IP do if one computer changed its IP address which we are sending data to?
What’s the standard behavior of TCP/IP protocol stack when a computer which we are sending data to suddenly changed its IP address? When this happens, the ARP table in our system is out of date, but the entry for this IP is not timed out? Is there a way to discover the new IP-mac mapping or we simply drop the
how to verify tcp checksum [closed]
This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center. Closed 10 years ago. For some odd reason,
Trouble on state FIN_WAIT_1
recently i’ve got some port holding on FIN_WAIT_1 state till two days later. The target port is used by one server process ever and client connect to the server process through this port. The situation is we stopped the server process, and obviously some client is still connecting with the server at that moment. From my understanding, the server process
Simplest way to script slowly sending data through a socket connection
I need to periodically connect to a server from a Linux client and send some commands, so I wrote this script: The problem is that I need to wait between commands. This script sends the commands and disconnects too quickly, which the server detects, and drops the commands. It works if I open the connection from the command line and
TCP performance differences between RH Linux and Solaris in java?
While comparing java TCP socket performance between RH Linux and Solaris, one of my test is done by using a java client sending strings and reading the replies from a java echo server. I measure the time spent to send and receive the data (i.e. the loop back round trip). The test is run 100,000 times (more occurrence are giving
Redirecting packets to user space TCP stack without modifying application
I’m using a user space TCP stack based on the Linux stack running under Linux. Unfortunately it requires applications to specifically call its own modified versions of the normal sockets API functions and then just grabs incoming packets it receives in response using libpcap. Now my question is whether there is any way to redirect packets from an application to