> ## Documentation Index
> Fetch the complete documentation index at: https://help.dsalta.com/llms.txt
> Use this file to discover all available pages before exploring further.

# GCP VPC Subnet flow logs should be captured

> VPC flow logs should be enabled for subnets.

## What this check does

Checks flow log config on subnets.

| | |
| - | - |
| **Severity** | Medium |
| **Category** | `network` |
| **Data used** | Subnet config |
| **Permissions required** | `compute.subnetworks.get`, `compute.regionOperations.get` |

**Passes when:** Flow logs enabled.

## Why this matters

Flow logs support audit and forensics.

## How to fix

**Enable VPC Flow Logs on every subnet**

1. Sign in to the [Google Cloud Console](https://console.cloud.google.com/) and navigate to **VPC network → VPC networks**.
2. Click the network, open the **Subnets** tab, and click the subnet the test flagged.
3. Click **Edit**, then set **Flow logs** to **On**.
4. Expand **Configure logs** and set **Aggregation interval** to **5 sec**, **Sample rate** to at least **50%**, and **Metadata** to **Include all metadata**.
5. Click **Save**, then repeat for every subnet in every region — flow logs are configured per subnet, not per network.

Or from the command line:

```bash theme={null}
gcloud compute networks subnets update SUBNET_NAME \
  --region=REGION \
  --enable-flow-logs \
  --logging-aggregation-interval=interval-5-sec \
  --logging-flow-sampling=0.5 \
  --logging-metadata=include-all
```

Once resolved, DSALTA records a **200** (compliant) result on this test's **Source Data** tab at the next scheduled run.

## Frequently asked questions

<AccordionGroup>
  <Accordion title="How often does this check run?">
    Once a day, at 02:00 America/New\_York, while the integration is connected. A run is skipped entirely if the integration is not in a **connected** state, or if the test has been deactivated.

    To see a fix reflected sooner, open the test from **Compliance → Tests** and click **Run** in the **Run Test** row. You need Full Access to run a test on demand.
  </Accordion>

  <Accordion title="What does the status actually tell me?">
    The **Status** column answers "did the check run?", not "did I pass". **Completed** means DSALTA reached your system and finished evaluating — a check that ran and *found a problem* is still Completed.

    To see what it found, open the test and read the result code on the **Source Data** tab. **200** means nothing to fix; **204** means the check did not apply to your environment; **207** means it ran and found a compliance gap you need to act on. See [Understanding test results](/guides/compliance/test-results).
  </Accordion>

  <Accordion title="The check shows Failed. Does that mean I am non-compliant?">
    Usually not. On an integration-powered check, **Failed** means DSALTA was *blocked* and could not evaluate it — result code **403** (a missing permission) or **428** (a setting DSALTA still needs from you). Code **500** means the run failed on DSALTA's side.

    A genuine compliance gap does not turn the list red — it runs to completion and shows **207**.
  </Accordion>

  <Accordion title="What if this check does not apply to us?">
    Deactivate it: open the test from **Compliance → Tests**, then use the **⋮** menu at the top right of the panel and choose **Deactivate Test**. It applies immediately, with no confirmation step.

    Write your justification in the **Comments** tab **before** you deactivate. Once deactivated, every other tab is grayed out, so Comments is the only place an auditor can read why — see [Test detail](/guides/compliance/test-detail).
  </Accordion>

  <Accordion title="Does DSALTA change my configuration?">
    No. DSALTA only reads. It never creates, modifies, or deletes resources, and every remediation step is performed by your team directly in the third-party product.
  </Accordion>
</AccordionGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.