Feature Req: load averages (with code)
Posted: Sun Aug 02, 2009 11:44 am
I tried to add load averages to overview.sh & compile & test it, but running full-build-809.sh had a problem:
Checking 'case-sensitive-fs'... failed.
Build dependency: OpenWrt can only be built on a case-sensitive filesystem
So I'll need to juggle things around.
Its simple enough:
--- overview_new.sh 2009-07-29 22:30:11.000000000 -0400
+++ overview.sh 2009-08-02 11:23:12.000000000 -0400
@@ -33,6 +33,8 @@
echo "var totalMemory=$total_mem;"
echo "var freeMemory=$free_mem;"
+ load_avg=$(cat loadavg | awk '{print $1, $2, $3}')
+
?>
//-->
@@ -54,6 +56,9 @@
<div>
<span class='leftcolumn'>Memory Usage:</span><span id="memory" class='rightcolumn'></span>
</div>
+ <div>
+ <span class='leftcolumn'>Load Averages:</span><span id="load_avg" class='rightcolumn'></span>
+ </div>
<div class="internal_divider"></div>
</div>
---------------
If this isn't how you want code submissions, maybe a FAQs entry would be instructive.
Checking 'case-sensitive-fs'... failed.
Build dependency: OpenWrt can only be built on a case-sensitive filesystem
So I'll need to juggle things around.
Its simple enough:
--- overview_new.sh 2009-07-29 22:30:11.000000000 -0400
+++ overview.sh 2009-08-02 11:23:12.000000000 -0400
@@ -33,6 +33,8 @@
echo "var totalMemory=$total_mem;"
echo "var freeMemory=$free_mem;"
+ load_avg=$(cat loadavg | awk '{print $1, $2, $3}')
+
?>
//-->
@@ -54,6 +56,9 @@
<div>
<span class='leftcolumn'>Memory Usage:</span><span id="memory" class='rightcolumn'></span>
</div>
+ <div>
+ <span class='leftcolumn'>Load Averages:</span><span id="load_avg" class='rightcolumn'></span>
+ </div>
<div class="internal_divider"></div>
</div>
---------------
If this isn't how you want code submissions, maybe a FAQs entry would be instructive.