<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Calculating bandwidth in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344853#M86202</link>
    <description>A while back I wrote a similar script for Tru64unix.   I pulled both input bytes and&lt;BR /&gt;output bytes.   I didn't use snmp but the figures are the same.&lt;BR /&gt;&lt;BR /&gt;I have a feeling that if you are only capturing and calculating bandwidth based on outpackets, you are shortchanging the calculation.   &lt;BR /&gt;&lt;BR /&gt;Bandwidth of a particular interface is made up of both input and output traffic.  &lt;BR /&gt;&lt;BR /&gt;Try including the ifoutOctets as well as see if this brings you any closer the expected result.&lt;BR /&gt;</description>
    <pubDate>Fri, 06 Aug 2004 12:24:32 GMT</pubDate>
    <dc:creator>Al Licause</dc:creator>
    <dc:date>2004-08-06T12:24:32Z</dc:date>
    <item>
      <title>Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344846#M86195</link>
      <description>Hello all,&lt;BR /&gt;&lt;BR /&gt;I've set up SNMP on linux, which is all fine and dandy. I am trying to write a small app that checks how much bandwidth is going through the interface at any given time. I did it in perl, and it works... but the numbers are wrong!&lt;BR /&gt;&lt;BR /&gt;Basically, I pull ifInOctets from snmp. This is the bytes of data that have come in the interface. But when I take the change in that, over the change in time since the last check, the numbers are not right! Low values seem to be ok, but if I generate A LOT of traffic, then it shoots up to 45 MegaBYTES!!! Obviously impossibly over 100-MBit network.&lt;BR /&gt;&lt;BR /&gt;I also tested it against MRTG. MRTG seems to get the right values. What have I done wrong?&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;&lt;BR /&gt;-Jack C&lt;BR /&gt;&lt;A href="http://www.CREPinc.com" target="_blank"&gt;http://www.CREPinc.com&lt;/A&gt;</description>
      <pubDate>Thu, 29 Jul 2004 12:35:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344846#M86195</guid>
      <dc:creator>Jack C_1</dc:creator>
      <dc:date>2004-07-29T12:35:45Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344847#M86196</link>
      <description>Does snmp always return valid values?&lt;BR /&gt;&lt;BR /&gt;I think to help an snmp guru(not me) might need to see your application source code. Could be a simple division error or something.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Thu, 29 Jul 2004 15:16:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344847#M86196</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2004-07-29T15:16:41Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344848#M86197</link>
      <description>That's true. I check pretty closly though...&lt;BR /&gt;&lt;BR /&gt;One thing I do know is that SNMP counters reset after a certain number. I acounted for that in the program.&lt;BR /&gt;&lt;BR /&gt;Perhaps my timeer is not accurate enough?&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;&lt;BR /&gt;-Jack C</description>
      <pubDate>Thu, 29 Jul 2004 15:56:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344848#M86197</guid>
      <dc:creator>Jack C_1</dc:creator>
      <dc:date>2004-07-29T15:56:29Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344849#M86198</link>
      <description>try this scripts - it's checking Lan interface traffic.</description>
      <pubDate>Fri, 30 Jul 2004 00:41:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344849#M86198</guid>
      <dc:creator>Petr Simik_1</dc:creator>
      <dc:date>2004-07-30T00:41:45Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344850#M86199</link>
      <description>Another shot, test it with mrtg-rrdtool.&lt;BR /&gt;Take random samples across a fixed time period.  Can you show me this perl script?&lt;BR /&gt;The sampling is not done right.</description>
      <pubDate>Fri, 30 Jul 2004 01:44:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344850#M86199</guid>
      <dc:creator>Ragu_3</dc:creator>
      <dc:date>2004-07-30T01:44:22Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344851#M86200</link>
      <description>Yes I will post the script on monday, sorry I don't have it with me right now. Also, I will test the script monday, because unfourtunatly I'm on windows right now.&lt;BR /&gt;&lt;BR /&gt;Thanks guys,&lt;BR /&gt;&lt;BR /&gt;-Jack C</description>
      <pubDate>Sat, 31 Jul 2004 10:43:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344851#M86200</guid>
      <dc:creator>Jack C_1</dc:creator>
      <dc:date>2004-07-31T10:43:51Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344852#M86201</link>
      <description>OK. The shell script does not run because I do not have the binary therein. (lanadmin).&lt;BR /&gt;&lt;BR /&gt;My perl script is attatched. Sorry it is not very good, as I am not a real perl person. &lt;BR /&gt;&lt;BR /&gt;Thanks again,&lt;BR /&gt;-Jack C&lt;BR /&gt;&lt;A href="http://www.crepinc.com" target="_blank"&gt;http://www.crepinc.com&lt;/A&gt;</description>
      <pubDate>Mon, 02 Aug 2004 16:23:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344852#M86201</guid>
      <dc:creator>Jack C_1</dc:creator>
      <dc:date>2004-08-02T16:23:29Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344853#M86202</link>
      <description>A while back I wrote a similar script for Tru64unix.   I pulled both input bytes and&lt;BR /&gt;output bytes.   I didn't use snmp but the figures are the same.&lt;BR /&gt;&lt;BR /&gt;I have a feeling that if you are only capturing and calculating bandwidth based on outpackets, you are shortchanging the calculation.   &lt;BR /&gt;&lt;BR /&gt;Bandwidth of a particular interface is made up of both input and output traffic.  &lt;BR /&gt;&lt;BR /&gt;Try including the ifoutOctets as well as see if this brings you any closer the expected result.&lt;BR /&gt;</description>
      <pubDate>Fri, 06 Aug 2004 12:24:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344853#M86202</guid>
      <dc:creator>Al Licause</dc:creator>
      <dc:date>2004-08-06T12:24:32Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344854#M86203</link>
      <description>Re-reading your original note, I'm wondering if you are forgetting a conversion factor some place ?&lt;BR /&gt;&lt;BR /&gt;I am from the old school of bits/second for throughput numbers so I use the following:&lt;BR /&gt;&lt;BR /&gt;(((ibytes_previous + obytes_previous)*8) - ((ibytes + obytes)*8))/seconds&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 06 Aug 2004 12:29:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344854#M86203</guid>
      <dc:creator>Al Licause</dc:creator>
      <dc:date>2004-08-06T12:29:47Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating bandwidth</title>
      <link>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344855#M86204</link>
      <description>Well, my data is not total throughput. If you look at the script, you see that I have a separate area for in/out on each interface (except lo). So only IN bandwidth  and OUT bandidth are shown. And yes, it is in Bytes Per Second.&lt;BR /&gt;&lt;BR /&gt;Here is a thought. After comparing it to a known level of bandwidth, it seems that I get one low value, then one high. Perhaps, if my timing was not acurate enough, that could happen. Ideas?&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;&lt;BR /&gt;-Jack C&lt;BR /&gt;&lt;A href="http://www.crepinc.com" target="_blank"&gt;http://www.crepinc.com&lt;/A&gt;</description>
      <pubDate>Sat, 07 Aug 2004 08:25:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/calculating-bandwidth/m-p/3344855#M86204</guid>
      <dc:creator>Jack C_1</dc:creator>
      <dc:date>2004-08-07T08:25:50Z</dc:date>
    </item>
  </channel>
</rss>

