Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Error when adding IP address to interface #139

Closed
tiagosil-cisco opened this issue Nov 1, 2023 · 3 comments
Closed

Error when adding IP address to interface #139

tiagosil-cisco opened this issue Nov 1, 2023 · 3 comments

Comments

@tiagosil-cisco
Copy link

I'm now deploying a sub-interface on FMC using the following resource but, although it's created, I get the error below. Tried changing the net mask to 24, "24", tostring(24) and tonumber(24), same error.

`resource "fmc_device_subinterfaces" "side_xe" {
depends_on = [fmc_security_zone.security_zones]
count = local.json_input.sessions
name = "${local.json_input.interface_type_ftd}${local.json_input.interface_id_ftd_xe}"
device_id = data.fmc_devices.device.id
subinterface_id = "${count.index + local.json_input.index_start}"
vlan_id = "${count.index + local.json_input.index_start}"
security_zone_id = fmc_security_zone.security_zones[count.index].id
ifname = "${local.json_input.VRF_PREFIX}${count.index + local.json_input.index_start}-INSIDE"
mtu = 1500
enabled = true
mode = "NONE"
ipv4_static_address = cidrhost(cidrsubnet(local.json_input.supernet_iosxe_fw, 8, count.index + local.json_input.index_start), 2)
ipv4_static_netmask = tonumber(24)

}

│ Error: unable to update physical interface

│ with module.fmc.fmc_device_subinterfaces.side_xe[1],
│ on modules/fmc/320_fmc_subinterfaces.tf line 2, in resource "fmc_device_subinterfaces" "side_xe":
│ 2: resource "fmc_device_subinterfaces" "side_xe" {

│ creating sub interfaces: https://10.0.10.36/api/fmc_config/v1/domain/e276abec-e0f2-11e3-8169-6d9ed49b625f/devices/devicerecords/a40968f2-53f9-11ee-a510-d4df6ac80d4e/subinterfaces - json: cannot unmarshal string into Go
│ struct field IPv4Static.ipv4.static.netmask of type int


│ Error: unable to update physical interface

│ with module.fmc.fmc_device_subinterfaces.side_xe[0],
│ on modules/fmc/320_fmc_subinterfaces.tf line 2, in resource "fmc_device_subinterfaces" "side_xe":
│ 2: resource "fmc_device_subinterfaces" "side_xe" {

│ creating sub interfaces: https://10.0.10.36/api/fmc_config/v1/domain/e276abec-e0f2-11e3-8169-6d9ed49b625f/devices/devicerecords/a40968f2-53f9-11ee-a510-d4df6ac80d4e/subinterfaces - json: cannot unmarshal string into Go
│ struct field IPv4Static.ipv4.static.netmask of type int `

@tiagosil-cisco
Copy link
Author

@snetlamu
Copy link
Contributor

snetlamu commented Nov 6, 2023

Hi @tiagosil-cisco , thank you for raising the issue. We've identified what's causing this behaviour and will be merging a fix soon. ETA is Nov 7 or earlier.

@snetlamu
Copy link
Contributor

snetlamu commented Nov 7, 2023

This issue has been fixed in release 1.4.6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants