I want to get all SSM inventory (and later patch) information across the organisation to one bucket. I created the bucket, and configured permissions, as details here.
The problem I have is actually creating the datasync. The page has the following example:
aws ssm create-resource-data-sync --sync-name name --s3-destination “BucketName=DOC-EXAMPLE-BUCKET,Prefix=prefix-name,SyncFormat=JsonSerDe,Region=AWS Region, for example us-east-2,DestinationDataSharing={DestinationDataSharingType=Organization}”
When I change the bucket name and region, I get the following error:
An error occurred (ResourceDataSyncInvalidConfigurationException) when calling the CreateResourceDataSync operation: Organization Id is required when DestinationDataSharing is selected in S3Destination
I can’t find anything about specifying an org ID anywhere in the documentation.
Thanks. Have you actually got this to work? Is I use SyncFromSource, it sounds like it need to run it in the org account, but the AWS documentation talks about it running the cli in all accounts in all regions?
After a few attempts with previous versions of the JSON, it now completes without error, which is a good sign I think. But I don’t see anything in my S3 bucket yet..
So feel like I am getting further, but still not sure if it is not missing something?
I actually implemented this at work the other week and didnt run into any issues.. i used Terraform to deploy the configs but I did all the account/region deployments separately (we have a cicd in place) havent tried doing an org wide deployment from the master acc
Create your S3 bucket in the root account, and configure permissions for all of your other accounts.
Create you inventory data-sync in each account, pointing to the s3 bucket you created above (if you get errors, check your JSON for the correct arn format)
Check that you have inventory data in bucket (you may need to give it a few minutes)
Then go to Athena, and create the tables and namespaces for the data you are collecting
Optionally, sign up for a trial of quicksight to view it all.
This link was pretty good at sorting it all out, and of course the other comments here!