100 Days of AWS — Day 20- AWS System Manager — Part 1

  1. Setting up IAM Role for System Manager
  • Give your role some meaningful name and click on Create role
  • Choose the IAM Role, you have create in previous step and click on Save.
$ cat /etc/os-releaseNAME="Amazon Linux"VERSION="2"
  • To verify it
$ rpm -qa|grep -i ssmamazon-ssm-agent-3.1.1188.0-1.amzn2.x86_64
  • In order to install the agent on Centos/RedHat run the below command
sudo yum install -y https://s3.amazonaws.com/ec2-downloads-windows/SSMAgent/latest/linux_amd64/amazon-ssm-agent.rpm
  • Under Node Management → Run Command → Run a Command
  • Under Run a command, select AWS-RunShellScript, under Commands (ls -l ) and under Choose Instances Manually. Click on Run
  • If the command is executed successfully, you will see the Overall status as Success.
  • Click on the instance and check the output
  • You can execute the same command via AWS cli
$ aws ssm send-command --document-name "AWS-RunShellScript" --parameters commands=["ls -l"] --targets "Key=instanceids,Values=<instance id"
  • In the next tab
  • Give you inventory some name
    * Targets: Either Manually select the instance or better to use Tag so that all the future installed instance will be tracked automatically
    * Schedule: How frequently you want to collect Inventory
    * Parameter: Different Parameter you want to collect
  • After waiting for few min, you will see something like this

--

--

--

AWS Community Builder, Ex-Redhat, Author, Blogger, YouTuber, RHCA, RHCDS, RHCE, Docker Certified,4XAWS, CCNA, MCP, Certified Jenkins, Terraform Certified, 1XGCP

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Snowpark Fast & Furious: Streamlining your Data Pipelines

Lessons Learned from Airflow 2.0

Trump Lost — But Trumpism Won

My first project at coding bootcamp

Use VSCode and Remote SSH extension to connect to Compute Engine on Google Cloud

“Testers just Validate Acceptance Criteria”

Object Recognition using CNN Model

Why Google makes Kotlin an Official programming language for Android development?

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Prashant Lakhera

Prashant Lakhera

AWS Community Builder, Ex-Redhat, Author, Blogger, YouTuber, RHCA, RHCDS, RHCE, Docker Certified,4XAWS, CCNA, MCP, Certified Jenkins, Terraform Certified, 1XGCP

More from Medium

Labs, exam scenarios and ALL you need for AWS Security Specialty Certification.

AWS Certified Solution Architect — ELB

Containers on AWS

VPN Service — AWS vs Azure vs GCP