1 Answer
- Newest
- Most votes
- Most comments
0
I had the same issue - I fixed it by using the aws cli. This seems to be a bug in aws console. You are able to enable inspector but if it gets stuck in a disabling state there is no way to disable from the UI because you cannot access inspector in order to disable it... The command line allows you to send a disable command to inspector even when the state is disabling.
aws inspector2 enable --region us-east-2 --account-ids 111111111111 --resource-types EC2
{
"accounts": [],
"failedAccounts": [
{
"accountId": "111111111111",
"errorCode": "DISABLE_IN_PROGRESS",
"errorMessage": "Two state changes cannot be made at the same time. Wait till current statu>
"resourceStatus": {
"ec2": "DISABLED",
"ecr": "DISABLED"
},
"status": "DISABLE_FAILED"
}
]
}
aws inspector2 disable --region us-east-2 --account-ids 1111111111 --resource-types EC2
{
"accounts": [
{
"accountId": "1111111111",
"resourceStatus": {
"ec2": "DISABLED",
"ecr": "DISABLED"
},
"status": "DISABLING"
}
],
"failedAccounts": []
}
aws inspector2 enable --region us-east-2 --account-ids 1111111111 --resource-types EC2
{
"accounts": [
{
"accountId": "1111111111",
"resourceStatus": {
"ec2": "ENABLING",
"ecr": "DISABLED"
},
"status": "ENABLING"
}
],
"failedAccounts": []
}
aws inspector2 batch-get-account-status --region us-east-2 --account-ids 1111111111
{
"accounts": [
{
"accountId": "1111111111",
"resourceState": {
"ec2": {
"status": "ENABLING"
},
"ecr": {
"status": "DISABLED"
}
},
"state": {
"status": "ENABLED"
}
}
],
"failedAccounts": []
}
answered 2 years ago
Relevant content
- asked 4 years ago
- asked a year ago
- AWS OFFICIALUpdated 7 months ago
- AWS OFFICIALUpdated 5 months ago
- AWS OFFICIALUpdated 2 years ago