minimada / ipmi-fru-it

A tool for reading and writing IPMI FRU data files.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ipmi-fru-it

Github Issues Average time to resolve an issue

ipmi-fru-it (pronounced ipmi-fruit) is a command-line utility for reading and writing IPMI FRU data.

It follows the IPMI Management FRU Information Storage Definition Specification when reading/writing a FRU data file.

NOTE: This tool uses the iniparser library for parsing the config file. This library was modified for some bug-fixes.

Usage:

Generating a FRU data file:

$ ipmi-fru-it -s 256 -c fru.conf -o FRU.bin

Reading a FRU data file:

$ ipmi-fru-it -r -i FRU.bin

FRU config

The FRU data to be written is provided by means of a config file as input to ipmi-fru-it. The config file follows a simple INI file format and provides data for the various FRU sections.

ipmi-fru-it understands only the following INI section headers (other sections are simply ignored):

  • iua
  • cia
  • bia
  • pia

These map directly to the various FRU sections of the FRU Information Storage Definition specifications. ALL sections are optional and can have additional custom keys, which are placed in the custom area of that section (see FRU storage def specs). Each pre-defined field not specified in a section, is stored as an empty type/length value.

Section headers

  1. iua (Internal Use Area): If this section is specified, it MUST have a key - bin_file with a value as the absolute path of a file that you want included in the internal use area. The file is treated as a binary file and it's contents are copied as-is into this FRU section.
  2. cia (Chassis Info Area): If this section is specified, it should have the following pre-defined keys:
  3. chassis_type - A single byte number specifying the type of chassis as defined in SMBIOS Reference Spec, (7.4.1 System Enclosure or Chassis Types).
  4. part_number - ASCII string.
  5. serial_number - ASCII string.
  6. bia (Board Info Area): If this section is specified, it should have the following pre-defined keys:
  7. mfg_datetime - Number of minutes from 0:00 hrs 1/1/96.
  8. manufacturer - ASCII string.
  9. product_name - ASCII string.
  10. serial_number - ASCII string.
  11. part_number - ASCII string.
  12. pia (Platform Info Area): If this section is specified, it should have the following pre-defined keys:
  13. manufacturer - ASCII string.
  14. product_name - ASCII string.
  15. part_number - ASCII string.
  16. version - ASCII string.
  17. serial_number - ASCII string.
  18. asset_tag - ASCII string.

Reading FRU data file

TBD.

Known Issues

  • Any ASCII value in the config file MUST be in UPPER case.
  • Currently, there's no way to specify binary or BCD data for any of the FRU sections (ipmi-fru-it assumes all keys are ASCII text).

TODO

  • Implement -r option - read contents of a FRU data file.
  • Support for MultiRecord Headers.
  • Support for FRU File ID.
  • ASCII values should be case-insensitive.
  • Find a way to specify BCD values.

About

A tool for reading and writing IPMI FRU data files.

License:MIT License


Languages

Language:C 65.2%Language:Objective-C 17.4%Language:CSS 12.9%Language:Makefile 3.1%Language:Shell 1.2%Language:Python 0.2%