Skip to content

Run Commands in AWS Systems Manager

Sona Arzumanyan edited this page Sep 27, 2024 · 9 revisions

How to Run Commands on Multiple Instances in AWS Systems Manager

AWS Systems Manager allows you to run commands on multiple EC2 instances. Follow the steps below to execute a command on selected instances:

1. Open AWS Systems Manager Console

Log in to your AWS Management Console and navigate to Systems Manager.

2. Access the "Run Command" Section

In Systems Manager, go to Node Management and select the Run Command option from the left-hand menu.

3. Initiate a New Command

In the Run Command section, click the Run Command button located in the top-right corner.

4. Select Command Type

In the Command document section:

  • Choose AWS-RunShellScript from the list of available command types.

5. Enter Commands

In the Commands section:

  • Write the shell script or specific commands that you want to execute on your EC2 instances.

6. Select Target Instances

In the Target selection section:

  • Choose Select instances manually.
  • From the list of available instances, select the ones you wish to target.

7. Execute the Command

Scroll to the bottom of the page and click the Run button to execute the command on the chosen instances.


You can monitor the status and output of the command in the Command history section.

Clone this wiki locally