-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
Add-AzureRmServiceFabricNodeType fails with error: The Resource 'Microsoft.Network/virtualNetworks/VNETX' under resource group 'RG01' was not found #8407
Comments
@asetiMSFT Can you try running Also, please gather additional debugging info by setting
|
Hi Mark, I will ask my customer (they are in East coast and I'm here in West coast (Redmond/Sammamish area)). They'll get back Monday and may be available over the weekend. At any rates, I'll forward the requests to them. My shift is almost over but I can monitor their email during weekend and post anything new here. I'm still working on other case at the moment. Thanks for your help! |
Hi Mark, got a reply from cx as follows (sensitive data was omitted). If I missed something, pls let me know. Thanks! PS C:\WINDOWS\system32>
$DebugPreference='Continue'
PS C:\WINDOWS\system32> Resolve-AzureRmError -Last
DEBUG: 7:15:53 AM - ResolveError begin processing with ParameterSet 'LastErrorParameterSet'.
DEBUG: 7:15:53 AM - using account id '<OMITTED>'...
HistoryId: 60
RequestId : <OMITTED>
Message : The Resource 'Microsoft.Network/virtualNetworks/VNETX' under resource group 'RG01' was not found.
ServerMessage : ResourceNotFound: The Resource 'Microsoft.Network/virtualNetworks/VNETX' under resource group 'RG01' was not found. (System.Collections.Generic.List`1[Microsoft.Rest.Azure.CloudError])
ServerResponse : {NotFound}
RequestMessage : {GET https://management.azure.com/subscriptions/<OMITTED>/resourceGroups/RG1/providers/Microsoft.Network/virtualNetworks/VNETX/subnets/<OMITTED>-Subnet-0?api-version=2017-10-01}
InvocationInfo : {Add-AzureRmServiceFabricNodeType}
Line : Add-AzureRmServiceFabricNodeType
Position : At line:1 char:1
+ Add-AzureRmServiceFabricNodeType
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
StackTrace : at Microsoft.Azure.Management.Internal.Network.Version2017_10_01.SubnetsOperations.<GetWithHttpMessagesAsync>d__6.
MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at
Microsoft.Azure.Management.Internal.Network.Version2017_10_01.SubnetsOperationsExtensions.<GetAsync>d__3.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at
Microsoft.Azure.Management.Internal.Network.Version2017_10_01.SubnetsOperationsExtensions.Get(ISubnetsOperations
operations, String resourceGroupName, String virtualNetworkName, String subnetName, String expand)
at Microsoft.Azure.Commands.ServiceFabric.Commands.AddAzureRmServiceFabricNodeType.GetSubnetAddressPrefix(VirtualM
achineScaleSetIPConfiguration ipConfiguration)
at Microsoft.Azure.Commands.ServiceFabric.Commands.AddAzureRmServiceFabricNodeType.CreateNetworkResource(VirtualMa
chineScaleSetNetworkConfiguration existingNetworkConfig)
at Microsoft.Azure.Commands.ServiceFabric.Commands.AddAzureRmServiceFabricNodeType.GetProfiles(VirtualMachineScale
SetExtensionProfile& vmExtProfile, VirtualMachineScaleSetOSProfile& osProfile, VirtualMachineScaleSetStorageProfile&
storageProfile, VirtualMachineScaleSetNetworkProfile& networkProfile)
at Microsoft.Azure.Commands.ServiceFabric.Commands.AddAzureRmServiceFabricNodeType.CreateVmss()
at Microsoft.Azure.Commands.ServiceFabric.Commands.AddAzureRmServiceFabricNodeType.ExecuteCmdlet()
at Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet.ProcessRecord()
HistoryId : 60
DEBUG: AzureQoSEvent: CommandName - Resolve-AzureRmError; IsSuccess - True; Duration - 00:00:00.0351621; Exception - ;
DEBUG: Finish sending metric.
DEBUG: 7:15:55 AM - ResolveError end processing.
DEBUG: 7:15:55 AM - ResolveError end processing. |
I'll post the debug info for the failing command tomorrow as it's getting late here and I needed to ensure I don't post any sensitive info here. |
@asetiMSFT Were you able to get the debugging information? |
I was but my team is super swamped right now and didn't get a chance to spend time on removing sensitive info. ETA: EOD today. |
Hi Mark, I was out for few days due to snow and outage. It took me quite a while trying to ensure there's no sensitive info from the debugging information. Hopefully I didn't remove too much. Note that the names and some values are not real names but they should be consistent/doesn't change the context (hopefully). Let me know if I'm missing anything. `PS C:\WINDOWS\system32> $pwd = ConvertTo-SecureString -String 'xxxxxxxxx' -AsPlainText -Force PS C:\WINDOWS\system32> Add-AzureRmServiceFabricNodeType DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: ============================ HTTP REQUEST ============================ HTTP Method: Absolute Uri: Headers: Body: DEBUG: ============================ HTTP RESPONSE ============================ Status Code: Headers: Body: DEBUG: [Common.Authentication]: Authenticating using Account: '', environment: 'Az DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: ============================ HTTP REQUEST ============================ HTTP Method: Absolute Uri: Headers: Body: DEBUG: ============================ HTTP RESPONSE ============================ Status Code: Headers: Body: DEBUG: [Common.Authentication]: Authenticating using Account: '', environment: 'Az DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Verbose: 1 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: Microsoft.IdentityModel.Clients.ActiveDirectory Information: 2 : DEBUG: ============================ HTTP REQUEST ============================ HTTP Method: Absolute Uri: Headers: Body: DEBUG: ============================ HTTP RESPONSE ============================ Status Code: Headers: Body: Add-AzureRmServiceFabricNodeType : The Resource 'Microsoft.Network/virtualNetworks/VNETX' under resource group
DEBUG: AzureQoSEvent: CommandName - Add-AzureRmServiceFabricNodeType; IsSuccess - False; Duration - 00:00:03.2237103; Exception - Micro PS C:\WINDOWS\system32> ` |
@vaishnavk @juhacket Can you take a look at this issue? |
@asetiMSFT thanks for reporting. I'll file a bug to fix this scenario, in the cmdlet logic we are assuming all resources are under the same resource group. As you pointed out this can be mitigated via ARM template deployment, was the customer unblocked doing this? |
Hi Alfredo, thanks for the follow up. The customer said they were unblocked by doing ARM template deployment but they mentioned they preferred to do it via cmdlet previously but since they have no choice, they had to do it anyway. I'll follow up with customer again and let him know about the progress so far. Thanks for your help! Please expect delays in my responses for the next days/week since my area has been pummeled by snow storm, power outages, etc. |
Cmdlet(s)
Add-AzureRmServiceFabricNodeType
PowerShell Version
5.1.17763.134
Module Version
AzureRM 6.12.0
OS Version
10.0.17763.253
Description
When attempting to add new node type to an existing cluster that has VMSS that uses existing VNet from other resource group that's different than resource group of the cluster, the command failed with error:
Cluster is healthy and was deployed based on this doc to use existing vnet from different resource group:
https://blogs.msdn.microsoft.com/kwill/2016/10/05/azure-service-fabric-common-networking-scenarios/#ExistingVnet
Perhaps using fully qualified resource id (https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-group-template-functions-resource#resourceid ) from within the code (https://github.com/Azure/azure-powershell/blob/master/src/ServiceFabric/ServiceFabric/Commands/AddAzureRmServiceFabricNodeType.cs ) may fix this problem? Or add new parameter to allow user to specify different resource group for certain resource (in this case, it's virtual network that's in different resource group than the cluster).
Please note that I'm submitting this issue on behalf of our customer. This seems to be a supported scenario and can be mitigated via ARM template update, however until this issue is fixed, user can't use this cmdlet for this scenario.
Script/Steps for Reproduction
Have an existing cluster with all resources in resource group RG01 except for the virtual network resource is in resource group RG02 (all under the same subscription).
Than run command:
The text was updated successfully, but these errors were encountered: