# Exclude symbol "-" does not work to filter out indices

**URL:** <https://discuss.elastic.co/t/exclude-symbol-does-not-work-to-filter-out-indices/377787>\
**Category:** Elasticsearch\
**Tags:** slm-snapshot-lifecycle-management\
**Created:** [May 5, 2025, 2:01am UTC](https://discuss.elastic.co/t/exclude-symbol-does-not-work-to-filter-out-indices/377787 "2025-05-05T02:01:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ChatLee](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/chatlee/32/125019_2.png) [@ChatLee](https://discuss.elastic.co/u/ChatLee)\
**Post date:** [May 5, 2025, 2:01am UTC](https://discuss.elastic.co/t/exclude-symbol-does-not-work-to-filter-out-indices/377787/1 "2025-05-05T02:01:19Z")

</div>

Hi teams,

I want to setup some snapshot settings, and I want to only back up indices those name start with non-dot, I tried with pattern " **-.\***" and " **\*, -.\***", but found these patterns does not work.  
I tried to setup the snapshot with both kibana-\> Stack Management -\> Snapshot and Restore and command like this: **PUT /\_slm/policy/my-snapshot-policy** , both two ways does not work.

I also tried with this command: " **GET /\_cat/indices/-.\*?v**", then I found that the result is empty.

I found there is a issue ticket here: [snapshot with exclude expression `-` does not work if you specify explicit index name · Issue #83435 · elastic/elasticsearch · GitHub](https://github.com/elastic/elasticsearch/issues/83435) , which is similar with my issue, any suggestions to fix this issue?

**My ES version is v8.11.1**

thanks
