- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-04-2018 11:54 PM
How the "Is Virtual" field gets populated using discovery?Is it different for different classes, checked in the business rules "Virtual Computer Check" but still not able to identify from where it gets checked.
Solved! Go to Solution.
- Labels:
-
Discovery
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-31-2018 06:25 AM
Hi,
There is an OOB Business Rule 'Virtual Computer Check', which sets the 'Is Virtual' field. It only handles Solaris, VMware and Hyper V servers. In order for it to handle other Virtual servers types, like AIX and HP UX servers, users may need to create a new business rule with a similar format or modify the existing business rule based on their requirement.
The above is the reply from th Service now HI team.
Thanks for the help
Regards,
Devyani
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-05-2018 03:03 AM
Hi,
In the Virtual Computer Check Business Rule around line 30 (in Kingston) where there is:
current.virtual = true
Before this, the code checks it is one one the virtualisation types that discovery recognises and returns out of the function if it doesn’t. If it does recognise it then it will set the value above.
Note that some patterns now set this as well so the Business Rule is not the only place. As an example the Windows OS - servers pattern in Kingston sets the virtual flag if it finds a virtual server is hosted on Azure or EC2:
Regards,
Dave
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2018 04:57 AM
Hi David,
Thanks for the reply.
i am still not sure how to identify for the CI's what is missing as before setting as virtual true it is checking the below parameters
function startVirtualComputerCheck() {
// Putting the easier ones to identify at the front so we don't spend extra effort looking up the others
if (isSolarisZone())
handleSolariZone();
else if (isVMWare()) {
// only process rec if just inserted or serial_number changed AND serial_number is non-nil
if (!(current.serial_number.changes() && JSUtil.notNil(current.serial_number)))
return;
handleVMWare();
} else if (isHyperV())
handleHyperV();
else
return;
Regards,
Devyani Laxmi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-07-2018 05:14 AM
Hi Devyani,
If you look further down in the Business Rule, you can see some examples of what it is checking, for example, to determine if it is a VMware virtual machine, it checks the serial number to see if it starts with 'vmware':
function isVMWare(){
if (!fVMGr.serial_number.hasValue())
return false;
if (!fVMGr.serial_number.toLowerCase().startsWith("vmware-"))
return false;
return true;
Are you finding some devices not being set as virtual? If so, do you have an example?
Regards,
Dave
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-04-2018 03:55 AM
Hi david,
I have a server "RTPLWBPVCMS07" of class as linux server.
this is not identifying as virtual
Thanks,
Devyani Laxmi