自学内容网 自学内容网

Linux: coreutils: timeout

文章目录

timeout

  • run a command with a time limit。
    这个命令也是很有用,可以帮助执行命令设置timeout时间。

用法参数

timeout [OPTION] DURATION COMMAND [ARG]…
启动COMMAND,如果这个命令在DURATION之后仍然在运行,就kill掉这个命令。
Mandatory arguments to long options are mandatory for short options too.
–preserve-status
exit with the same status as COMMAND, even when the command times out
–foreground
when not running timeout directly from a shell prompt, allow COMMAND to read from the TTY and get TTY signals; in this mode, children of COMMAND will not be timed out
-k, --kill-after=DURATION
also send a KILL signal if COMMAND is still running this long after the initial signal was sen


原文地址:https://blog.csdn.net/qq_36428903/article/details/120742407

免责声明:本站文章内容转载自网络资源,如本站内容侵犯了原著者的合法权益,可联系本站删除。更多内容请关注自学内容网(zxcms.com)!