Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Confusing limitations on private subnets size #1807

Open
foretspaisibles opened this issue Aug 19, 2023 · 1 comment
Open

Confusing limitations on private subnets size #1807

foretspaisibles opened this issue Aug 19, 2023 · 1 comment
Assignees
Labels
documentation priority:high New features vpc Virtual Private Cloud (VPC) issues, bugs and feature requests

Comments

@foretspaisibles
Copy link

Valid IPv4 subnets have confusing and apparently undocumented limitations. The error shows up while using Terraform provider but since it is not caught by the provider itself, I believe it is actually an error in the SDK.

For instance attempting to create the following VPC, results in an error:

resource "scaleway_vpc_private_network" "main" {
  name = "private-network"
  tags = ["GitHub-issue"]

  ipv4_subnet {
    subnet = "192.168.0.0/16"
  }
}

The message is

Error: scaleway-sdk-go: invalid argument(s): subnets[0] is invalid for unexpected reason, prefix: {"max": 20, "min": 29}

It is helpful because it explains how to solve the issue, yet in a not so straightforward way. It is confusing because there is no reference to this in Terraform provider documentation nor in SDK documentation. Another source of confusion is that the reserved IP addresses listed by IETF mentions 192.168.0.0/16.

As a Scaleway user I would love to see:

  1. A mention about these limitations in documentation (provider, sdk)
  2. A straightforward message explaining how to resolve the issue, which uses words and concepts based on user intent (CIDR, IPs, mask length) rather than relating to deserialisation artefacts from the CIDR notation.
  3. A link to said documentation in the error message.

Using terraform provider 2.26.0

@remyleone remyleone added vpc Virtual Private Cloud (VPC) issues, bugs and feature requests bug Something isn't working priority:high New features labels Oct 23, 2023
@yfodil yfodil added documentation and removed bug Something isn't working labels Oct 27, 2023
@0xd3e
Copy link

0xd3e commented Mar 4, 2025

The note here also indicates that it should work.

...

  • We advise you to configure your Private Network using IPs from the following private IP ranges:
    • 192.168.0.0 - 192.168.255.255 (65,536 IP addresses) and
    • 172.16.0.0 - 172.31.255.255 (1,048,576 IP addresses).

...

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
documentation priority:high New features vpc Virtual Private Cloud (VPC) issues, bugs and feature requests
Projects
None yet
Development

No branches or pull requests

5 participants