Skip to content

Commit

Permalink
new-post: introducing the prune command in REANA client
Browse files Browse the repository at this point in the history
  • Loading branch information
giuseppe-steduto committed Jul 11, 2023
1 parent 560d0dc commit 87c92a6
Showing 1 changed file with 50 additions and 0 deletions.
50 changes: 50 additions & 0 deletions content/posts/2023/reana-client-prune-command.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
title: "Free up disk space in REANA workspaces with the new prune command"
date: 2023-04-24T07:00:00+01:00
---

Starting from REANA 0.9.1, managing disk space in REANA workspaces will become even easier! The new `prune` command in
`reana-client` identifies and removes temporary files, freeing up your storage while preserving the
reproducibility of your workflows.

<!--more-->

The management of disk space in REANA can be a challenge.
You might have used the `rm` command to manually
delete unnecessary files, for example by running `reana-client rm -w myanalysis.42 tmp/mytmpdata.csv`.
Although it worked, it was time-consuming and required extra care not to delete essential input or output files.

The new `prune` command in `reana-client` is a more convenient and safer way to free up disk space
in your REANA workspaces.
It is designed to manage workspace files intelligently, automatically identifying and deleting
temporary files that are neither inputs nor outputs, freeing up your storage significantly and effortlessly.
Here's how you can use it:

```console
$ reana-client prune -w my-analysis.42
==> SUCCESS: The workspace has been correctly pruned.
```

This will delete all temporary files in the workspace of the workflow `my-analysis.42`.
If you need to free up even more space, you can also delete input or output files
by using the `--include-inputs` or `--include-outputs` flags, respectively.

However, a word of caution: it's important to remember that running the `prune` command will permanently delete the files
from your workspace. This means that you should make sure you have backed up any files you want to keep
before running the command. Additionally, be careful when using the `--include-inputs` or
`--include-outputs` flags, as deleting inputs will make it impossible to run your workflow
again and by deleting output files you will lose the results of your workflow run.

By the way, did you know you can keep your workspaces clean automatically? REANA features the possibility
to configure one or more *workspace file retention rules* for your workflows that will automatically
and periodically delete the specified files after a certain amount of time.
You can read more about this feature in the [related blog post](https://blog.reana.io/posts/2022/workspace-file-retention-rules/).

We hope you find this new feature useful for managing your REANA workspaces and freeing up
valuable disk space. As always, if you have any feedback or suggestions for how we can improve
REANA, please let us know!

## See also

- [REANA Client](https://reana-client.readthedocs.io/en/latest/) documentation page
- [Workspace retention rules](https://blog.reana.io/posts/2022/workspace-file-retention-rules/) blog post

0 comments on commit 87c92a6

Please sign in to comment.