Beispiel #1
0
end_time = time.time()

results_collector.gather_end_results()

end_txg = ZfsApi.get_current_txg(Configs.main_pool)

time_elapsed = end_time - start_time

print("that took " + str(datetime.timedelta(seconds=time_elapsed)))

elapsed_txgs = end_txg - start_txg
txgs_per_second = elapsed_txgs / time_elapsed

print("TXGs/second: " + str(txgs_per_second))

property_dictionary = ZfsApi.get_filesystem_properties(zfs_receive_path, ['used'])

used_in_bytes = property_dictionary["used"]
used_in_mebibytes = Common.bytes_to_mebibyte(used_in_bytes)

print("received " + str(used_in_bytes))

bytes_per_second = used_in_mebibytes / time_elapsed

print("Speed: " + str(bytes_per_second) + " MiB/s")

# Clean up the PID file to allow other runs
Pid.destroy_pid_file()

    pass

end_time = time.time()

results_collector.gather_end_results()

end_txg = ZfsApi.get_current_txg(Configs.main_pool)

time_elapsed = end_time - start_time

print("that took " + str(datetime.timedelta(seconds=time_elapsed)))

elapsed_txgs = end_txg - start_txg
txgs_per_second = elapsed_txgs / time_elapsed

print("TXGs/second: " + str(txgs_per_second))

property_dictionary = ZfsApi.get_filesystem_properties(zfs_receive_path, ["used"])

used_in_bytes = property_dictionary["used"]
used_in_mebibytes = Common.bytes_to_mebibyte(used_in_bytes)

print("received " + str(used_in_bytes))

bytes_per_second = used_in_mebibytes / time_elapsed

print("Speed: " + str(bytes_per_second) + " MiB/s")

# Clean up the PID file to allow other runs
Pid.destroy_pid_file()