InvalidInstanceId
The following problems can cause this exception:
You don't have permission to access the managed node.
Amazon Web Services Systems Manager Agent(SSM Agent) isn't running. Verify that SSM Agent is running.
SSM Agent isn't registered with the SSM endpoint. Try reinstalling SSM Agent.
The managed node isn't in valid state. Valid states are:
Running
,Pending
,Stopped
, andStopping
. Invalid states are:Shutting-down
andTerminated
.