Home | History | Annotate | Download | only in server

Lines Matching refs:host

32         # maps hostname to (host object, autotest.Autotest object, Autotest
33 # install dir), where the host object is the one created specifically
67 for host in self.job.hosts:
68 if host.hostname not in self.job.machines:
69 # job.hosts include all host instances created on the fly.
73 autodir = host.get_autodir()
75 in_use_hosts[host.hostname] = host
78 # determine what valid host objects we already have installed
80 for host, at, profiler_dir in self.installed_hosts.values():
81 if host.path_exists(profiler_dir):
82 profiler_hosts.add(host.hostname)
86 host.hostname, profiler_dir)
87 del self.installed_hosts[host.hostname]
93 host = in_use_hosts[hostname]
94 tmp_dir = host.get_tmp_dir(parent=PROFILER_TMPDIR)
95 at = autotest.Autotest(host)
97 self.installed_hosts[host.hostname] = (host, at, tmp_dir)
104 def _get_hosts(self, host=None):
106 Returns a list of (Host, Autotest, install directory) tuples for hosts
107 currently supported by this profiler. The returned Host object is always
109 'host' is not None, all entries not matching that host object are
112 if host is None:
114 if host.hostname in self.installed_hosts:
115 return [self.installed_hosts[host.hostname]]
132 def _get_failure_logs(self, autodir, test, host):
139 dir=self._get_local_profilers_dir(test, host.hostname))
141 host.get_file(get_profiler_log_path(autodir), path)
143 self._get_profiler_logs(autodir, test, host)
151 for host, at, autodir in hosts:
152 self._get_failure_logs(autodir, test, host)
155 def _get_profiler_logs(self, autodir, test, host):
157 local_dir = self._get_local_profilers_dir(test, host.hostname)
159 self.job.remove_client_log(host.hostname, results_dir, local_dir)
163 host.get_file(results_dir + '/', tempdir)
180 for host, at, autodir in hosts:
182 host.hostname,
188 self._get_failure_logs(autodir, test, host)
193 host.hostname)
194 self.job.add_client_log(host.hostname, remote_results_dir,
205 def before_start(self, test, host=None):
206 # create host objects and install the needed clients
209 self._run_clients(test, self._get_hosts(host))
212 def start(self, test, host=None):
213 hosts = self._get_hosts(host)
239 def report(self, test, host=None):
242 hosts = self._get_hosts(host)
245 if not host:
254 for host, at, autodir in hosts:
255 self._get_profiler_logs(autodir, test, host)
258 def handle_reboot(self, host):
268 self.report(test, host)
269 self.before_start(test, host)
270 self.start(test, host)