added SETDEVICENAME in tc-all.sh, support /all.xml and provided all.xsl to allow on-the-fly html generation, re-worked javascript
Costa Tsaousis (ktsaou) committed
Mar 25, 2014 at 20:10 UTC
4939bd17ecf8912897dd4264632040a33345b6c2
4 files changed
+211
-101
netdata.c
+144
-14
@@ -59,7 +59,7 @@
59
#define CT_TEXT_XSL 8
60
61
// configuration
62
-#define DEBUG (D_WEB_CLIENT_ACCESS|D_LISTENER|D_RRD_STATS|D_TC_LOOP)
62
+#define DEBUG (D_WEB_CLIENT_ACCESS|D_LISTENER|D_RRD_STATS)
63
//#define DEBUG 0xffffffff
64
//#define DEBUG (0)
65
@@ -294,6 +294,8 @@ struct rrd_dimension {
294
295
void *values;
296
297
+ time_t last_updated;
298
+
299
struct rrd_dimension *next;
300
};
301
typedef struct rrd_dimension RRD_DIMENSION;
@@ -301,11 +303,18 @@ typedef struct rrd_dimension RRD_DIMENSION;
303
struct rrd_stats {
304
pthread_mutex_t mutex;
305
306
+ char id[RRD_STATS_NAME_MAX + 1];
307
char name[RRD_STATS_NAME_MAX + 1];
308
+ char title[RRD_STATS_NAME_MAX + 1];
309
+ char vtitle[RRD_STATS_NAME_MAX + 1];
310
+
311
+ char type[RRD_STATS_NAME_MAX + 1];
312
313
size_t entries;
314
size_t last_entry;
315
316
+ time_t last_updated;
317
+
318
struct timeval *times;
319
RRD_DIMENSION *dimensions;
320
struct rrd_stats *next;
@@ -315,7 +324,7 @@ typedef struct rrd_stats RRD_STATS;
324
RRD_STATS *root = NULL;
325
pthread_mutex_t root_mutex = PTHREAD_MUTEX_INITIALIZER;
326
318
-RRD_STATS *rrd_stats_create(const char *name, unsigned long entries)
327
+RRD_STATS *rrd_stats_create(const char *id, const char *name, unsigned long entries, const char *title, const char *vtitle, const char *type)
328
{
329
RRD_STATS *st = NULL;
330
@@ -331,12 +340,25 @@ RRD_STATS *rrd_stats_create(const char *name, unsigned long entries)
340
return NULL;
341
}
342
343
+ strncpy(st->id, id, RRD_STATS_NAME_MAX);
344
+ st->id[RRD_STATS_NAME_MAX] = '\0';
345
+
346
strncpy(st->name, name, RRD_STATS_NAME_MAX);
347
st->name[RRD_STATS_NAME_MAX] = '\0';
348
349
+ strncpy(st->title, title, RRD_STATS_NAME_MAX);
350
+ st->title[RRD_STATS_NAME_MAX] = '\0';
351
+
352
+ strncpy(st->vtitle, vtitle, RRD_STATS_NAME_MAX);
353
+ st->vtitle[RRD_STATS_NAME_MAX] = '\0';
354
+
355
+ strncpy(st->type, type, RRD_STATS_NAME_MAX);
356
+ st->type[RRD_STATS_NAME_MAX] = '\0';
357
+
358
st->entries = entries;
359
st->last_entry = 0;
360
st->dimensions = NULL;
361
+ st->last_updated = time(NULL);
362
363
pthread_mutex_init(&st->mutex, NULL);
364
pthread_mutex_lock(&st->mutex);
@@ -355,7 +377,7 @@ RRD_DIMENSION *rrd_stats_dimension_add(RRD_STATS *st, const char *id, const char
377
{
378
RRD_DIMENSION *rd = NULL;
379
358
- debug(D_RRD_STATS, "Adding dimension '%s' to RRD_STATS '%s'.", name, st->name);
380
+ debug(D_RRD_STATS, "Adding dimension '%s' (%s) to RRD_STATS '%s' (%s).", name, id, st->name, st->id);
381
382
rd = calloc(sizeof(RRD_DIMENSION), 1);
383
if(!rd) return NULL;
@@ -372,6 +394,8 @@ RRD_DIMENSION *rrd_stats_dimension_add(RRD_STATS *st, const char *id, const char
394
}
395
396
strncpy(rd->id, id, RRD_STATS_NAME_MAX);
397
+ rd->id[RRD_STATS_NAME_MAX] = '\0';
398
+
399
strncpy(rd->name, name, RRD_STATS_NAME_MAX);
400
rd->name[RRD_STATS_NAME_MAX] = '\0';
401
@@ -381,7 +405,29 @@ RRD_DIMENSION *rrd_stats_dimension_add(RRD_STATS *st, const char *id, const char
405
return(rd);
406
}
407
384
-RRD_STATS *rrd_stats_find(const char *name)
408
+void rrd_stats_dimension_free(RRD_DIMENSION *rd)
409
+{
410
+ if(rd->next) rrd_stats_dimension_free(rd->next);
411
+ debug(D_RRD_STATS, "Removing dimension '%s'.", rd->name);
412
+ free(rd->values);
413
+ free(rd);
414
+}
415
+
416
+RRD_STATS *rrd_stats_find(const char *id)
417
+{
418
+ pthread_mutex_lock(&root_mutex);
419
+
420
+ RRD_STATS *st = root;
421
+
422
+ for ( ; st ; st = st->next ) {
423
+ if(strcmp(st->id, id) == 0) break;
424
+ }
425
+
426
+ pthread_mutex_unlock(&root_mutex);
427
+ return(st);
428
+}
429
+
430
+RRD_STATS *rrd_stats_find_byname(const char *name)
431
{
432
pthread_mutex_lock(&root_mutex);
433
@@ -424,6 +470,33 @@ void rrd_stats_next(RRD_STATS *st)
470
471
void rrd_stats_done(RRD_STATS *st)
472
{
473
+ RRD_DIMENSION *rd, *last;
474
+
475
+ // find if there are any obsolete dimensions (not updated recently)
476
+ for( rd = st->dimensions, last = NULL ; rd ; ) {
477
+ if(rd->last_updated < st->last_updated) {
478
+ debug(D_RRD_STATS, "Removing obsolete dimension '%s' (%s) of '%s' (%s).", rd->name, rd->id, st->name, st->id);
479
+
480
+ if(!last) {
481
+ st->dimensions = rd->next;
482
+ rd->next = NULL;
483
+ rrd_stats_dimension_free(rd);
484
+ rd = st->dimensions;
485
+ continue;
486
+ }
487
+ else {
488
+ last->next = rd->next;
489
+ rd->next = NULL;
490
+ rrd_stats_dimension_free(rd);
491
+ rd = last->next;
492
+ continue;
493
+ }
494
+ }
495
+
496
+ last = rd;
497
+ rd = rd->next;
498
+ }
499
+
500
pthread_mutex_unlock(&st->mutex);
501
}
502
@@ -431,10 +504,12 @@ void rrd_stats_dimension_set(RRD_STATS *st, const char *id, void *data)
504
{
505
RRD_DIMENSION *rd = rrd_stats_dimension_find(st, id);
506
if(!rd) {
434
- error("Cannot find dimension with id '%s' on stats '%s'.", id, st->name);
507
+ error("Cannot find dimension with id '%s' on stats '%s' (%s).", id, st->name, st->id);
508
return;
509
}
510
511
+ rd->last_updated = st->last_updated;
512
+
513
if(rd->bytes == sizeof(long long)) {
514
long long *dimension = rd->values, *value = data;
515
@@ -461,6 +536,32 @@ void rrd_stats_dimension_set(RRD_STATS *st, const char *id, void *data)
536
#define GROUP_AVERAGE 0
537
#define GROUP_MAX 1
538
539
+size_t rrd_stats_all_xml(char *buffer, size_t len)
540
+{
541
+ RRD_STATS *st;
542
+ size_t i = 0;
543
+
544
+ i += sprintf(&buffer[i], "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n<?xml-stylesheet type=\"text/xsl\" href=\"all.xsl\"?>\n\n<catalog>\n");
545
+
546
+ for(st = root; st ; st = st->next) {
547
+ if(i+ 200 > len) break;
548
+
549
+ i += sprintf(&buffer[i], "\t<graph>\n");
550
+ i += sprintf(&buffer[i], "\t\t<id>%s</id>\n", st->id);
551
+ i += sprintf(&buffer[i], "\t\t<name>%s</name>\n", st->name);
552
+ i += sprintf(&buffer[i], "\t\t<type>%s</type>\n", st->type);
553
+ i += sprintf(&buffer[i], "\t\t<title>%s%s</title>\n", st->title, st->name);
554
+ i += sprintf(&buffer[i], "\t\t<vtitle>%s</vtitle>\n", st->vtitle);
555
+ i += sprintf(&buffer[i], "\t\t<dataurl>/data/%s</dataurl>\n", st->name);
556
+ i += sprintf(&buffer[i], "\t\t<entries>%ld</entries>\n", st->entries);
557
+ i += sprintf(&buffer[i], "\t</graph>\n");
558
+ }
559
+
560
+ i += sprintf(&buffer[i], "</catalog>\n");
561
+
562
+ return(i);
563
+}
564
+
565
size_t rrd_stats_json(RRD_STATS *st, char *b, size_t length, size_t entries_to_show, size_t group_count, int group_method)
566
{
567
pthread_mutex_lock(&st->mutex);
@@ -785,9 +886,16 @@ int mysendfile(struct web_client *w, char *filename)
886
return 404;
887
}
888
788
- w->ifd = open(filename, O_NONBLOCK, O_RDONLY);
889
+ int failcount = 0;
890
+ while(failcount < 100) {
891
+ w->ifd = open(filename, O_NONBLOCK, O_RDONLY);
892
+ if(w->ifd != -1 || (errno != EBUSY && errno != EAGAIN)) break;
893
+ failcount++;
894
+ error("%llu: file '%s' is busy, trying again...", w->id, filename);
895
+ usleep(500);
896
+ }
897
if(w->ifd < 0) {
790
- debug(D_WEB_CLIENT_ACCESS, "%llu: Cannot open file '%s'.", w->id, filename);
898
+ error("%llu: Cannot open file '%s'.", w->id, filename);
899
w->data->bytes = sprintf(w->data->buffer, "Cannot open file '%s'.", filename);
900
w->ifd = w->ofd;
901
return 404;
@@ -887,7 +995,7 @@ void web_client_process(struct web_client *w)
995
debug(D_WEB_CLIENT, "%llu: Searching for RRD data with name '%s'.", w->id, tok);
996
997
// do we have such a data set?
890
- RRD_STATS *st = rrd_stats_find(tok);
998
+ RRD_STATS *st = rrd_stats_find_byname(tok);
999
if(!st) {
1000
// we don't have it
1001
code = 404;
@@ -923,7 +1031,7 @@ void web_client_process(struct web_client *w)
1031
else debug(D_WEB_CLIENT, "%llu: Unknown group method '%s'", w->id, tok);
1032
}
1033
926
- debug(D_WEB_CLIENT_ACCESS, "%llu: Sending RRD data '%s' (%d lines, %d group_count, %d group_method).", w->id, st->name, lines, group_count, group_method);
1034
+ debug(D_WEB_CLIENT_ACCESS, "%llu: Sending RRD data '%s' (id %s, %d lines, %d group_count, %d group_method).", w->id, st->name, st->id, lines, group_count, group_method);
1035
1036
code = 200;
1037
w->data->contenttype = CT_APPLICATION_JSON;
@@ -949,6 +1057,12 @@ void web_client_process(struct web_client *w)
1057
for ( ; st ; st = st->next )
1058
w->data->bytes += sprintf(&w->data->buffer[w->data->bytes], "%s\n", st->name);
1059
}
1060
+ else if(strcmp(tok, "all.xml") == 0) {
1061
+ code = 200;
1062
+ debug(D_WEB_CLIENT_ACCESS, "%llu: Sending all.xml of RRD_STATS...", w->id);
1063
+ w->data->contenttype = CT_TEXT_XML;
1064
+ w->data->bytes = rrd_stats_all_xml(w->data->buffer, w->data->size);
1065
+ }
1066
else if(strcmp(tok, "file") == 0) {
1067
code = mysendfile(w, url);
1068
}
@@ -1385,7 +1499,7 @@ int do_proc_net_dev() {
1499
RRD_STATS *st = rrd_stats_find(name);
1500
1501
if(!st) {
1388
- st = rrd_stats_create(name, save_history);
1502
+ st = rrd_stats_create(name, name, save_history, "Network usage for ", "Bandwidth in kilobits/s", "net");
1503
if(!st) {
1504
error("Cannot create RRD_STATS for interface %s.", name);
1505
continue;
@@ -1486,7 +1600,7 @@ int do_proc_diskstats() {
1600
}
1601
else error("Cannot read sector size for device %s from %s. Assuming 512.", name, ssfilename);
1602
1489
- st = rrd_stats_create(name, save_history);
1603
+ st = rrd_stats_create(name, name, save_history, "Disk usage for ", "I/O in kilobytes/s", "disk");
1604
if(!st) {
1605
error("Cannot create RRD_STATS for disk %s.", name);
1606
continue;
@@ -1578,6 +1692,7 @@ struct tc_class {
1692
};
1693
1694
struct tc_device {
1695
+ char id[RRD_STATS_NAME_MAX + 1];
1696
char name[RRD_STATS_NAME_MAX + 1];
1697
1698
struct tc_class *classes;
@@ -1614,9 +1729,9 @@ void tc_device_commit(struct tc_device *d)
1729
1730
debug(D_TC_LOOP, "Committing TC device '%s'", d->name);
1731
1617
- RRD_STATS *st = rrd_stats_find(d->name);
1732
+ RRD_STATS *st = rrd_stats_find(d->id);
1733
if(!st) {
1619
- st = rrd_stats_create(d->name, save_history);
1734
+ st = rrd_stats_create(d->id, d->name, save_history, "Class usage for ", "Bandwidth in kilobits/s", "tc");
1735
if(!st) {
1736
error("Cannot create RRD_STATS for interface %s.", d->name);
1737
return;
@@ -1644,11 +1759,19 @@ void tc_device_set_class_name(struct tc_device *d, char *id, char *name)
1759
for ( c = d->classes ; c ; c = c->next) {
1760
if(strcmp(c->id, id) == 0) {
1761
strncpy(c->name, name, RRD_STATS_NAME_MAX);
1762
+ c->name[RRD_STATS_NAME_MAX] = '\0';
1763
break;
1764
}
1765
}
1766
}
1767
1768
+void tc_device_set_device_name(struct tc_device *d, char *name)
1769
+{
1770
+ strcpy(d->name, "tc.");
1771
+ strncpy(&d->name[3], name, RRD_STATS_NAME_MAX - 3);
1772
+ d->name[RRD_STATS_NAME_MAX] = '\0';
1773
+}
1774
+
1775
struct tc_device *tc_device_create(char *name)
1776
{
1777
struct tc_device *d;
@@ -1658,6 +1781,9 @@ struct tc_device *tc_device_create(char *name)
1781
1782
strcpy(d->name, "tc.");
1783
strncpy(&d->name[3], name, RRD_STATS_NAME_MAX - 3);
1784
+ d->name[RRD_STATS_NAME_MAX] = '\0';
1785
+
1786
+ strcpy(d->id, d->name);
1787
1788
return(d);
1789
}
@@ -1749,10 +1875,14 @@ void *tc_main(void *ptr)
1875
p = strsep(&b, " \n");
1876
if(p && *p) class->bytes = atoll(p);
1877
}
1878
+ else if(device && (strcmp(p, "SETDEVICENAME") == 0)) {
1879
+ char *name = strsep(&b, " |\n");
1880
+ if(name && *name) tc_device_set_device_name(device, name);
1881
+ }
1882
else if(device && (strcmp(p, "SETCLASSNAME") == 0)) {
1883
char *name = strsep(&b, " |\n");
1884
char *id = strsep(&b, " |\n");
1755
- tc_device_set_class_name(device, id, name);
1885
+ if(id && *id && name && *name) tc_device_set_class_name(device, id, name);
1886
}
1887
else if((strcmp(p, "MYPID") == 0)) {
1888
char *id = strsep(&b, " \n");
netdata.js
+57
-36
@@ -4,6 +4,8 @@
4
// Load the Visualization API and the piechart package.
5
google.load('visualization', '1', {'packages':['corechart']});
6
7
+ var charts = new Array();
8
+
9
function refreshChart(index) {
10
if(index >= charts.length) return;
11
@@ -26,15 +28,8 @@
28
}
29
30
var width = charts[index].width;
29
- if(width == 0) width = (window.innerWidth - 40) / 2;
30
- if(width <= 10) width = (window.innerWidth - 40) / width;
31
- if(width < 200) width = 200;
32
-
31
var height = charts[index].height;
34
- if(height == 0) height = (window.innerHeight - 20) / 2;
35
- if(height <= 10) height = (window.innerHeight - 20) / height;
36
- if(height < 100) height = 100;
37
-
32
+
33
var hAxisTitle = null;
34
var vAxisTitle = null;
35
if(height >= 200) hAxisTitle = "Time of Day";
@@ -62,34 +57,21 @@
57
else console.log('Cannot create chart for ' + charts[index].url);
58
}
59
65
- var charts = new Array();
66
- function drawChart(name, div, width, height, jsonurl, title, vtitle) {
67
- var i;
68
-
69
- for(i = 0; i < charts.length; i++)
70
- if(charts[i].name == name) break;
71
-
72
- if(i >= charts.length) {
73
- console.log('Creating new objects for chart ' + name);
74
- charts[i] = [];
75
- charts[i].chart = null;
76
- charts[i].jsondata = null;
77
- charts[i].datatable = null;
78
- charts[i].name = name;
79
- charts[i].div = div;
80
- charts[i].width = width;
81
- charts[i].height = height;
82
- charts[i].url = jsonurl;
83
- charts[i].title = title;
84
- charts[i].vtitle = vtitle;
85
- }
60
+ function addChart(name, div, width, height, jsonurl, title, vtitle) {
61
+ var i = charts.length;
62
87
- try {
88
- refreshChart(i);
89
- }
90
- catch(err) {
91
- console.log('Cannot create chart for ' + jsonurl);
92
- }
63
+ console.log('Creating new objects for chart ' + name);
64
+ charts[i] = [];
65
+ charts[i].chart = null;
66
+ charts[i].jsondata = null;
67
+ charts[i].datatable = null;
68
+ charts[i].name = name;
69
+ charts[i].div = div;
70
+ charts[i].url = jsonurl;
71
+ charts[i].title = title;
72
+ charts[i].vtitle = vtitle;
73
+ charts[i].width = width;
74
+ charts[i].height = height;
75
}
76
77
var charts_last_drawn = 999999999;
@@ -98,22 +80,61 @@
80
if(charts.length == 0) return;
81
82
var h = howmany;
101
- if(h == 0) h = 1;
83
+ if(h == 0) h = charts.length;
84
if(h > charts.length) h = charts.length;
85
//console.log('Will run for ' + h + ' charts');
86
87
+ var width = Math.round(Math.sqrt(charts.length));
88
+ var height = Math.round(Math.sqrt(charts.length));
89
+ while((width * height) < charts.length) {
90
+ if((height + 1) <= width) height++;
91
+ else width++;
92
+ }
93
+ // console.log('all: ' + charts.length + ', optimal: width = ' + width + ', height = ' + height);
94
+
95
+ while(width > 1 && width >= height) {
96
+ width--;
97
+ height++;
98
+ }
99
+ if(width * height < charts.length) height++;
100
+ // console.log('final: width = ' + width + ', height = ' + height);
101
+
102
+ if(width == 0) width = (document.documentElement.clientWidth - 40) / 2;
103
+ if(width <= 10) width = (document.documentElement.clientWidth - 40) / width;
104
+ if(width < 200) width = 200;
105
+
106
+ if(height == 0) height = (document.documentElement.clientHeight - 20) / 2;
107
+ if(height <= 10) height = (document.documentElement.clientHeight - 20) / height;
108
+ if(height < 100) height = 100;
109
+
110
+ // console.log('width = ' + width + ', height = ' + height);
111
+
112
var i;
113
for(i = 0; i < h; i++) {
114
+ var zeroDimensions = 0;
115
+
116
charts_last_drawn++;
117
if(charts_last_drawn >= charts.length) charts_last_drawn = 0;
118
119
+ if(charts[charts_last_drawn].width == 0 && charts[charts_last_drawn].height == 0) {
120
+ charts[charts_last_drawn].width = width;
121
+ charts[charts_last_drawn].height = height;
122
+ zeroDimensions = 1;
123
+ }
124
+
125
try {
126
+
127
console.log('Refreshing chart ' + charts[charts_last_drawn].name);
128
refreshChart(charts_last_drawn);
129
}
130
catch(err) {
131
console.log('Cannot refresh chart for ' + charts[charts_last_drawn].url);
132
}
133
+
134
+ if(zeroDimensions == 1) {
135
+ charts[charts_last_drawn].width = 0;
136
+ charts[charts_last_drawn].height = 0;
137
+ }
138
}
139
return 0;
140
}
netdata.start
+9
-50
@@ -75,6 +75,7 @@ else
75
echo >&2 "Directory $base/data already exists. Not touching it, however it should be a link '${data}'."
76
fi
77
78
+cp "${base}/all.xsl" "${data}/"
79
cp "${base}/netdata.js" "${data}/"
80
cp "${base}/tc-all.sh" "${data}/"
81
chmod 700 "${data}/tc-all.sh"
@@ -86,11 +87,13 @@ killall netdata 2>/dev/null
87
killall tc-all.sh 2>/dev/null
88
89
echo "Compiling netdata"
89
-gcc -Wall -O3 -o netdata netdata.c -lpthread || exit 1
90
+# gcc -Wall -O3 -o netdata netdata.c -lpthread || exit 1
91
+gcc -Wall -ggdb -o netdata netdata.c -lpthread || exit 1
92
93
echo "Starting netdata"
94
p=`pwd`
95
cd data
96
+ulimit -c unlimited
97
$p/netdata -d -u $NETDATA_CONFIG_INTERNAL_UPDATE_EVERY -l $NETDATA_HISTORY_LINES || exit 1
98
cd "$p"
99
@@ -111,48 +114,6 @@ done
114
115
echo "We have $count graphs..."
116
114
-# find the optimal graphs per page
115
-w=1
116
-h=1
117
-a=1
118
-while [ $a -lt $count ]
119
-do
120
- if [ $[h+1] -le $w ]
121
- then
122
- h=$[h+1]
123
- else
124
- w=$[w+1]
125
- h=$[h-1]
126
- fi
127
-
128
- a=$[w*h]
129
-done
130
-
131
-echo "Optimal size is $w x $h..."
132
-
133
-# prefer to have wider graphs
134
-while [ $w -ge $h ]
135
-do
136
- w=$[w-1]
137
- h=$[h+1]
138
- a=$[w*h]
139
-done
140
-if [ $a -lt $count ]
141
-then
142
- h=$[h+1]
143
-fi
144
-
145
-# make sure we don't display too small graphs
146
-if [ $w -gt 10 ]
147
-then
148
- w=10
149
-fi
150
-if [ $h -gt 10 ]
151
-then
152
- h=10
153
-fi
154
-echo "Final screen size is $w x $h..."
155
-
117
echo "Generating ${data}/index.html"
118
host="`hostname`"
119
cat >${data}/index.html <<EOF
@@ -176,9 +137,6 @@ cat >${data}/index.html <<EOF
137
google.setOnLoadCallback(drawCharts);
138
139
function drawCharts() {
179
- var width = $w; // if zero, auto-adjusts to 50% of screen, 1-10 goes 1/width of screen
180
- var height = $h;
181
-
140
// EDIT: add one line per interface you have
141
// EDIT:
142
// EDIT: name div id json data graph vertical axis title
@@ -216,7 +174,7 @@ do
174
if [ ! "$p" = "IGNORE" ]
175
then
176
cat >>${data}/index.html <<EOF2
219
- drawChart('${x}', '${y}_div', width, height, "data/${x}/${NETDATA_CONFIG_HISTORY_POINTS}/${NETDATA_CONFIG_UPDATE_EVERY}/average/", "${title}${t} (${x})", "${vtitle}");
177
+ addChart('${x}', '${y}_div', 0, 0, "data/${x}/${NETDATA_CONFIG_HISTORY_POINTS}/${NETDATA_CONFIG_UPDATE_EVERY}/average/", "${title}${t} (${x})", "${vtitle}");
178
EOF2
179
fi
180
done
@@ -234,6 +192,7 @@ then
192
fi
193
194
cat >>${data}/index.html <<EOF3
195
+ refreshCharts(999999);
196
}
197
198
var refreshCount = 0;
@@ -247,9 +206,9 @@ cat >>${data}/index.html <<EOF3
206
207
setInterval(myChartsRefresh, $tim);
208
250
- window.onresize = function(event) {
251
- refreshCharts(999999);
252
- };
209
+ //window.onresize = function(event) {
210
+ // refreshCharts(999999);
211
+ //};
212
</script>
213
214
</head>
tc-all.sh
+1
-1
@@ -18,7 +18,7 @@ do
18
if [ -f /var/run/fireqos/ifaces/$x ]
19
then
20
name=`cat /var/run/fireqos/ifaces/$x`
21
- # echo "SETDEVICENAME $name"
21
+ echo "SETDEVICENAME $name"
22
interface_classes=
23
source /var/run/fireqos/$name.conf
24
for x in $interface_classes