Find the answer to your Linux question:
Results 1 to 2 of 2
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    maximum bandwidth for a process ?


    How can I ask to linux to execute a script using the maximum bandwidth available ?

    when executing a script on 2 different servers with a very different bandwidth, the script is not faster on one server than on another one.
    This script (tcp client) opens a connection with an external tcp server and is continuously exchangin data with it, so speed should be affected according to the bandwidth no ?
    Or is the bandwidth limited by calling a perl script ?
    I call it from ssh with : nohup nice -20 perl &
    Is there in this command line something that limits the bandwidth ?
    (dns and apache server are not activated)

    Thank you for your help and any clue

  2. #2
    Trusted Penguin Irithori's Avatar
    Join Date
    May 2009
    There might be some traffic shaping, but not per default.
    Someone would have to have setup this.

    Get a baseline of what is actually possible.
    I take it, you have access to your two servers, do you have acces to that remote server, too?

    Please install iptraf and netcat (may be called nc) on your servers and netcat on the remote server.

    • open a terminal to your server.
    • become root in
    • start iptraf
    • "configure" it to show kbyte/s
    • then go to "detailed interface statistics" and select your interface.

    • open a terminal to the remote server
    • use netcat to open a port. Everything coming in will go to /dev/null
      netcat -l -p 22222 > /dev/null
      open a terminal to your server
      use netcat to create traffic.
      cat /dev/zero | netcat <REMOTE SERVER IP ADDRESS> 22222

    • Look at iptraf.
    • Note the bandwidth.
    • Repeat the setup with your second server

    Well, that's about it.
    This will be the maximum networkspeed your perl application can possibly get.
    If it is significantly lower, either your app or the remote server is too slow.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts