diff --git a/launch.py b/launch.py index 859cf3bf3b35ee66b083b451e03f1b75771f7d41..836c4e4f12b163cb6479b12dea92e39e32c667ab 100755 --- a/launch.py +++ b/launch.py @@ -496,7 +496,10 @@ class Scheduler: f.close() def update_state_log(self, ts, cpu_user, cpu_free, cpu_user_queue): - line = [ts, self.nr_cpus, cpu_user, cpu_free, self.cpu_free, + ts_ = datetime.fromtimestamp(ts).strftime('%m-%d %H:%M:%S') + ms = '%1.02f' % ts + ts_ += ms[-3:] + line = [ts_, self.nr_cpus, cpu_user, cpu_free, self.cpu_free, cpu_user_queue, self.cpu_user_queue, self.tsleep, self.tsleep_short, self.pbs_update_deltat, self.reload_pbsflist] @@ -578,6 +581,8 @@ class Scheduler: # we only launch a new job when we are not using more than our # quota (nr_cpus), or when there is still some room for others # to breath + # TODO: add another metric: if the total queue is bigger than + # so many nodes/cpus, don't add anything else. if (self.nr_cpus > cpu_user) and (cpu_free > self.cpu_free) and \ (cpu_user_queue < self.cpu_user_queue):