Closed mrpackethead closed 4 months ago
Looks like a problem with getting information about the Config aggregator. When you deployed, did you provide the name of an existing aggregator at deployment? Can you run the following CLI command: aws configservice describe-configuration-aggregators --configuration-aggregator-names <your-aggregator-name>
and paste the output here?
[cloudshell-user@ip-10-132-68-168 ~]$ aws configservice describe-configuration-aggregators --configuration-aggregator-names name { "ConfigurationAggregators": [ { "ConfigurationAggregatorName": "name", "ConfigurationAggregatorArn": "arn:aws:config:ap-southeast-2:9xxxxxx0:config-aggregator/config-aggregator-utxgcwgw", "AccountAggregationSources": [ { "AccountIds": [ "xxxxx" ], "AllAwsRegions": false, "AwsRegions": [ "ap-southeast-2" ] } ], "CreationTime": "2024-06-18T00:27:07.889000+00:00", "LastUpdatedTime": "2024-06-18T00:27:07.890000+00:00" } ] } [cloudshell-user@ip-10-132-68-168 ~]$
I replaed 'name' for aggreagator name, and can confirm it was ok. ( just to obfiscate real accounts ) lookign at the order of how i deployed things, it may be possible that the config aggregator was not operational before the solution was deployed.
As soon as the aggregator became operational the discovery process should have picked it up on its next run. Can you go the discovery process logs and search for a line in the logs with the following string: Organization source info
and paste that line in here. The steps to find the ECS logs are:
To retrieve the logs for the discovery component:
/ecs/workload-discovery-task
.{ "level": "info", "message": "Organization source info.", "timestamp": "2024-06-19T10:46:28.081Z" }
It looks like the aggregator you've created is not an an organization-wide aggregator. Either create a new aggregator of the required type or the just set the ConfigAggregatorName
CFN paramter in the WD template to be blank and one will be created for you.
ok, i've created a new one, that is an org-wide aggreagtor and its not erroring now. Just have to see how the collection is going.
Seems to be doing the job. Thanks for your help.
Nice! I think we can make the error message here better, it shouldn't fail silently if that field is missing so I've added that to the backlog.
I'm going to leave this open until I've released the the change to the error message
Yes, helpful error messages really help..
This has been fixed in v2.1.9 that was released yesterday.
I'm Getting this error in my /ecs/workload-discovery logs. I'm not seeing any accounts being Imported. I'm running in an organisations mode.
{ "msg": "Cannot read properties of undefined (reading 'AllAwsRegions')", "stack": "TypeError: Cannot read properties of undefined (reading 'AllAwsRegions')\n at /code/src/lib/apiClient/index.js:143:56\n at Array.map ()\n at getOrgAccounts (/code/src/lib/apiClient/index.js:134:10)\n at async Object.getAccounts (/code/src/lib/utils.js:174:24)\n at async Promise.all (index 0)\n at async discoverResources (/code/src/lib/index.js:19:69)\n at async discover (/code/src/index.js:14:3)",
"level": "error",
"message": "Error in Discovery process.",
"timestamp": "2024-06-19T06:46:23.317Z"
}
@AWS folks.. case number 171874402100195