AIX ODM Commands

root's picture

A bit of ODM explanation first:

/etc/objrepos:(Cu* classes and / (root) part of SWVPD)

CuDv (Customized Device):

It contains entries for all device instances defined in the system. (A defined device has been created by the define method, but an actual device no necessarily should be attached to the system)

CuAt (Customized Attribute):

It contains customized device-specific attribute information. Devices in CuDv have attibutes in PdAt and CuAt. Attributes taking the default value are found in PdAt, and attributes with customized values are in CuAt.

CuDep (Customized Dependency):

It contains logical dependencies. (i.e. dependency between lv and a vg, physical device dependencies are stored in CuDv)

CuDvDr (Customized Device Driver):

It stores the major and minor numbers of devices. (Some programs use these special files to access a certain device.)

CuVPD (Customized Vital Product Data):

It contains vital product data (manufacturer of device, part number, and so forth) that is useful for technical support. When an error occurs with a specific device the vital product data is shown in the error log.

Config_Rules: There is one ODM object class which the cfgmgr uses to determine the correct sequence when configuring devices.

/usr/lib/objrepos:(Pd* classes and /usr part of SWVPD)

PdDv (Predefined Devices):

It contains entries for all devices supported by system. A device that is not part of this could not be configured on AIX.

PdAt (Predefined Attribute):

It contains attributes for each device represented in the PdDv object class. These attributes become the default values if they are not modified. Modified attributes are written to the CuAt.

PdCn (The Predefined Connection):

It contains information about how devices physically connect to the system.

sm*: SMIT menu are located in the folowing files : sm_cmd_hdr, sm_cmd_opt,sm_name_hdr, sm_menu_opt

To get the objects from class sm_menu_opt:

# odmget sm_menu_opt

To list objects that matches query id=licenses from object sm_menu_opt:

# odmget -q "id=licenses" sm_menu_opt

To delete the entries from class sm_menu_opt which agrees the query id=licenses:

# odmdelete -o sm_menu_opt -q "id=licenses"

To show the object class definition:

# odmshow sm_menu_opt

To drop sm_menu_opt object class:

# odmdrop -o sm_menu_opt

To change the attributes from file1:

# odmchange -o sm_menu_opt -q "id=licenses" file1

How to list route entries in ODM:

# odmget -q "name=inet0 and attribute=route" CuAt

How to list ethernet device entries in ODM:

[gzaix:root:/home/root:] odmget -q "name=en6" CuDv 

        name = "en6"
        status = 0
        chgstatus = 1
        ddins = "if_en"
        location = ""
        parent = "inet0"
        connwhere = ""
        PdDvLn = "if/EN/en"

How to delete ethernet device entry from ODM:

[gzaix:root:/home/root:] odmdelete -q "name=en6" -o CuDv
0518-307 odmdelete: 1 objects deleted.

Thou shalt not steal!

If you want to use this information on your own website, please remember: by doing copy/paste entirely it is always stealing and you should be ashamed of yourself! Have at least the decency to create your own text and comments and run the commands on your own servers and provide your output, not what I did!

Or at least link back to this website.