---
schema_version: "1"
id: 22793c2c0fc73187eb68bc2ce9196dc9d3ecb30d1d82f7b9bcffc8f642082261
title: Resetting the Control Node Cache with the CLI
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/gateway/latest/troubleshoot-reset-cache.md
canonical_url: https://docs.mulesoft.com/gateway/latest/troubleshoot-reset-cache
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 18b17ef151d4be85e700dcb882b33da28021465a3bdc0104337ceaabcfad5258
description: MuleSoft Documentation Site
release: "1.14"
latest: true
---
---
product: Omni Gateway
version: 1.14
is-latest-version: true
---

# Resetting the Control Node Cache with the CLI

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

If the control node cache becomes corrupted or you encounter other critical issues that affect the
integrity of the cache, use the `flexctl reset` CLI to erase the cache state.

Resetting the control node cache can’t be undone. Use `flexctl reset` only to recover from data
corruption or other critical cache issues.

The command deletes only the control node’s data from the configured shared storage. When the shared
storage is Redis, other keys in the same Redis instance, such as those used by policies, aren’t
deleted.

> [!NOTE] To run `flexctl reset` for Linux deployments, either add the user to the `flex` user group
> or run `flexctl reset` with the `sudo` command. To learn more, see
> [Troubleshooting Linux Permissions](https://docs.mulesoft.com/gateway/latest/troubleshoot-linux-permissions).

## Run the CLI

1.  Run the following command:

    ```ssh
    flexctl reset
    ```

    To run the command in a container without entering it, run:

    ```ssh
    docker exec -it flex-gateway flexctl reset
    ```

2.  When prompted to confirm, type `yes`. Any other input cancels the operation.

    If the reset succeeds, the CLI returns the following message:

    Storage was reset successfully. You can restart flex now!

3.  Restart Omni Gateway.

## Change the Admin API Address

By default, `flexctl reset` connects to the gateway’s Admin API through the Unix socket
`/var/tmp/mulesoft/flex-gateway/flex-agent-status-api.sock`. To use a different Admin API address,
use the `--flex-admin-api-url` flag:

```ssh
flexctl reset --flex-admin-api-url <ADMIN_API_URL>
```

## See Also

- [Troubleshooting with the CLI](https://docs.mulesoft.com/gateway/latest/troubleshoot-admin-api)

- [Known Issues](https://help.salesforce.com/s/issues)
