FIO needs sudo 69/11069/1
authorMark Beierl <mark.beierl@emc.com>
Wed, 9 Mar 2016 16:19:32 +0000 (11:19 -0500)
committerMark Beierl <mark.beierl@emc.com>
Wed, 9 Mar 2016 16:19:32 +0000 (11:19 -0500)
Use sudo for fio when profiling a device.

Change-Id: Ibbcbb15a2c33e1e58b7e340f9c3f6de5958f5636
JIRA: STORPERF-40
Signed-off-by: Mark Beierl <mark.beierl@emc.com>
storperf/fio/fio_invoker.py

index e343dce..017f74a 100644 (file)
@@ -8,7 +8,6 @@
 ##############################################################################
 
 from threading import Thread
-import cmd
 import json
 import logging
 import subprocess
@@ -79,7 +78,8 @@ class FIOInvoker(object):
             cmd = "ssh"
             additional_args = ['-o', 'StrictHostKeyChecking=no',
                                '-i', 'storperf/resources/ssh/storperf_rsa',
-                               'ubuntu@' + self.remote_host, "./fio"]
+                               'ubuntu@' + self.remote_host,
+                               "sudo", "./fio"]
             args = additional_args + args
 
         self.fio_process = subprocess.Popen([cmd] + args,