

本文属于机器翻译版本。若本译文内容与英语原文存在差异，则一律以英文原文为准。

# `pcluster describe-cluster-instances`
<a name="pcluster.describe-cluster-instances-v3"></a>

描述集群中的实例。

```
pcluster describe-cluster-instances [-h] 
                 --cluster-name {{CLUSTER_NAME}}
                [--debug]
                [--next-token {{NEXT_TOKEN}}]
                [--node-type {HeadNode,ComputeNode,LoginNode}]
                [--query {{QUERY}}]
                [--queue-name {{QUEUE_NAME}}]
                [--region {{REGION}}]
```

## 命名的参数
<a name="pcluster-v3.describe-cluster-instances.namedargs"></a>

**-h, --help**  
显示 `pcluster describe-cluster-instances` 的帮助文本。

**--cluster-name, -n {{CLUSTER\_NAME}}**  
指定集群的名称。

**--debug**  
启用调试日志记录。

**--next-token {{NEXT\_TOKEN}}**  
用于获取下一组结果的令牌。

**--node-type {`HeadNode`,`ComputeNode`,`LoginNode`}**  
指定要列出的节点类型。支持的值为 `HeadNode`、`ComputeNode` 和 `LoginNode`。如果未指定此参数，则描述 `HeadNode`、`ComputeNode` 和 `LoginNode` 实例。

**--query {{QUERY}}**  
指定要对输出执行的 JMESPath 查询。

**--queue-name {{QUEUE\_NAME}}**  
指定要列出的队列的名称。如果未指定此参数，则描述所有队列中的实例。

**--region, -r {{REGION}}**  
指定 Amazon Web Services 区域 要使用的。 Amazon Web Services 区域 必须使用`AWS_DEFAULT_REGION`环境变量、`~/.aws/config`文件`[default]`部分中的`region`设置或`--region`参数来指定。

**使用 Amazon ParallelCluster 版本 3.1.4 的示例：**

```
$ pcluster describe-cluster-instances -n {{cluster-v3}}
{
  "instances": [
    {
      "launchTime": "2022-07-12T17:22:21.000Z",
      "instanceId": "i-1234567890abcdef0",
      "publicIpAddress": "198.51.100.44",
      "instanceType": "t2.micro",
      "state": "running",
      "nodeType": "HeadNode",
      "privateIpAddress": "192.0.2.0.196"
    },
    {
      "launchTime": "2022-07-12T17:37:42.000Z",
      "instanceId": "i-021345abcdef6789",
      "queueName": "queue1",
      "publicIpAddress": "198.51.100.44",
      "instanceType": "t2.micro",
      "state": "pending",
      "nodeType": "ComputeNode",
      "privateIpAddress": "192.0.2.0.196"
    },
    {
        "launchTime": "2022-07-12T17:37:42.000Z", 
        "instanceId": "i-021345abcdef6789", 
        "poolName": "pool1", 
        "publicIpAddress": "198.51.100.44", 
        "instanceType": "t2.micro", 
        "state": "pending", 
        "nodeType": "loginNode", 
        "privateIpAddress": "192.0.2.0.196" 
    }
  ]
}
```