26 from cm.utils
import log
31 log.debug(0,
"Execute command: %s" % str(command_list))
32 log_file = file(
'/var/log/cc1/cm_thread.log',
'a')
33 r = subprocess.call(command_list, stdout=log_file, stderr=log_file)
36 log.error(0,
"Execute command %s failed: %s" % (str(command_list), e))
42 log.debug(0,
"Execute command (with output): %s" % str(command_list))
43 p = subprocess.Popen(command_list, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
46 log.error(0,
"Execute command (with output) %s failed: %s" % (str(command_list), e))