Network Management

"ERROR IN DELETE CONNECTION PROFILE" while deleting connection profile in NCM

Not able to delete the connection profile, receiving ERROR IN DELETE CONNECTION PROFILE

First published date

7/14/2021 2:37 PM

Last published date

7/14/2021 2:37 PM

Overview

This article provides details on addressing errors, like the below examples, showing up while attempting to delete the connection profile.
 
image.png

image.png

Product section

Network Configuration Manager

Cause

Connection profile assigned to node(s).

Resolution

Since the connection profile is assigned to node(s) you are not allowed to delete it. If you wish to delete it you will first need to remove it from the node(s), for example by editing the node and changing the connection profile.

Currently, there is no report which will assist in listing nodes using a specific connection profile but you can use the below SQL query (i.e. Create a web-based report in the Orion Platform):
-- Scripts are not supported under any SolarWinds support program or service.
-- Scripts are provided AS IS without warranty of any kind. SolarWinds further
-- disclaims all warranties including, without limitation, any implied warranties
-- of merchantability or of fitness for a particular purpose. The risk arising
-- out of the use or performance of the scripts and documentation stays with you.
-- In no event shall SolarWinds or anyone else involved in the creation,
-- production, or delivery of the scripts be liable for any damages whatsoever
-- (including, without limitation, damages for loss of business profits, business
-- interruption, loss of business information, or other pecuniary loss) arising
-- out of the use of or inability to use the scripts or documentation.

SELECT NP.[CoreNodeID], ND.[Caption], ND.[IP_Address], CP.[Name]
FROM [NCM_NodeProperties] NP
JOIN [NodesData] ND ON ND.[NodeID]=NP.[CoreNodeID]
JOIN (SELECT [ID], [Name] FROM [NCM_ConnectionProfiles]) CP ON NP.[ConnectionProfile]=CP.[ID]
WHERE CP.[Name]='PROFILE-NAME'
NOTE:
  • replace PROFILE-NAME in WHERE clause with the name of the desired connection profile


In case the connection profile can not be changed through Orion Web Console preventing profile deletion you can use below SQL Query to reset the node to "no profile" and then delete the connection profile:
-- Scripts are not supported under any SolarWinds support program or service.
-- Scripts are provided AS IS without warranty of any kind. SolarWinds further
-- disclaims all warranties including, without limitation, any implied warranties
-- of merchantability or of fitness for a particular purpose. The risk arising
-- out of the use or performance of the scripts and documentation stays with you.
-- In no event shall SolarWinds or anyone else involved in the creation,
-- production, or delivery of the scripts be liable for any damages whatsoever
-- (including, without limitation, damages for loss of business profits, business
-- interruption, loss of business information, or other pecuniary loss) arising
-- out of the use of or inability to use the scripts or documentation.

UPDATE [NCM_NodeProperties]
SET [ConnectionProfile] = -1
WHERE [ConnectionProfile] = (SELECT TOP 1 [ID] FROM [NCM_ConnectionProfiles] WHERE [Name]='PROFILE-NAME')
NOTE:
  • replace PROFILE-NAME in WHERE clause with the name of the desired connection profile
If you happen to know the ID of the connection profile you can use a simplified query:
-- Scripts are not supported under any SolarWinds support program or service.
-- Scripts are provided AS IS without warranty of any kind. SolarWinds further
-- disclaims all warranties including, without limitation, any implied warranties
-- of merchantability or of fitness for a particular purpose. The risk arising
-- out of the use or performance of the scripts and documentation stays with you.
-- In no event shall SolarWinds or anyone else involved in the creation,
-- production, or delivery of the scripts be liable for any damages whatsoever
-- (including, without limitation, damages for loss of business profits, business
-- interruption, loss of business information, or other pecuniary loss) arising
-- out of the use of or inability to use the scripts or documentation.

UPDATE [NCM_NodeProperties]
SET [ConnectionProfile] = -1
WHERE [ConnectionProfile] = PROFILE-ID
NOTE:
  • replace PROFILE-ID in WHERE clause with the ID of the desired connection profile