Hello @RahulRana-1085 ,
From your verbatim, I see
- VNET1 is connected to OnPrem1 via S2S
- This VNET1 has a firewall, say OldFirewall
- VNET2 is connected to OnPrem2 via ExR
- You do not use Gateway Transit and instead, Connectivity between OnPrem1 to VNET2 is provided by routing traffic to the OldFirewall
- Essentially, as you said,
- VNET2 Azure VM <--> VNET1 Azure Firewall <--> S2S connected OnPrem1
Yes, this configuration would work but note that this is not a typical Hub Spoke.
- We suggest all the Gateways be in a single VNET and this VNET should be the Hub
- Your situation is something like a multi Hub design.
Observation:
- From the logs you shared, I don't see two things happening
- OnPrem1 <---> OnPrem2 flow
- VNET1 <---> OnPrem2 flow
- I think this is expected and doubt you will be able to achieve this with static routing.
- This makes sense as from OldFirewall in VNET1, there is no way of routing to OnPrem2 (which is connected to VNET2)
- i.e., The Firewall can only learn the OnPrem routes to which it's VNET is connected.
- That's why you were able to access "S2S connected on-prem device"
Now, per your requirement, "I want to delete the oldFirewall and create a newFirewall in VNET2 so that all traffic from on-prem passes through the newFirewall first and then the infrastructure VMs, following a hub-and-spoke model"
- You will able to achieve connectivity between different VNETs that are peered to the VNET2 via the NewFirewall.
- Also, OnPrem2 (connected to VNET2), can access all the peered VNETs via Azure Firewall
- However, I don't think OnPrem to OnPrem connectivity can be achieved in this manner
You can instead consider using Azure Virtual WAN for such complex scenarios which provided "Branch connectivity" across all connected sites.
Hope this clarifies.
Cheers,
Kapil