Open ar316234 opened 4 months ago
Thanks for raising this issue. Seems I can't reproduce this issue with below tf config and latest tf azurerm provider. Could you provide reproduce steps and the simplest tf config that triggers this issue? Could you also try below tf config with latest tf azurerm provider to see if the issue still exists? Thanks.
provider "azurerm" {
features {}
}
resource "azurerm_resource_group" "test" {
name = "acctestRG-nica-test02"
location = "westeurope"
}
resource "azurerm_virtual_network" "test" {
name = "acctestvn-test02"
address_space = ["10.0.0.0/16"]
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
}
resource "azurerm_subnet" "test" {
name = "testsubnet"
resource_group_name = azurerm_resource_group.test.name
virtual_network_name = azurerm_virtual_network.test.name
address_prefixes = ["10.0.2.0/24"]
}
resource "azurerm_public_ip" "test" {
name = "test-ip-test02"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Static"
}
resource "azurerm_lb" "test" {
name = "acctestlb-test02"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
frontend_ip_configuration {
name = "primary"
public_ip_address_id = azurerm_public_ip.test.id
}
}
resource "azurerm_lb_backend_address_pool" "test" {
loadbalancer_id = azurerm_lb.test.id
name = "acctestpool"
}
resource "azurerm_network_interface" "test" {
name = "acctestni-test02"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
ip_configuration {
name = "testconfiguration1"
subnet_id = azurerm_subnet.test.id
private_ip_address_allocation = "Dynamic"
}
}
resource "azurerm_network_interface_backend_address_pool_association" "test" {
network_interface_id = azurerm_network_interface.test.id
ip_configuration_name = "testconfiguration1"
backend_address_pool_id = azurerm_lb_backend_address_pool.test.id
}
resource "azurerm_network_interface" "test2" {
name = "acctestni-test03"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
ip_configuration {
name = "testconfiguration1"
subnet_id = azurerm_subnet.test.id
private_ip_address_allocation = "Dynamic"
}
}
resource "azurerm_network_interface_backend_address_pool_association" "test2" {
network_interface_id = azurerm_network_interface.test2.id
ip_configuration_name = "testconfiguration1"
backend_address_pool_id = azurerm_lb_backend_address_pool.test.id
}
resource "azurerm_lb_backend_address_pool" "test2" {
loadbalancer_id = azurerm_lb.test.id
name = "acctestpool2"
}
resource "azurerm_network_interface" "test4" {
name = "acctestni-test04"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
ip_configuration {
name = "testconfiguration1"
subnet_id = azurerm_subnet.test.id
private_ip_address_allocation = "Dynamic"
}
}
resource "azurerm_network_interface_backend_address_pool_association" "test4" {
network_interface_id = azurerm_network_interface.test4.id
ip_configuration_name = "testconfiguration1"
backend_address_pool_id = azurerm_lb_backend_address_pool.test2.id
}
resource "azurerm_network_interface" "test5" {
name = "acctestni-test05"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
ip_configuration {
name = "testconfiguration1"
subnet_id = azurerm_subnet.test.id
private_ip_address_allocation = "Dynamic"
}
}
resource "azurerm_network_interface_backend_address_pool_association" "test5" {
network_interface_id = azurerm_network_interface.test5.id
ip_configuration_name = "testconfiguration1"
backend_address_pool_id = azurerm_lb_backend_address_pool.test2.id
}
Is there an existing issue for this?
Community Note
Terraform Version
1.8.5
AzureRM Provider Version
3.52.0
Affected Resource(s)/Data Source(s)
azurerm_network_interface_backend_address_pool_association
Terraform Configuration Files
Debug Output/Panic Output
Expected Behaviour
Actual Behaviour
Steps to Reproduce
This is a simple azure VM build task which we were doing with all the additional components like LB, ever faced this kind of error previously. and please make it noted that the for which we got this error actually got created, please check the above mentioned picture.
Important Factoids
No response
References
No response