# Computer identity - Hostname normalization

Hostname normalization is a feature that is introduced with Snow Inventory 6.1.0.

Use of the Hostname normalization feature changes how computer hostnames are recorded. Hostname normalization truncates computer names if they contain a period; every character after and including the first period is deleted. For example: if HostName normalization is applied, the hostname for the computer Computer1.company.europe.com is transformed to Computer1.

The normalized hostname also affects identity management and can aid consolidating data from different data sources for the same computer.

This feature is not enabled by default. It can apply to the entire computer estate, or to a portion of it, defined by configurable criteria. The criteria are defined in the snowserver.config configuration file, and their parameters are detailed in the table below.

### Caution

Take care when planning to configure and enable the Hostname normalization feature. When the feature is applied, the data already processed is not affected retroactively, and only newly incoming data is normalized.

Especially when used together with the Hostname-only mode, a change in the configuration of this feature can lead to duplication of affected computer entries.

Available criteria group

Description

SiteNames

The site name of the computer, defined in the Inventory Agent configuration file.

Example 14.

<SiteName>MySite</SiteName>

ConfigNames

The name of the Inventory Agent configuration, defined in the agent configuration file.

Example 15.

<ConfigName>MyWindowsConfig</ConfigName>

HostNames

The hostname of the computer.

Example 16.

<HostName>*.domain.local</HostName>

OperatingSystems

The operating system of the computer.

Example 17.

<OperatingSystem>Windows*</OperatingSystem>

Example 18. Linux server with Snow Inventory Agent and ILMT connector

A scenario where the Hostname normalization feature can be used is when Snow Inventory collects data for a Linux server using both the Snow Inventory Agent for Linux and the IBM License Metric Tool (ILMT) connector, and the Linux server hostname is configured as FQDN.

In this case the desired outcome is to have one computer entry that combines the software data coming from the agent and the IBM Processor Value Unit data coming from the ILMT connector.

Configure the Hostname normalization feature to make sure that the entries from the different data sources are consolidated as one computer and not as different computers.

Example 19. Misconfiguration for HostNameOnly and HostnameNormalization

In this scenario, the Snow Inventory Agent is configured with the same SiteName for all computers, both Hostname-only mode and Hostname normalization are enabled for the entire computer estate.

The hostnames for the computers server01.europe.company.com and server01.america.company.com are both changed to server01, and the data for the two computers are merged together in a single computer entry, which is not a correct representation.

## Configuration

A SiteConfiguration group contains a boolean expression and groups of criteria. Each group is given a name used as identifier in the boolean expression. Each group of criteria is evaluated to true or false, depending on whether the evaluated computer fulfills the criteria or not, and then it is added in the boolean expression. Finally, if the boolean expression evaluates to true, then Hostname-only mode is used to identify the computer.

### Note

• All of the criteria tags are optional.

• The xml schema for criteria definition is case sensitive.

• The criteria parameters are not case sensitive.

• There can be multiple SiteConfiguration groups to account for different site configurations.

Example 20.
<?xml version="1.0" encoding="utf-8"?>
<Configuration>
<Master>
[…]
<HostnameNormalization>
<SiteConfiguration expression="{A} AND {B}">
<SiteNames name="A">
<SiteName>snow*</SiteName>
</SiteNames>
<ConfigNames name="B">
<ConfigName>linux-config</ConfigName>
</ConfigNames>
</SiteConfiguration>
</HostnameNormalization>
</Master>
[…]
</Configuration>


Example 21. Enable Hostname normalization for the entire estate
<?xml version="1.0" encoding="utf-8"?>
<Configuration>
<Master>
[…]
<HostnameNormalization>
<SiteConfiguration expression="true"/>
</HostnameNormalization>
</Master>
[…]
</Configuration>