· 9 years ago · Feb 04, 2017, 09:56 AM
1{
2 "Version": "2012-10-17",
3 "Statement": [
4 {
5 "Sid": "AllowAccessToSSM",
6 "Effect": "Allow",
7 "Action": [
8 "cloudwatch:PutMetricData",
9 "logs:CreateLogGroup",
10 "logs:CreateLogStream",
11 "logs:DescribeLogGroups",
12 "logs:DescribeLogStreams",
13 "logs:PutLogEvents"
14 ],
15 "Resource": [
16 "*"
17 ]
18 }
19 ]
20}
21
22...
23
24{
25 "Id": "PerformanceCounter",
26 "FullName": "AWS.EC2.Windows.CloudWatch.PerformanceCounterComponent.PerformanceCounterInputComponent,AWS.EC2.Windows.CloudWatch",
27 "Parameters": {
28 "CategoryName": "Memory",
29 "CounterName": "Available MBytes",
30 "InstanceName": "",
31 "MetricName": "Memory",
32 "Unit": "Megabytes",
33 "DimensionName": "InstanceId",
34 "DimensionValue": "{instance_id}"
35 }
36}
37
38...
39
40{
41 "Id": "CloudWatch",
42 "FullName": "AWS.EC2.Windows.CloudWatch.CloudWatch.CloudWatchOutputComponent,AWS.EC2.Windows.CloudWatch",
43 "Parameters":
44 {
45 "AccessKey": "",
46 "SecretKey": "",
47 "Region": "eu-west-1",
48 "NameSpace": "PerformanceMonitor"
49 }
50}
51
52If you are running EC2Config version 4.0 or later, then you must restart the SSM Agent on the instance from the Microsoft Services snap-in.