def starttime(pid):
"""starttime(pid) -> float
Arguments:
pid (int): PID of the process.
Returns:
The time (in seconds) the process started after system boot
"""
return psutil.Process(pid).create_time() - psutil.boot_time()
评论列表
文章目录