# Xtrabackup --decompress folder

**URL:** <https://forums.percona.com/t/xtrabackup-decompress-folder/26053>\
**Category:** Percona XtraBackup\
**Created:** [October 20, 2023, 1:45am UTC](https://forums.percona.com/t/xtrabackup-decompress-folder/26053 "2023-10-20T01:45:24Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![pmmChobo](https://avatars.discourse-cdn.com/v4/letter/p/5f8ce5/32.png) [@pmmChobo](https://forums.percona.com/u/pmmChobo)\
**Post date:** [October 20, 2023, 1:45am UTC](https://forums.percona.com/t/xtrabackup-decompress-folder/26053/1 "2023-10-20T01:45:24Z")

</div>

The decompressed file is stored in the target-dir when the command below is executed.

```auto
xtrabackup --decompress --target-dir=[target-dir]

```

Isn’t there a way to specify the storage location directly, instead of saving the decompressed file to target-dir?

---

<div class="post-metadata">

**Author:** ![lalit.choudhary](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/lalit.choudhary/32/51_2.png) [@lalit.choudhary](https://forums.percona.com/u/lalit.choudhary)\
**Post date:** [October 20, 2023, 5:59am UTC](https://forums.percona.com/t/xtrabackup-decompress-folder/26053/2 "2023-10-20T05:59:42Z")

</div>

Hello @pmmChobo

It is expected to work that way by keeping all backup files in `--target-dir` only even after decompressing them and the same will be used for prepare.

Any particular reason for looking to store decompressed files in another directory and not in --traget-dir?

---

<div class="post-metadata">

**Author:** ![Marcelo\_Altmann](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/marcelo_altmann/32/11299_2.png) [@Marcelo\_Altmann](https://forums.percona.com/u/Marcelo_Altmann)\
**Post date:** [October 23, 2023, 9:46am UTC](https://forums.percona.com/t/xtrabackup-decompress-folder/26053/3 "2023-10-23T09:46:27Z")

</div>

Hi @pmmChobo .

If your concern is disk space, you can use `--decompress` with `--remove-original`, This way after each files is decompressed, its corresponding compressed file will be removed.

---

<div class="post-metadata">

**Author:** ![pmmChobo](https://avatars.discourse-cdn.com/v4/letter/p/5f8ce5/32.png) [@pmmChobo](https://forums.percona.com/u/pmmChobo)\
**Post date:** [October 23, 2023, 11:47pm UTC](https://forums.percona.com/t/xtrabackup-decompress-folder/26053/4 "2023-10-23T23:47:42Z")

</div>

thank you, that`s what i want
