ODM API

ITEM: RS4000013355



**************> QUESTION level 1 --> level 2 SPECIALIST <**************         
Hi,                                                                             
I cannot find examples for the use of ODM API. Could anyone show me             
how to do (for example) 'lsattr -El mem0' or 'odmget -q"name=mem0"              
CuAt'                                                                           
with these routines?                                                            
Thanks in advance,                                                              
Ralf                                                                            
**************> ANSWER   level 2 --> level 1 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN USA                                  
PMR 00066,998,758 was created on 97/01/28 at 23:16:06.                          
**************> ANSWER   level 2 --> level 1 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN USA                                  
====> ASGN: SGARDNER AT WTSCPOK  ================= DATE:970128                  
TIME:2103                                                                      
Received by Austin ITSC and assigned to AIXOPSYS.                               
                                                                                
Your question has been received and assigned to a specialist. Please            
wait for a reply. Thank you                                                     
**************> ANSWER   level 2 --> level 1 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN USA                                  
====> RESP: AIXOPSYS AT WTSCPOK  ================= DATE:970129                  
TIME:0802                                                                       
                                                                                
YOUR ITEM HAS BEEN RECEIVED.                                                    
                                                                                
**************> ANSWER   level 2 --> level 1 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN USA                                  
====> RESP: AIXOPSYS AT WTSCPOK  ================= DATE:970129                  
TIME:1323                                                                      
                                                                                
RESPONSE:                                                                       
                                                                                
Are you trying to view information in ODM about API?                            
Is ADSM and/or API currently running on the system?                             
And if so for what device, and optical library?                                 
What type of information do you need about API from the ODM?                    
Or are you just trying to use or install API?                                   
                                                                                
Can you be more specific about what you are trying to do?                       
                                                                                
Reply with response.                                                            
                                                                                
**************> QUESTION level 1 --> level 2 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN ITALY                               
I want to retrieve information from ODM trought a C program, not                
using the commands like lsattr or odmget.                                       
What I like to do is to write a simple program that could tell me               
the amount of memory/L2 cache in the system. These info are stored              
in the ODM database (CuAt) since I can get them entering the                    
'odmget -q"name=mem0" CuAt' command.                                            
But the odmget command is using an API (I think odm_get_list that               
is referenced in odmi.h or somethings like that).                               
Using info I didn't find example for these routines. Could you help             
me sending an example?                                                          
Or better could you send me the source of odmget command?                       
Thanks in advance.                                                              
R. Loi                                                                          
**************> ANSWER   level 2 --> level 1 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN USA                                 
PMR 00066,998,758 was updated on 97/01/30 at 08:20:26.                          
**************> ANSWER   level 2 --> level 1 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN USA                                  
====> ASGN: SGARDNER AT WTSCPOK  ================= DATE:970130                  
TIME:0609                                                                       
Received by Austin ITSC and assigned to AIXOPSYS.                               
                                                                                
Your question has been received and assigned to a specialist. Please            
wait for a reply. Thank you                                                     
**************> ANSWER   level 2 --> level 1 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN USA                                  
====> RESP: AIXOPSYS AT WTSCPOK  ================= DATE:970130                  
TIME:0750                                                                       
                                                                                
YOUR ADDITIONAL INFORMATION HAS BEEN RECEIVED.                                 
                                                                                
**************> ANSWER   level 2 --> level 1 SPECIALIST <**************         
====> THIS TEXT HAS BEEN ENTERED BY IBM IN USA                                  
====> RESP: AIXOPSYS AT WTSCPOK  ================= DATE:970130                  
TIME:1632                                                                       
                                                                                
RESPONSE:                                                                       
                                                                                
The following are some of the ODM subroutine calls that can be found in         
/lib/libodm.a, with their header files in /usr/include/odmi.h:                  
                                                                                
odm_add_obj      Adds a new object to the object class                          
odm_change_obj   Changes the contents of an object                              
odm_get_by_id    Retrieves an object by specifying its ID                       
odm_get_first    Retrieves the first object that matches criteria              
odm_get_list     Retrieves a list of objects that match criteria                
odm_get_next     Retrieves the next object that matches criteria                
odm_get_obj      Retrieves an object that matches criteria                      
odm_rm_by_id     Removes an object by specifying its ID                         
odm_rm_obj       Removes all objects that match the specified criteria          
odm_run_method   Invokes a method for the specified object                      
odm_close_class  Closes an object class                                         
odm_create_class Creates an empty object class                                  
odm_lock         Locks an object class                                          
odm_mount_class  Retrieves an object class description                          
odm_open_class   Opens an object class                                          
odm_rm_class     Removes an object class                                        
odm_set_path     Sets the default path for object classes                       
odm_set_perms    Sets default permissions for object class creation             
odm_unlock       Unlocks an object class or group of classes                   
odm_err_msg      Retrieves a message string                                     
odm_free_list    Frees memory allocated for the odm_get_list subroutine         
odm_initialize   Initialzes an ODM session                                      
odm_terminate    Ends an ODM sesion                                             
                                                                                
These routines are callable from the C programming language                     
                                                                                
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++          
                                                                                
                  We cannot distribute AIX source code.                         
                                                                                
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++          
                                                                                
ADDITIONAL RESPONSE:                                                            
                                                                               
The only example code that demonstrates any ODM calls would be                  
part of the source code developer files that would be part of the               
"bos.adt.samples" fileset. In particular, the source files within               
/usr/samples/cfg will includes code that manipulates ODM in reference           
to device configuration.                                                        
                                                                                
The only other references to use of these ODM calls would be in                 
InfoExplorer on a per system call basis.                                        
                                                                                
        AGAIN TO REITERATE THE ABOVE TEXT:                                      
                                                                                
        We cannot distribute AIX source code.                                   
                                                                                
Thank you for using AIX Suppport Family services.                               
                                                                               


WWQA: ITEM: RS4000013355 ITEM: RS4000013355
Dated: 01/1997 Category: AIXGENR
This HTML file was generated 99/06/24~12:43:04
Comments or suggestions? Contact us