# Snapshot policy will continue to backup fail when the backup jumps out of shard error

**URL:** <https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738>\
**Category:** Kibana\
**Tags:** snapshot-and-restore\
**Created:** [July 6, 2023, 3:45am UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738 "2023-07-06T03:45:22Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Lily1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lily1/32/123109_2.png) [@Lily1](https://discuss.elastic.co/u/Lily1)\
**Post date:** [July 6, 2023, 3:45am UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738/1 "2023-07-06T03:45:22Z")

</div>

Version: Elasticsearch 7.16.2  
S3 Storage Classes: new file saving S3 Standard, after month turn to S3 Glacier

Regularly back up the index of the same Aliases to s3 every day.  
Recently, the following error suddenly popped up. May I ask if the error is because my s3 has been set to transfer to the glacier storage method for one month?

Snapshot Failed indices:  
 ![image](https://us1.discourse-cdn.com/elastic/original/3X/c/6/c659b869dd5cb39d08a21bb41529a1453e45cbcf.png)

```auto
INTERNAL_SERVER_ERROR: AmazonS3Exception[The operation is not valid for the object's storage class (Service: Amazon S3; Status Code: 403; Error Code: InvalidObjectState; Request ID: 9T81R0DTBFXKRXHK; S3 Extended Request ID: Yhrwi1M188qhZRToZBwCYuBSY+GB4SuCERlErbrWKtGRGacqIFysdioYf83Aq8I0lnQSeKJbiz4=)]

```

Policy History:

```auto

{
  "type": "snapshot_exception",
  "reason": "[XXXX:XXXX-2023.07.06-6ohv3ltdtpmmf2gimegkxa] failed to create snapshot successfully, 28 out of 28 total shards failed",
  "stack_trace": "SnapshotException[[XXXX:XXXX-2023.07.06-6ohv3ltdtpmmf2gimegkxa] failed to create snapshot successfully, 28 out of 28 total shards failed]\n\tat org.elasticsearch.xpack.slm.SnapshotLifecycleTask$1.onResponse(SnapshotLifecycleTask.java:135)\n\tat org.elasticsearch.xpack.slm.SnapshotLifecycleTask$1.onResponse(SnapshotLifecycleTask.java:109)\n\tat org.elasticsearch.action.support.ContextPreservingActionListener.onResponse(ContextPreservingActionListener.java:31)\n\tat org.elasticsearch.action.support.TransportAction$1.onResponse(TransportAction.java:88)\n\tat org.elasticsearch.action.support.TransportAction$1.onResponse(TransportAction.java:82)\n\tat org.elasticsearch.action.support.ContextPreservingActionListener.onResponse(ContextPreservingActionListener.java:31)\n\tat org.elasticsearch.xpack.security.action.filter.SecurityActionFilter.lambda$applyInternal$2(SecurityActionFilter.java:192)\n\tat org.elasticsearch.action.ActionListener$DelegatingFailureActionListener.onResponse(ActionListener.java:219)\n\tat org.elasticsearch.action.ActionListener$DelegatingActionListener.onResponse(ActionListener.java:186)\n\tat org.elasticsearch.action.ActionListener$MappedActionListener.onResponse(ActionListener.java:101)\n\tat org.elasticsearch.action.ActionListener.onResponse(ActionListener.java:293)\n\tat org.elasticsearch.snapshots.SnapshotsService.completeListenersIgnoringException(SnapshotsService.java:3413)\n\tat org.elasticsearch.snapshots.SnapshotsService.lambda$finalizeSnapshotEntry$31(SnapshotsService.java:2052)\n\tat org.elasticsearch.action.ActionListener$1.onResponse(ActionListener.java:136)...

```

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [July 6, 2023, 4:01am UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738/2 "2023-07-06T04:01:14Z")

</div>

> [@Lily1](#):
>
> May I ask if the error is because my s3 has been set to transfer to the glacier storage method for one month?

I would say that this is probably the issue, this is in the [documentation](https://www.elastic.co/guide/en/elasticsearch/reference/current/repository-s3.html) on the part about the `storage_class`.

> You may use an S3 Lifecycle Policy to adjust the storage class of existing objects in your repository, but you **must not transition objects to Glacier classes** and you must not expire objects. If you use Glacier storage classes or object expiry then you may permanently lose access to your repository contents.

---

<div class="post-metadata">

**Author:** ![Lily1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lily1/32/123109_2.png) [@Lily1](https://discuss.elastic.co/u/Lily1)\
**Post date:** [July 6, 2023, 7:07am UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738/3 "2023-07-06T07:07:06Z")

</div>

Thank you for your reply.

Because I have had no problems with backups for several months, suddenly this error started to appear in recent backups. Is it because I have set storage for one month to convert to Glacier classes?

Thanks!

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [July 6, 2023, 12:13pm UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738/4 "2023-07-06T12:13:43Z")

</div>

> [@Lily1](#):
>
> Is it because I have set storage for one month to convert to Glacier classes?

This was already answered in the previous answer, you must not transition objects to Glacier classes and you may lose access to them if you do.

Not sure if you can recover it as the documentation says that you should not do it and warns about losing access.

---

<div class="post-metadata">

**Author:** ![Lily1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lily1/32/123109_2.png) [@Lily1](https://discuss.elastic.co/u/Lily1)\
**Post date:** [July 7, 2023, 1:30am UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738/5 "2023-07-07T01:30:41Z")

</div>

Ok, thank you for your reply.

---

<div class="post-metadata">

**Author:** ![Lily1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lily1/32/123109_2.png) [@Lily1](https://discuss.elastic.co/u/Lily1)\
**Post date:** [July 25, 2023, 10:03am UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738/6 "2023-07-25T10:03:52Z")

</div>

We are planning to use S3 Intelligent-Tiering for storage. If the backup file transition to Deep Archive Access, can it be retrieved and used normally?

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [July 25, 2023, 12:16pm UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738/7 "2023-07-25T12:16:26Z")

</div>

> [@Lily1](#):
>
> We are planning to use S3 Intelligent-Tiering for storage. If the backup file transition to Deep Archive Access, can it be retrieved and used normally?

I'm not sure, I do not use S3 for snapshots, you have to wait for someone from Elastic to answer or open an issue on Github about it because the documentation does not mention this storage class.

---

<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, 2023, 12:16pm UTC](https://discuss.elastic.co/t/snapshot-policy-will-continue-to-backup-fail-when-the-backup-jumps-out-of-shard-error/337738/8 "2023-08-22T12:16:38Z")

</div>

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