Delete a group of devices from the blacklist via script or probe utility
search cancel

Delete a group of devices from the blacklist via script or probe utility

book

Article ID: 402844

calendar_today

Updated On:

Products

DX Unified Infrastructure Management (Nimsoft / UIM)

Issue/Introduction

We need to remove many devices that are blacklisted and would like to do it via script or using the probe utility.

Environment

UIM 23.4+

Resolution

1. Run the following query to obtain the bl_id for the list of devices that need to be unblacklisted

select * from CM_BLACKLIST_COMPUTER_SYSTEM

2. Copy the bl_ids for devices to a text file and name it bl_ids.txt

3. Create the following batch file with the pu command and the discovery_server unblacklist_devices callback.

Note: Replace <password> with your UIM's administrator password

@ECHO OFF

SET PASSWORD=<password>

FOR /F "tokens=*" %%A in (bl_ids.txt) do (
pu.exe -u administrator -p %PASSWORD% discovery_server unblacklist_devices %%A
)

4. Open the command prompt with 'Run as administrator' and run the batch file with single bl_id in the bl_ids.txt file.

5. Confirm that device is removed from the cm_black_device table with query below

Example for a single bl_id
select * from CM_BLACKLIST_DEVICE where bl_id in (1755)

Example for a multiple bl_ids
select * from CM_BLACKLIST_DEVICE where bl_id in (1755,1367)

6. Run the batch with the full list and run above queries to confirm that devices are removed

Note: you may also do them one at a time instead of using bl_id.txt by inserting the bl_id in question to the following command:

pu.exe -u administrator -p %PASSWORD% discovery_server unblacklist_devices ####

Where #### is the bl_id of the device you want to unblacklist.

You can also use the GUI Probe Utility (CTRL+P) in Infrastructure Manager to execute the same callback.

Additional Information