Category Archives: bandwidth

linux: Reserve bandwidth [on hold]

Im streaming a video file from my pc to my server1 and then i restream from server1 to server2

if there are to lot of connection to server1 then server2 is also blocked coz it can not get the video from server1

So my question is: Is there a way to reserve bandwidth for server2 so it can always connect to server1?

example 1: is there a wat to reserver 2mpbs for server2 and other bandwidth can use other users.

Example 2: maybe to send stream via different port so users can connect to site.com/vide.m3u8 and my server will connect to site.com:8111/video.m3u8 which will have some priority

so what u suggest to me, which is best way to fix it is there any way to do this.

My website is getting a lot of unknown traffic which is inturn consuming many GB’s of bandwidth

I have a wordpress site hosted which is experiencing some kind of attack. My hosting stats show that my account has consumed 4GB of bandwidth in just 20 days. After some digging I found out that there have been more than 15,000 visits to my website in just few weeks. I checked my logs and found a pattern of GET requests. Thousands of IP's are making a GET request on following url's

1) /using-joomla/extensions/components/users-component/registration-form.html?layout=complete

2) /using-joomla/extensions/components/users-component/login-form.html

3) /?option=com_users&view=profile&layout=edit

4) /europe-tours/item/23-praesent-viverra-nisl-eu-enim-mollis-interdum.html

None of these URL's exist on my website.

I also installed a security plugin which shows my website as a referer to all these url's. I have no idea what is going on, so some help will be highly appreciated.

Connecting to ubuntu home server without internet connection

I am running an Ubuntu server with my laptop through an Orcale VirtualBox and I try to maximize the bandwidth of my home server, as it really slows down my internet connection. My router supports up to 300Mbit upload/download speed and my laptop wifi's card up to 150bit.

I configured my server with the following(static IP, configured by vim /etc/network/interfaces):

auto eth0
iface eth0 inet static
address 192.168.1.240
netmask 255.255.255.0
gateway 192.168.1.1
dns-nameservers 192.168.1.1

192.168.1.1 is my default gateway, and I just configured a static IP which ends with 240.

When my laptop's WIFI is on, I can easily access the server's files(.html files etc) through chrome from any computer on my house, as I just need to enter the server's IP into the browser, plus I can access the server through SSH. But when It's off, I can't even access the server's HTML files through the laptop itself, though I can see that the server is still running on VirtualBox. When I turn the WIFI once again, I can run services which require Apache2 but they really slow my internet connection, as a result I can barely surf the web. I am trying to configure the server to use only the bandwidth of my router, since my actual internet connection is 30 Mbit download and 1.90 Mbit upload(according to speedtest), and It probably interferes with it. Is it possible to access the server without WIFI connection, so it will purely use my router's speed?

Any help would be appreciated.

Response time jump after 4 KB from a php server

I am trying to get information about the bandwidth to a server so i send some packets from a java program of varying sizes (4,8,16,.... 524288) to a php script. The response time for the packets of less than 4KB is linear. After 4KB the response time increase much and the slope changes but its still linear.

PS: I cancelled the php buffer and also tried to change the TCP buffer but still the same behaviour occurs. I use apache server and also disabled the buffer.

Here is the java client code :

public void measure() throws IOException, URISyntaxException {
    timeArray = new double[sizeArray.length];
    for (int i = 0; i < sizeArray.length; i++) {
    URL url = new URL(ParseConfigurationFile.phpQuery +sizeArray[i]); 
    byte [] temp = new byte[sizeArray[i]];
    HttpClient client = new DefaultHttpClient();


    HttpPost post = new HttpPost(url.toURI());
    String res = null;


        post.setEntity((HttpEntity) new ByteArrayEntity(temp));
        HttpResponse response = client.execute(post);
        long start = System.nanoTime();
        res = EntityUtils.toString(response.getEntity());
        long end = System.nanoTime();
        System.out.println("Size = " + sizeArray[i] + " , time = "+(end - start) +" ");
        timeArray[i] = (end - start);

    }
}

Here is the code for the php script :

<?php
 $bytes = $_GET["bytes"];
 $temp = intval ($bytes);
 $result = str_pad("",$temp,"*");
 echo($result);
?>

Could anybody explain this increase after 4KB ?