Network or Telecom Equipment naming convention in servicenow

Vinay2509
Tera Contributor

Hi Team,

 

We have requirement as to handle Naming convention for Device & Hostname when we register or create in ServiceNow platform.

 

Ex : Below is the example and logic has to work for type of devices like, OLT, ABC, CBZ etc.

 

Equipment name        Hostname
OLT1.abn-001          OLT1.abn-001.de-ao.de
wdm1a.abn-001       wdm1a.abn-001.de-ao.de 

 

Do we have any way to achieve this? any OOB solution

8 REPLIES 8

ersureshbe
Giga Sage
Giga Sage

Hi, There is no OOB solution. You should write script in background or fixscript and execute. As per your example, I'm seeing .de-ao.de it should be added in end of your name. Take below is a sample example.

 

var grName = new GlideRecord('Table_name');

grName.addNotNullQuery('FieldName of the ServerName');

grName.query();

while(grName.next())

{

 var x = grName.name; // Which field you want to modify.

 grName.name = x+'.de-ao.de'; // Which field you want to modify

grName.update();

}

Regards,
Suresh.

Community Alums
Not applicable

@ersureshbe Thanks for your response!

I tried to achive naming convention for equipment type and Hostname using Script include & BR it not working.

 

When I tried to create an Equipment instance using change model or API name feild need to be generat as per rule, but here name value is automatically populating with some predefined field values, not sure where this value come from? Is there any pre config for CI name generation in ServiceNow? 

 

Please advise if any exisitng naming script or rules already present in Servicnow for Equipment naming, will follow the same. 

 

 

VinayTNI_0-1704640318521.png

 

Hi, I hope, the above values are coming from data sources using import set tables. I suggest you to check the import set table associated to your target table. It will give you the result.

Regards,
Suresh.

Community Alums
Not applicable

@ersureshbe I have checked, values not come from import set, also I tried to create change request model to create an equipment instance, while creating we need to select inventory equipment template and Network site feild on which we need to create instance.

 

Once after filling above feilds and submit, instance will get created but name will be auto populating with clli code value which is on network site.

 

I checked Configuration item table,Class manger for equipment naming, nothing is helping to solve

 

Please advise