Tuning the Scheduler



I have a Linux app, let's call it App1, that uses a TCP/IP socket to
communicate with the socket of another app, App2. The problem is that
the App2's receive socket buffer eventually overflows because it cannot
keep up with the rate at which App1 is sending TCP/IP messages. When I
view the CPU utilization using Top, I notice that the CPU is idle about
75% of the time. Because of this large amount of idle time, It seems to
me that there is plenty of CPU power to prevent the receive buffer
overflow if the scheduler can somehow be make aware of the receive
buffer state (say via some kind of high watermark indication).

Is there a way to tune the scheduler so that it gives App2 the time it
needs to prevent buffer overflow? BTW, App2 is not waiting on anything
which would prevent it from being run as it's receive buffer begins to
fill.

Thanks,

Darol

.



Relevant Pages

  • Re: Communication speed between blocking call and non blocking cal
    ... You could use event based notification, ... When you use nonblocking I/O, the system may have to perform extra buffering ... data buffer until you say that you are done with it. ... I checked default socket buffer ...
    (microsoft.public.win32.programmer.networks)
  • Re: strange select() behavior
    ... sharing descriptors, might fill that interface buffer. ... What do you do when a blocking socket operation returns ENOBUFS? ... because it's a semantic change. ...
    (comp.unix.programmer)
  • Re: Can someone help me
    ... // contents from the server to the client public class AsynchNetworkFileServer {class ClientHandler {// constructor public ClientHandler(Socket socketForClient) {// initialize member variable socket = socketForClient; // initialize buffer to hold ... // contents of file buffer = new byte; // create the network stream networkStream = new NetworkStream; // set the file callback for reading ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: [PATCH] CONFIG_PACKET_MMAP should depend on MMU
    ... The entire data buffer is allocated as one contiguous lump in NOMMU-mode. ... +#ifndef CONFIG_MMU ... * find out where the socket buffers are so that NOMMU mmap can return the ...
    (Linux-Kernel)
  • Re: Socket stuck with puts over ADSL line
    ... gets stuck with the puts command within the filevent writeable ... Is the socket configured as -blocking 1? ... local buffer would fill rapidly, ... buffered portion across the WAN as its own TCP packet, ...
    (comp.lang.tcl)