The Chef asset load fetches device information, including the CPU, IP address and Serial Number of a device.
You'll get complete visibility of your devices as data from Chef is automatically transformed into consumable information and actionable insights.
Connect Oomnitza and Chef in minutes
Get the information and insights that you need to reduce costs and the time that you spend on administration tasks such as:
- Configurable dashboards and list views of key device information
- Configurable reports to share information about devices with your colleagues and management such as corporate-wide reports that detail the distribution and status of the devices in your environment
Note on the Chef basic integration
This integration is a local basic integration, which means that it needs to be managed on your local machine. You'll need to prepare your local environment beforehand, download the Oomnitza connector, update a configuration file, and push it to your Oomnitza instance. Finally, you'll need to manage the scheduling of your basic integration on your local machine (using tools such as Task Scheduler for example).
Before you start
To stream data into Oomnitza, complete these tasks:
- Review the system requirements.
- Download and install Python. Best practice is to create a virtual environment. A virtual environment is created on top of the existing Python installation and can be isolated from the packages in the base environment, so only those explicitly installed in the virtual environment are available.
Download the source code for the Oomnitza connector
-
In Oomnitza, click Configuration > Integrations and click Block view
- In the Basic section for Asset Integrations, click the Chef tile.
- Download the source code and place it in a directory, such as
C:\oomnitza_connector
You can also download the source code on the Oomnitza Connector page on GitHub.
Installing the requirements
In the directory you created (C:\oomnitza_connector), install the required Python dependencies stored in the requirements.txt file using pip install -r requirements.txt
Tip
Run pip install --upgrade pip before installing and use the new version of pip
Generate the configuration file
In the same directory, runpython connector.py generate-ini to generate theconfig.inifile. For further information read the Connector Configs section in the Getting started document.
Tip
Run python connector.py --help to see all available command line options.
Edit the configuration file
You must modify the following sections in the configuration file:
- The Oomnitza section
- The Chef section
Before you edit the configuration file, you must retrieve the following information:
Your Oomnitza token which can be created in Configuration > Security > API tokens
Your Chef details
- Open the configuration file that you generated in edit mode.
- In the Oomnitza section, enter the URL of your Oomnitza instance and enter the API token that you generated in Oomnitza.
Oomnitza configuration settings
[oomnitza]
url= https://<name_of_instance>.oomnitza.com
api token = <my_Oomnitza_token> - In the Chef section, make the following changes:
- Set enable to True to turn the integration on.
- URL: The URL of your organization's Chef Instance. The URL must include /organizations/NAME as part of the name for the endpoint.
- Client: The Chef username for authentication
- Key_file: The path to the private key file (e.g. /path/to/user.pem) used for authentication. More information on Chef Key files can be found here: https://docs-archive.chef.io/release/server_12-8/auth.html
- Attribute_extension: (Optional). Dictionary of additional attributes to be mapped. The examples below map the Kernel Name and Mac and Windows Machine Names.
Chef settings
[chef]
enable = True
url = https://example.com/organizations/org
client = user
key_file = /path/to/user.pem
attribute_extension = {"__default__": {"kernel_name": "automatic.kernel.name"}}
attribute_extension = { "mac_os_x": {"machine_name": "automatic.machinename"}, "windows": {"machine_name": "automatic.foo.bar"} } - You can delete all the other configurations you do not need from the list, i.e. Kace, Chef etc.
- Save your changes.
Map Chef fields to Oomnitza fields
Map Chef fields to Oomnitza fields to get the asset information that you need. For the field mapping, it is recommended to follow these steps:
-
Cick Configuration > Integrations and click Block view
- In the Basic section for Asset Integrations, click the Chef tile.
- Click Mappings.
- Map the Chef fields to the Oomnitza fields.
- Select a unique value for the sync key, such as the Serial Number, which will synchronize the data that is streamed from Chef to Oomnitza.
- Click FINISH.
When your connector is uploaded to Oomnitza, it will use the mappings that you have configured.
Custom mappings
CPU
CPU Count
Domain
FQDN
Hostname
IP Address
Mac Address
Model
Node Name
Platform
Platform Version
Serial Number
Total HDD MB
Total Memory MB
Uptime Seconds
You can define mappings in the UI (as described above) or in the configuration file, as follows:
[chef]
enable = True
url = https://example.com/organizations/org
client = user
key_file = /path/to/user.pem
attribute_extension = {"__default__": {"kernel_name": "automatic.kernel.name"}}
attribute_extension = { "mac_os_x": {"machine_name": "automatic.machinename"}, "windows": {"machine_name": "automatic.foo.bar"} }
mapping.1234567* = {'source': "hardware.device_model"}
mapping.1234567* = {'source': "hardware.total_memory_mb"}
Replace 1234567 with the ID of the Oomnitza field. You can find the External ID by navigating to Configuration > Data Model > Field Configuration > Users in your Oomnitza instance. Locate your field in the list. The ID is displayed in the Field Information tab. Make sure to prepend the Chef value you wish to import to Oomnitza with "hardware.".
Contact Support for more information.
Run the Chef network devices connector
To upload the Chef information to Oomnitza, run the connector.
Run the connector in test mode to ensure that the mapped information is uploaded to Oomnitza:
python connector.py upload chef --testmode
When you are confident that you are uploading the information that you mapped, run the connector again in normal mode:
python connector.py upload chef
Getting your results
-
Click Configuration > Integrations and click Block view
- In the Basic section for Asset Integrations, click the Chef tile.
- Click SYNC SESSIONS.
- Go to the Assets page and review the information that is uploaded.
Schedule
To find out how to schedule the Chef integration, contact Support or see Installing the connector
Unleash the power of Oomnitza
To get valuable actionable insights that help you manage your assets, learn how to:
- Configure dashboards for your assets
- Configure custom reports about your assets
See Getting started.
Comments
0 comments
Please sign in to leave a comment.