i want solution for creating multiple ports at both server and client sides using c/c++.
My main idea is to send requests from different clients to server(ex:to port1) and receive data from server( from another port 2) and at the receiver side again i want new port to receive data from server to each client.
Is it possible to do like that???
please give suggestions
Why do you think you need such a design. Normally, one socket connection per client would be enough.
Actually i want send jumbo frames [5000bytes] from each client to sever.
My idea is, if we send both request messages from different clients to a particular port on server and send data to same port on the server will decrease the throughput. so i want to send data from clients to different port on the server side.
Is this idea is correct ???
I don't think so. You must think in terms of connections, not ports. A connection consists of the tuple (local IP address, local port, remote IP address, remote port, protocol). So if each client establishes 1 connection to the server, everything can be sent via this connection. A separate data connection would not necessarily increase the overall throughput, IMO.
Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are, by
definition, not smart enough to debug it.
- Brian W. Kernighan
Actually i want send jumbo frames [5000bytes] from each client to sever.
Originally Posted by bhanubtech35
(Here we are using UDP for sending packets.)
For all I know, this seems to be not the best approach. Since UDP packets can not be split, huge packets might be dropped on their way. All applications I know of use UDP for rather small packets (as a rule of thumb I have in mind having read 1500 bytes max.).
However, you are asking for a solution. Are you still in favor of the 2 port solution?
Actually we want to send data through 10Gbps line(i.e. using optical fiber). So, to achieve higher data rates we have to send jumbo packets.Using single port we didn't get good throughput so we want go for 2 ports. Is there any solution for this ? ,otherwise please suggest a procedure to achieve good throughput.
Actually we want to send data through 10Gbps line(i.e. using optical fiber). So, to achieve higher data rates we have to send jumbo packets.Using single port we didn't get good throughput so we want go for 2 ports. Is there any solution for this ? ,otherwise please suggest a procedure to achieve good throughput.
If you are using UDP and Windows, your poor throughput with jumbo packets might be because of a known issue regarding the registry entries respectively called FastSendDatagramThreshold and FastCopyReceiveThreshold. The issue affects only Windows machines (naturally, since it's a registry entry) and not Linux etc. See, for example, these two links:
"Microsoft Windows 2000 TCP/IP Implementation Details" at http://technet.microsoft.com/en-us/l.../bb726981.aspx (it's a long page, seach towards the end where you will find an explanation of the FastSendDatagramThreshold parameter)
Try re-running your tests with different sizes for your message. Instead of 5000 bytes, try to re-run at the following message sizes:
1023
1024
1025
1026
If you see a large slowdown in throughput as you change the message size from 1024 to 1025, then you are dealing with this known issue of registry entries.
If so, then there is no need for multiple ports. Just change the registry entries.
Cycling is the most fashionable among all sports, not only because of its beautiful curve while riding across the road but also because of the diversified bicycle suits with which riders match their style at their will.You will find many excellent cycling jerseys from this site.
Bookmarks