So,
I use automatic logging using AWS Lambda. It generates log flows with names that look like this: 2016/05/18/[$LATEST]99577d10a8cb420cb124a90c20d5653a
I can query, using 'aws logs describe-log-streams', the available log streams and get some JSON containing these names, along with other metadata.
However, if I try to do this:
aws logs get-log-events --log-group-name /aws/lambda/categorise --log-stream-name "2016/05/18/[$LATEST]99577d10a8cb420cb124a90c20d5653a"
I get an error
A client error (ResourceNotFoundException) occurred when calling the GetLogEvents operation: The specified log stream does not exist.
Thus, if the log stream name returned by the describe log stream command does not actually exist. What is it?
I tried to hack the command a bit by deleting [$LATEST] , quoting it, running away. But no joy. Has anyone managed to recover their Lambda log events using aws cli?
source share