# Snapshot AWS S3 bucket

**URL:** <https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082>\
**Category:** Elasticsearch\
**Created:** [February 17, 2016, 10:59pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082 "2016-02-17T22:59:11Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![genesis](https://avatars.discourse-cdn.com/v4/letter/g/96bed5/32.png) [@genesis](https://discuss.elastic.co/u/genesis)\
**Post date:** [February 17, 2016, 10:59pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/1 "2016-02-17T22:59:11Z")

</div>

I have a script that does a snapshot to S3 and lately it has been failing (PARTIAL) and I have not idea  
Here is the error, please help

"snapshot" : "snapshot\_kibana\_feb021606",  
"version\_id" : 1070199,  
"version" : "1.7.1",  
"indices" : [".marvel-kibana", "kibana-int", ".kibana"],  
"state" : "PARTIAL",  
"start\_time" : "2016-02-17T22:39:20.239Z",  
"start\_time\_in\_millis" : 1455748760239,  
"end\_time" : "2016-02-17T22:39:21.066Z",  
"end\_time\_in\_millis" : 1455748761066,  
"duration\_in\_millis" : 827,  
"failures" : [ {  
"node\_id" : "RY2PONaTSEu-xxxxxxx",  
"index" : ".kibana",  
"reason" : "IndexShardSnapshotFailedException[[.kibana][0] The operation is not valid for the object's storage class (Service: Amazon S3; Status Code: 403; Error Code: InvalidObjec  
tState; Request ID: AFE9D8EDCE00A20F)]; nested: AmazonS3Exception[The operation is not valid for the object's storage class (Service: Amazon S3; Status Code: 403; Error Code: InvalidObje  
ctState; Request ID: AFE9D8EDCE00A20F)]; ",  
"shard\_id" : 0,  
"status" : "INTERNAL\_SERVER\_ERROR"

---

<div class="post-metadata">

**Author:** ![genesis](https://avatars.discourse-cdn.com/v4/letter/g/96bed5/32.png) [@genesis](https://discuss.elastic.co/u/genesis)\
**Post date:** [February 18, 2016, 4:53pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/2 "2016-02-18T16:53:10Z")

</div>

Please help  
Thank you

---

<div class="post-metadata">

**Author:** ![msimos](https://avatars.discourse-cdn.com/v4/letter/m/bb73d2/32.png) [@msimos](https://discuss.elastic.co/u/msimos)\
**Post date:** [February 18, 2016, 5:53pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/3 "2016-02-18T17:53:44Z")

</div>

Hi,

I'm not sure why this is occurring but you may want to take a look at this github issue which has a similar error:

> <https://github.com/elastic/elasticsearch-cloud-aws/issues/220>

You may want to check and see if prior snapshots of these indices exist in S3.

---

<div class="post-metadata">

**Author:** ![genesis](https://avatars.discourse-cdn.com/v4/letter/g/96bed5/32.png) [@genesis](https://discuss.elastic.co/u/genesis)\
**Post date:** [February 18, 2016, 6:01pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/4 "2016-02-18T18:01:01Z")

</div>

I do daily snapshot to S3 using the date format to make them unique  
The backup has been running fine for the last 3 months it started failing for the past 2 weeks

tag=$(date '+%Y\_%m\_%d')  
index="kibana"  
curl -XPUT "localhost:9200/_snapshot/s3\_repository/snapshot_${index}\_${tag}?wait\_for\_completion=true" -d '{  
"indices": ".marvel-kibana,kibana-int,.kibana",  
"include\_global\_state": false }'

---

<div class="post-metadata">

**Author:** ![Jeferson\_Martins](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jeferson_martins/32/5849_2.png) [@Jeferson\_Martins](https://discuss.elastic.co/u/Jeferson_Martins)\
**Post date:** [February 18, 2016, 9:24pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/5 "2016-02-18T21:24:27Z")

</div>

Do you use AWS?

In my case, In the past I used a low aws instance with low network and cpu. My snapshots become corrupted every day (I have index by day).

When I found this problem, I choose a bether instance and today I dont have failed snapshots.

if you use aws, see the monitoring graphs in your EC2 instance.

---

<div class="post-metadata">

**Author:** ![genesis](https://avatars.discourse-cdn.com/v4/letter/g/96bed5/32.png) [@genesis](https://discuss.elastic.co/u/genesis)\
**Post date:** [February 18, 2016, 9:37pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/6 "2016-02-18T21:37:10Z")

</div>

> [@Jeferson\_Martins](#):
>
> [GitHub - elastic/elasticsearch-cloud-aws: AWS Cloud Plugin for Elasticsearch](http://github.com/elastic/elasticsearch-cloud-aws)

I think I may have find the problem (will be able to tell for sure in couple of days). We have lots of indices and my script backup them up at the end of the day after they have rollover. These 3 indices that are failing are the only indices that do not rollover, documents get added to them day by day. I have a policy on my S3 backup to move indices from S3 to IA (Infrequent Access) and to Glacier after 60 days.  
It seems like those indices were moved to Glacier.  
I am in the process of restoring them to S3 and run the snapshot again.  
Will keep you posted.  
Thanks

---

<div class="post-metadata">

**Author:** ![Jeferson\_Martins](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jeferson_martins/32/5849_2.png) [@Jeferson\_Martins](https://discuss.elastic.co/u/Jeferson_Martins)\
**Post date:** [February 18, 2016, 9:41pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/7 "2016-02-18T21:41:20Z")

</div>

hmm, I had this problem.

the snapshot plugin not works with aws glacier. 🙂

if you want to get a glacier snapshot you will have the same problem.

---

<div class="post-metadata">

**Author:** ![babeesh](https://avatars.discourse-cdn.com/v4/letter/b/e47c2d/32.png) [@babeesh](https://discuss.elastic.co/u/babeesh)\
**Post date:** [March 10, 2016, 6:59am UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/8 "2016-03-10T06:59:26Z")

</div>

Hi Genesis..

Sorry to post question in your thread.  
I have a doubt about this topic. If we create snapshots of elasticsearch cluster or node and store it in aws s3, how we can view the logs in kibana?

I mean for viewing logs in kibana, do we need to restore the snapshots back to elasticsearch.

I setup logserver in AWS EC2 and created a S3 bucket. Next I need to bind S3 with Elasticsearch ,but no idea of where to start.

Hope you will reply.

Thanks

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 10, 2016, 7:27am UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/9 "2016-03-10T07:27:14Z")

</div>

Kibana reads what is indexed into elasticsearch.  
So yes, you have to restore your data in elasticsearch if you want to be able to consume them into Kibana.

---

<div class="post-metadata">

**Author:** ![babeesh](https://avatars.discourse-cdn.com/v4/letter/b/e47c2d/32.png) [@babeesh](https://discuss.elastic.co/u/babeesh)\
**Post date:** [March 10, 2016, 7:38am UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/10 "2016-03-10T07:38:04Z")

</div>

Okay. so these snapshots are using for backup only, right?

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 10, 2016, 8:00am UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/11 "2016-03-10T08:00:31Z")

</div>

exactly.

---

<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:** [July 5, 2017, 11:09pm UTC](https://discuss.elastic.co/t/snapshot-aws-s3-bucket/42082/12 "2017-07-05T23:09:39Z")

</div>


