---
title: Collecting Hardware Data from MIB (SNMP)
slug: citsmart-8-en/collecting-hardware-data-from-mib-snmp
description: Learn how to collect hardware asset data using the SNMP protocol and add it to the Configuration Management process with this comprehensive document. Deploy Inventory Version 1.2.1.9 or higher, configure the standalone-full.xml file, and define an invento
docTags: 
createdAt: 2022-01-19T22:36:47.000Z
---

It is possible to <font color="#3b9f0f">**collect hardware asset data using the SNMP protocol**</font> - via MIB collection - and add to the information of a configuration item in the **Configuration Management** process.

## What to do before

- [x] It is necessary to have deployed the <font color="#3b9f0f">**CITSmart** </font>**Inventory Version 1.2.1.9** or higher (see Perform installation);
- [x] In the **standalone-full.xml** file, add the property `snmp.oid.repository.directory` with the path of the folder where it will be the xml files with the layout (see **System Properties Configuration**);
- [x] Have an inventory process defined via Configuration Management (see **Implement&#x20;**<font color="#3b9f0f">**CITSmart** </font>**Inventory**);
- [x] Inventory the SNMP configuration item for collecting MIB (see **Configuring Inventory Connection**);

## Creating Model

****<font color="#3b9f0f">**Model\:**</font>****

```xml
<ITS-TYPE-ITEM oid-validator="(OID of a specific property that will allow the rest of the file to be interpreted. If no value is returned, the TYPE-ITEM is not created.)">
                <ITS-CHARACTERISTIC>(OID of the information you want)</ITS-CHARACTERISTIC>
                <CHARACTERISTIC-IN-HEXA type="hex">(OID of the information that the returned value needs to be converted from HEXADECIMAL)</CHARACTERISTIC-IN-HEXA>
</ITS-TYPE-ITEM>
```

****<font color="#3b9f0f">**Example\:**</font>****

```xml
<PRINTER oid-validator=".1.3.6.1.2.1.43.5.1.1.16.1">
                <NAME>.1.3.6.1.2.1.43.5.1.1.16.1</NAME>
                <DESCRIPTION type="hex">.1.3.6.1.2.1.43.5.1.1.16.1</DESCRIPTION>
                <NUMBER-PAGES-PRINTED>.1.3.6.1.2.1.43.10.2.1.4.1.1</NUMBER-PAGES-PRINTED>
                <CAPACITY-TOTAL-TONER>.1.3.6.1.2.1.43.11.1.1.8.1.1</CAPACITY-TOTAL-TONER>
                <CAPACITY-CURRENT-TONER>.1.3.6.1.2.1.43.11.1.1.9.1.1</CAPACITY-CURRENT-TONER>
</PRINTER>
```

## Deploying Model

After creating the model, it is necessary to save it in the folder indicated in the `snmp.oid.repository.directory` parameter of the application server.&#x20;

After the model deployment, at the time of inventory execution, the application will check the CI that has the indicated MIB and will automatically update the assets with the collected information.

:::hint{type="warning"}
⚠️ <u>**Attention**</u>**!&#x20;**

1. Layout files can have any name. All files in the folder will be interpreted, so there can only be XML files inside it;
2. If there is more than one layout, it can be placed within the same file or in different files. It's only necessary to respect the XML format;
:::

:::hint{type="info"}
<u>**Learn more**</u>**&#x20;💬**

1. <font color="#3376bc"><u>**http\://www.oidview.com/mibs/**</u></font> - Repository containing thousands of MIB separated by the manufacturers.
2. <font color="#377fc9"><u>**http\://ireasoning.com/mibbrowser.shtml**</u> </font>- MibBrowser tool that can assist in OID collection.
:::



