To receive notifications about scheduled maintenance, please subscribe to the mailing-list gitlab-operations@sympa.ethz.ch. You can subscribe to the mailing-list at https://sympa.ethz.ch

Commit ce6616ef authored by Reto Da Forno's avatar Reto Da Forno

config moved

git-svn-id: svn://svn.ee.ethz.ch/flocklab/trunk/shared@3340 613144d5-4475-0410-9df3-888732ad2c88
parent 26440678
#flocklab-time.ethz.ch
server 129.132.177.101 minpoll 5 maxpoll 6
#flocklab-time.ethz.ch -> changed to time.ethz.ch
server time.ethz.ch minpoll 5 maxpoll 6
server 0.ch.pool.ntp.org minpoll 5 maxpoll 6
driftfile /media/card/log/chrony/chrony.drift
fallbackdrift 16 19
keyfile /etc/chrony.keys
......@@ -9,7 +10,7 @@ dumpdir /media/card/log/chrony
logdir /media/card/log/chrony
log measurements statistics tracking rtc refclocks tempcomp
logchange 0.5
initstepslew 2 129.132.177.101
initstepslew 2 time.ethz.ch
makestep 1000 10
cmdallow 127.0.0.1
rtcfile /media/card/log/chrony/chrony.rtc
......
......@@ -219,8 +219,8 @@ function collect_stats($filename)
$utilization_per_year[$row['y']] = round((($row['duration'] + $tests_per_year[$row['y']] * $testoverhead) / (strtotime($row['maxp']) - strtotime($row['minp'])) * 100));
}
// occupancy of last 12 month, weekly resolution
$sql = 'select year(time_start_act) as y, week(time_start_act) as w, count(*) as num, sum(timestampdiff(SECOND, time_start_act, time_end_act)) as runtime from tbl_serv_tests where
datediff(DATE_SUB(DATE_SUB(CURDATE(),INTERVAL (DAY(CURDATE())-1) DAY),INTERVAL 12 MONTH),time_start_act) <=0 group by year(time_start_act), week(time_start_act) having y is not null';
$sql = 'select year(time_start_act) as y, week(time_start_act,3) as w, count(*) as num, sum(timestampdiff(SECOND, time_start_act, time_end_act)) as runtime from tbl_serv_tests where
datediff(DATE_SUB(DATE_SUB(CURDATE(),INTERVAL (DAY(CURDATE())-1) DAY),INTERVAL 12 MONTH),time_start_act) <=0 group by year(time_start_act), week(time_start_act,3) having y is not null';
$rs = mysql_query($sql) or flocklab_die('Cannot get statistics from database because: ' . mysql_error());
$utilization_per_week = Array();
while ($row = mysql_fetch_array($rs)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment