# blade create process stop

暂停进程

## 介绍

此实验会暂停进程。支持命令行或者命令中进程匹配。

此实验可以验证程序 Hang 时，系统的容错能力。

## 参数

```
--process string       进程关键词，会在整个命令行中查找
--process-cmd string   进程命令，只会在命令中查找
--timeout string   设定运行时长，单位是秒，通用参数
```

## 案例

```
# 暂停包含 SimpleHTTPServer 关键词的进程
blade create process stop --process SimpleHTTPServer

# 暂停 java 进程
blade create process stop --process-cmd java
```

## 实现原理

\--process 内部使用 ps -ef | grep KEY 查找；--process-cmd 内部使用 pgrep 命令查找。使用 kill -STOP PIDS 暂停进程，使用 kill -CONT PIDS 恢复进程。

## 常见错误

Q：查找不到 UID，无法恢复暂停的进程 A：手动执行 kill -CONT PIDS


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://chaosblade-io.gitbook.io/chaosblade-help-zh-cn/blade-create-process-stop.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
