Reputation: 75
Is there a command in the AWS cli to get a list of services running on my ec2 instances?
Normally I log into each ec2 instance individually, and check using Linux commands such as "netstat" or "ps -eaf".
There are around 400 instances, so if I do this manually it takes quite a lot of time. If any AWS commands are there to find the services running without actually logging into the instance, it would be great.
Thanks in advance.
Upvotes: 0
Views: 3395
Reputation: 36224
You might have some luck with EC2 Run Command. From their docs:
Run Command provides a simple way of automating common administrative tasks like executing Shell scripts and commands on Linux [...] Run Command allows you to execute these commands across multiple instances and provides visibility into the results
Upvotes: 1
Reputation: 663
The AWS Command Line Interface is a tool to manage your AWS services. You cannot use AWS-CLI to manage OS-level service. With AWS-CLI, you can control multiple AWS services from the command line and automate them through scripts.
Hope it helps :-)
Upvotes: 5