Ana*_*kov 9 execute amazon-web-services amazon-ecs aws-cli
我在跑步aws ecs execute-command --cluster UltimaF --task 838d773b17954bcfbbacf343fb4fea70 --container ultima --interactive --command "/bin/sh"
取回:An error occurred (InvalidParameterException) when calling the ExecuteCommand operation: The execute command failed because execute command was not enabled when the task was run or the execute command agent isn\xe2\x80\x99t running. Wait and try again or run a new task with execute command enabled and try again.
我已保证:
\naws ecs describe-tasks --cluster UltimaF --tasks 838d773b17954bcfbbacf343fb4fea70回报"enableExecuteCommand": truessmmessages:CreateControlChannelssmmessages:CreateDataChannelssmmessages:OpenControlChannelssmmessages:OpenDataChannel我在 Windows 上运行,aws-cli/2.8.2
\n更新:\n运行ecs exec 检查器后后,我有两个黄色项目和一个红色项目:
\n ----------\n Managed Agent Status\n ----------\n 1. STOPPED (Reason: null) for "ultima" - LastStartedAt: null\n ----------\n Init Process Enabled (first-run-task-definition:12)\n ----------\n 1. Disabled - "ultima" \nRun Code Online (Sandbox Code Playgroud)\n更新二:
\n此问题表明\necs:clustername_taskid_containerruntimeid但对我来说它返回一个错误:An error occurred (TargetNotConnected) when calling the StartSession operation: ecs:UltimaF_838d773b17954bcfbbacf343fb4fea70_838d773b17954bcfbbacf343fb4fea70-2587323273 is not connected.
问题:如何连接?
\n小智 6
确保在任务定义的结构/JSON 中“ enableExecuteCommand ”设置为 true。
aws ecs describe-tasks --cluster <CLUSTER> --tasks <TASK_ARN>
| 归档时间: |
|
| 查看次数: |
14585 次 |
| 最近记录: |