doc: update command/atq.md
This commit is contained in:
parent
0ae1a1bc6e
commit
b1272c9afb
|
|
@ -7,30 +7,56 @@ atq
|
||||||
|
|
||||||
**atq命令** 显示系统中待执行的任务列表,也就是列出当前用户的at任务列表。
|
**atq命令** 显示系统中待执行的任务列表,也就是列出当前用户的at任务列表。
|
||||||
|
|
||||||
### 语法
|
### 语法
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
atq [-V] [-q 队列] [-v]
|
atq [-V] [-q 队列] [-v]
|
||||||
```
|
```
|
||||||
|
|
||||||
### 选项
|
### 选项
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
-V:显示版本号;
|
-V:显示版本号;
|
||||||
-q:查询指定队列的任务。
|
-q:查询指定队列的任务。
|
||||||
```
|
```
|
||||||
|
|
||||||
### 实例
|
### 示例
|
||||||
|
|
||||||
|
创建一个在10分钟后执行的任务,并列出当前用户的任务列表:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
at now + 10 minutes
|
[root@localhost ~]# at now + 10 minutes
|
||||||
at> echo 1111
|
at> echo 1111
|
||||||
at> <eot>
|
at> <EOT>
|
||||||
job 3 at Fri Apr 26 12:56:00 2013
|
job 3 at Fri Apr 26 12:56:00 2013
|
||||||
|
```
|
||||||
|
|
||||||
atq
|
使用`atq`命令查看当前用户的任务列表:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
[root@localhost ~]# atq
|
||||||
3 Fri Apr 26 12:56:00 2013 a root
|
3 Fri Apr 26 12:56:00 2013 a root
|
||||||
```
|
```
|
||||||
|
|
||||||
|
查询指定队列的任务:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
[root@localhost ~]# at -q a now + 10 minutes
|
||||||
|
at> echo "Task in queue a"
|
||||||
|
at> <EOT>
|
||||||
|
job 4 at Fri Apr 26 13:06:00 2013
|
||||||
|
```
|
||||||
|
|
||||||
|
使用`atq`命令查看队列`a`中的任务:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
[root@localhost ~]# atq -q a
|
||||||
|
4 Fri Apr 26 13:06:00 2013 a root
|
||||||
|
```
|
||||||
|
|
||||||
|
显示`atq`命令的版本号:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
[root@localhost ~]# atq -V
|
||||||
|
atq (GNU at) 3.1.20
|
||||||
|
```
|
||||||
Loading…
Reference in New Issue