Hello tsethuraman
You will need to make this changes for policy in oneClick for the following
variables...
Naming - Choose Name Service ( Default ) no Use DNS, a custom value from a file, or sysName when naming elements. Values are "DNS", "sysName", "file_name", or "No". When you set this value to DNS or sysname, you can specify a regular expression in NH_NAME_SRVC_PAT to truncate part of an element name exceeds the max name length.
EXAMPLE:
NH_NAME_SRVC_PAT = "(\.corp\.bca\.com\.br)|(\.corp\.bca\.com\.br)"
(\.lam\.priv\.rhodia\.comBR1234)
Naming - Truncate by Regular Expression ( Default ) Specify a regular expression to determine the part of the element name to truncate when maximum name length is exceeded. Requires NH_USE_NAME_SRVC value to be set to "DNS" or "sysName".
NH_USE_NAME_SRVC = sysName
Then you should be able to rerun the discovery again and above variables
take effect.
Naming - Use Alternate Alias Scheme ( Default ) Assign alias names using the specified TCL script.
Naming - Use Alternate Name Scheme ( Default ) Assign element names using the specified TCL script.
OR
name matches ".*\.alias\.5sigcmd.*":
{
setName("$1$2");
}
May need to rename existing elements, not sure if rediscovery with rule
will change name.
Please test. If that works they just need to use the rule and rediscover.
If not, they need to use nhModifyElements:
nhListElements -where "name matches *.alias.5sigcmd*" -outFile list.txt
Check list.txt to ensure it contains the correct list.
Should be a single column list of all elements with .alias.5sigcmd in the
name.
Run:
sed 's/\(.*\)\.alias\.5sigcmd\(.*\)/\0,\1\2/g' list.txt > rename.txt
(Google "sed backreferences" or ask if you need an explanation of how that
works)
Check rename.txt to ensure it contains a list of:
<element with .alias.5sigcmd in the name>,<element without .alias.5sigcmd
in the name>
<element with .alias.5sigcmd in the name>,<element without .alias.5sigcmd
in the name>
MAKE SURE THE LIST LOOKS CORRECT BEFORE RUNNING nhModifyElements.
Rename the elements:
nhModifyElements -inFile rename.txt -fieldName name
Check to see if the elements were renamed.
They probably want to split this into a few batches.
Regards,