> For the complete documentation index, see [llms.txt](https://docs.fusion.vectra.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.fusion.vectra.ai/cloud-onboarding/aws-cloud-onboarding/quickstart-aws/enable-vpc-flow-logs-1.md).

# Enable VPC flow logs

Navigate to VPC in the AWS console Under Resources by Region Select VPCs The next step will use the CloudShell, where you'll copy and paste a CLI command to more efficiently and accurately enable work

1. Navigate to VPC in the AWS console

![](https://1075194167-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7upncbzIm3grJePXaOO9%2Fuploads%2Fgit-blob-fab366034938bc3a22897d3e3ff3fb62f48b0185%2F7f856727e969ea6a69954aeaaaea2033c10278535f3699340712ba0ea4c4a9b2.png?alt=media)

2. Under **Resources by Region** Select **VPCs**

![](https://1075194167-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7upncbzIm3grJePXaOO9%2Fuploads%2Fgit-blob-27baa1fc5ba2ffab6e61229af9c488440044b380%2F7c8c88378ae6948c34a19cbc6035235ec75cc1632ab1a3e197a6988e29794f3d.png?alt=media)

3. The next step will use the CloudShell, where you'll copy and paste a CLI command to more efficiently and accurately enable working flow log configuration for your VPC.

Flow logs will be enabled with the following settings preconfigured:

* Traffic type: ALL
* Resource ID:
* Log destination type: S3
* Max aggregation interval: 1 minute

4. Open Cloudshell\
   You'll see a command prompt open up on the lower half of the screen

![](https://1075194167-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7upncbzIm3grJePXaOO9%2Fuploads%2Fgit-blob-b39e7d42fb12639e0bc486343985e8f532209bc3%2Fd1fa899c0b72f84538270e4a9f09817478ac0f5b7b86d8e0dcb3cfd0b16df58f.png?alt=media)

5. Copy and paste the command below, replace `<VPC ID>` with the VPC ID you want to enable flow logs for, and replace `<bucket name>` with the name of your S3 bucket created in a previous step.

{% tabs %}
{% tab title="CLI" %}

```shell
aws ec2 create-flow-logs \
  --resource-type VPC   \
  --resource-ids <VPC ID> \
  --traffic-type ALL   \
  --log-destination-type s3 \
  --log-destination arn:aws:s3:::<bucket name> \
  --log-format '${version} ${account-id} ${interface-id} ${srcaddr} ${dstaddr} ${srcport} ${dstport} ${protocol} ${packets} ${bytes} ${start} ${end} ${action} ${log-status} ${tcp-flags} ${type} ${pkt-dstaddr} ${pkt-srcaddr} ${instance-id} ${vpc-id} ${az-id} ${sublocation-id} ${sublocation-type} ${subnet-id}' \
  --max-aggregation-interval 1
```

{% endtab %}
{% endtabs %}

![](https://1075194167-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7upncbzIm3grJePXaOO9%2Fuploads%2Fgit-blob-562645244d22f22d7e5d2284e6fb9d5b4b49e66b%2F53710cbb94a8c67fc732016919e59d504b9c5e2c81682af9004c55fcd5831034.png?alt=media)

{% hint style="warning" %}
**🚧If the log format isn't specified exactly as it is in the above command, your integration will fail.**
{% endhint %}

6. Once you've pasted in the command, it should look like this:

![](https://1075194167-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7upncbzIm3grJePXaOO9%2Fuploads%2Fgit-blob-e38cc6a493b3ac3bb26cf4290a272faf08114603%2F72c9b43b73593603ebb0211f429a129abf99036ae4356ae673bdf13ed0e7e9df.png?alt=media)

7. Hit the enter key to run the command.

If you see the below, your flow logs have been successfully created.\
`"Unsuccessful":[]` means you were successful and no errors were indicated.

![](https://1075194167-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F7upncbzIm3grJePXaOO9%2Fuploads%2Fgit-blob-cfd06a3a0be083ba53fc0c1161990a724db0ac25%2F7449997d4a7cd4a99dcac8cc0c8283eff3a2ab0085116051e33a1214e487582d.png?alt=media)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.fusion.vectra.ai/cloud-onboarding/aws-cloud-onboarding/quickstart-aws/enable-vpc-flow-logs-1.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
