【发布时间】:2020-09-16 12:12:10
【问题描述】:
在生产系统(Centos 7)上运行“mount -a”时,我得到返回码 64
try:
subprocess.check_call(["mount", "-a"])
except subprocess.CalledProcessError as e:
raise Exception("Failed to run mount command. error:%s", str(e))
以下是日志:
raise Exception("Failed to run mount command. error:%s", str(e))
Exception: ('Failed to run mount command. error:%s', "Command '['mount', '-a']' returned non-zero exit status 64")
退出代码 64 是什么意思?
【问题讨论】:
-
检查
man mount的返回码。
标签: python centos subprocess centos7