Friday, 11 August 2017

Amazon Web Services added new features in EC2 System Manager; You can now Visualize and Query the instance Software Inventory



With the rapid development of the business sector, it has now become crucial to find the right tools to manage time, work and home systematically and easily. So with the increasing growth in technology, it has become very important to find the right management tools so that you can easily handle the systems. In 2016 at the re invent, conference AWS had introduced Amazon EC2 Manager to provide assistance with the management of the software and the systems.

Amazon EC2 System Manager is a management service that will allow you to collect software inventory, configure both Linux and Windows operating systems, Create system images, and also can apply Operating System patches. This will allow secure and remote administrations for Hybrid environments with on-premise machines set up for System Managers or EC2 instances. You can regulate and record the software set up the procedure of these instances using the AWS configuration with EC2 Service Capability.

Amazon Web Services have recently added another feature to the inventories of the EC2 Systems Manager to help you to record the metadata of your application deployments, S3 sync, OS, and System Configuration. You can aggregate the recorded inventory data automatically from the instance in multiple account and different regions and then it is stored in Amazon S3 with the help of S3 Sync for EC2 System Manager. When you store your data in Amazon S3 you can use Amazon Athena to run queries against the instance inventory and can also use Amazon QuickSight to analyze and visualize the software inventory of your instances.

Now let’s learn as to how to optimistically use Amazon S3 Sync with Amazon QuickSight and Amazon Athena to visualize and query the software inventory of instances. First, make sure that Amazon EC2 System Manager Prerequisites are completed, installation of the SSM Agent on the managed instances and the configuration of the roles and permissions in Access Management and AWS Identity.

1.     First, launch a new EC2 instance for the System Manager. After your instance is launched you then have to install the SSM Agent. It is important that the IAM user account should have administrator access in the VPC where the instance will be launched. You can also create a separate IAM user account for the EC2 System Manager instance.

2.    Installing an SSM Agent you will need to SSH into the instance and create a temporary directory. Install all the required SSM Agent software for Amazon Linux EC2 instance. On Windows instance, the SSM Agent is already launched so there is no need to install.

3.    System Manager Agent is now running on your instance you will need to use an S3 Bucket to record the inventory data. Create an S3 bucket to record the inventory data from the instance. Bucket policy will help to ensure that the EC2 System Manager has the permission to write to the bucket. To add the bucket policy you simply need to select the Permission tab in the S3 console and then select the Bucket Policy tab. Selecting the bucket policy will allow the system manager to check bucket permission and add an article to the bucket. After specifying the policy the S3 bucket is now ready to accept the instance inventory data.

4.    Go to EC2 console to configure the inventory collection using the bucket by selecting Managed Resources under the Systems Manager Shared Resources category and select the Set Inventory button. Now select the EC2 instance that was created earlier from where you can record the inventory data. You can also choose multiple instances to record the inventory data if preferred.

5.    After this just scroll down to the Schedule section where you can choose the time interval to know set the time on how much time you want the inventory metadata to be assembled from the instance. Wait for the confirmation dialogue that notes that the inventory is been deployed successfully and then click the close button to go to the main EC2 console.

6.   Click the Resource Data Sync button in the EC2 console to deploy the Resource Data sync by implementing S3 bucket for the managed instance. Enter the Sync Name, Bucket Name, Bucket Prefix and Bucket Region and then click the create button.

7.    Go to S3 bucket after few minutes just to check if that the instance inventory data is syncing to the S3 bucket. When the data is synced directly to the S3 you can then take advantage of the querying capabilities of the Amazon Athena service to display and query the instance inventory data. Create a folder in the bucket. After doing that you can then create a database for recording and querying that data which is sent from SSM to the bucket by typing CREATE DATABASE SQL Statement in the Athena Editor and selecting the Run Query Button.

8.    When the database is created, you can then create a table to capture the inventory application data from the Amazon S3 bucket synced to the System Manager Resource Data Sync.

9.    When you get the query success note, you can then run the MSCK REPAIR table command to aggregate the create table. After doing this you can run the query data against the inventory data that is synced from the EC2 System Manager to the Amazon S3 bucket. After creating the query data now you can also use Amazon QuickSight to visualize your data.

10.    Create the Amazon QuickSight account and go to the dashboard and choose the Manage Data button. Choose the New Dataset button. You can now create a data set from the Athena table that has the System Manager Inventory data by choosing Athena as the data source.

11.    Choose Visualize to create the data set and then analyze the data in the Athena Table. ApplicationType field to the graph can help you to build the visualization using the following data.


No comments:

Post a Comment

With the help of Tags, control your IAM Users and Roles

AWS Identity and Access Management (IAM) is a web service which aids you safely manage access of AWS resources. AWS Identity and Access M...