# Logstash unable to authenticate and get data from AWS kinesis stream

**URL:** <https://discuss.elastic.co/t/logstash-unable-to-authenticate-and-get-data-from-aws-kinesis-stream/192203>\
**Category:** Logstash\
**Created:** [July 25, 2019, 8:56am UTC](https://discuss.elastic.co/t/logstash-unable-to-authenticate-and-get-data-from-aws-kinesis-stream/192203 "2019-07-25T08:56:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mikolaj.janczak](https://avatars.discourse-cdn.com/v4/letter/m/50afbb/32.png) [@mikolaj.janczak](https://discuss.elastic.co/u/mikolaj.janczak)\
**Post date:** [July 25, 2019, 8:56am UTC](https://discuss.elastic.co/t/logstash-unable-to-authenticate-and-get-data-from-aws-kinesis-stream/192203/1 "2019-07-25T08:56:03Z")

</div>

Hello,

I have an issue with logstash. I try to configure it to get data from AWS kinesis and upload to elastic. I tested multiple cofig files, all ended with error  
java.lang.IllegalArgumentException: profile file cannot be null

Here is input part of my config:  
input {  
kinesis {  
kinesis\_stream\_name =\> "my-kinesis-stream-name"  
checkpoint\_interval\_seconds =\> 10  
region =\> "eu-west-1"  
type =\> "kinesis"  
profile =\> "/home/user/.aws/credentials"  
initial\_position\_in\_stream =\> TRIM\_HORIZON  
}  
}

Here is credentials file:  
[default]  
aws\_access\_key\_id=my-key-id  
aws\_secret\_access\_key=my-secret-access-jey

What's more, I declared environmental variables $aws\_access\_key\_id=my-key-id and $aws\_secret\_access\_key=my-secret-access-jey in root user profile. It didn't help.

I tried to comment line with profile attribute, thinking logstash will use environmental variables, but then I get  
`Unable to load AWS credentials from Java system properties (aws.accessKeyId and aws.secretKey), com.amazonaws.auth.profile.ProfileCredentialsProvider@507ed7ba: profile file cannot be null, com.amazonaws.auth.EC2ContainerCredentialsProviderWrapper@5312121e: Unable to load credentials from service endpoint]`

I start logstash also in root user profile.

Is there any mistake, or did I miss something?  
Please help.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [August 22, 2019, 8:56am UTC](https://discuss.elastic.co/t/logstash-unable-to-authenticate-and-get-data-from-aws-kinesis-stream/192203/2 "2019-08-22T08:56:10Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
