> ## Documentation Index
> Fetch the complete documentation index at: https://private-7c7dfe99-fix-nav-issues.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Execute SYSTEM statements on all nodes in ClickHouse Cloud

> Learn how to use `ON CLUSTER` and `clusterAllReplicas` to execute SYSTEM statements and queries across all nodes in a ClickHouse Cloud service.

{frontMatter.description}

<h2 id="answer">
  Answer
</h2>

In order to execute the same query on all nodes of a ClickHouse Cloud service, we can use [clusterAllReplicas](/reference/functions/table-functions/cluster).

For example, in order to get entries from a (node-local) system table from all nodes, you can use:

```sql theme={null}
SELECT ... FROM clusterAllReplicas(default, system.TABLE) ...;
```

Similarly, you can execute the same [SYSTEM statement](/reference/statements/system) on all nodes with a single statement, by using the [ON CLUSTER](/reference/statements/distributed-ddl) clause:

```sql theme={null}
SYSTEM ... ON CLUSTER default;
```

For example for [dropping the filesystem cache](/reference/statements/system#drop-filesystem-cache) from all nodes, you can use:

```sql theme={null}
SYSTEM DROP FILESYSTEM CACHE ON CLUSTER default;
```
