Got this interesting error today when trying to install a new Gateway server. It really puzzled me. Since this server wasn’t present at all in SCOM. It was a brand new server provisioned in a VMware environment. No Agent present on that server nor was it Agentless monitored. And yet when I ran the Gateway Approval Tool I got an error stating: ‘The gateway name already exists as a computer instance’.
Hmm. Wait! The VMware environment itself is being monitored by the nWorks Veaam MP which is older then version 5.7 (it has to updated soon). And the versions older then 5.7 of that MP have a small issue to reckon with: whenever a VM is detected it’s piped into SCOM and a relationship with a Windows Computer Object is created. Whether or not a SCOM R2 Agent is in place or not. Since this VM didn’t run a SCOM R2 Agent but was picked up by the nWorks Veeam MP it turned up into SCOM R2 as an unmonitored Windows Computer Object. And very hard to remove.
The PS cmdlet Remove-DisabledMonitoringObject didn’t work here so it was time for more drastic measures.
Be aware though it may wreck your SCOM database, so make a valid back up of it before you go ahead. Also good to know is that I am not responsible when your DB dies. (Anyhow, I have used this trick some times already and until now with no DB corruption…).
Preparations are key here since when the unmonitored Windows Computer is removed out of SCOM, the Gateway Server must be installed ASAP. Otherwise the computer will be back and might wreck the installation of the Gateway Server again. So in order to stay away from that scenario, prepare the installation of the Gateway Server in such a manner you can move fast.
- Create the required certificates (for the Gateway Server and the Management Servers) and install them;
- Copy the required installation files to the Gateway Server and don’t forget the MOMCertImport.exe tool AND CU#5;
- Create the required syntax for the SCOM R2 Gateway Server Approval Tool and keep it at hand;
- I found the required query on this blog posting (thanks Maarten Goet for sharing). Read this posting twice so you know what you’re doing;
- Open SQL Server Management Studio and make a backup of the SCOM R2 database.
The Real Deal (and now you’ve got to move FAST!!!)
- When the backup is OK run the query as stated on Maarten’s blog;
- Check the SCOM R2 Console for the unmonitored Windows Computer which must become the Gateway Server. You’ll see it’s gone now;
- Run the Gateway Server Approval Tool. It will succeed now;
- Install the Gateway Server right after it;
- Run the MOMCertImport.exe tool in order to map the correct certificate to the SCOM R2 Gateway instance;
- Now in SCOM R2 the SCOM R2 Gateway Server is accepted;
- Wait until the Gateway Server shows up healthy in the SCOM R2 Console;
- Install CU#5 and be HAPPY!