faq-1: Subject: EM 1.0 Installation and Configuration faq-1: faq-1: Question: faq-1: ========= faq-1: faq-1: How can I configure EM so it doesn't need to be run as root? faq-1: faq-1: faq-1: Answer: faq-1: ======= faq-1: faq-1: There are two steps necessary to use EM as a non-root user. faq-1: faq-1: a. Modify tools so non-root user can execute them: faq-1: faq-1: 1. Log in as root faq-1: 2. cd /opt/SUNWconn/em/etc faq-1: 3. chmod 4555 em_dmuxd faq-1: 4. cd /opt/SUNWconn/em/bin faq-1: 5. chmod 4555 em_mis faq-1: 6. edit "em_services" to comment out the following lines by faq-1: adding '#' in the first column (starting at line 21): faq-1: faq-1: #if test `id | awk '{print $1}'` != "uid=0(root)" faq-1: #then faq-1: # $ECHO "You must be root user to run em_services." faq-1: # exit 1 faq-1: #fi faq-1: faq-1: 7. Modify "var-install" to change all chmod, chgrp, and chown faq-1: to user name and group: faq-1: faq-1: line 60: makedir 755 username usergroup ${runtime} faq-1: line 63: makedir 777 username usergroup line 74: copyfile 644 username usergroup $EM_MIS_... faq-1: line 75: copyfile 644 username usergroup ... faq-1: line 76: copyfile 644 username usergroup ... faq-1: line 90: chown -f username ${runtime}/data/MDR faq-1: line 103:chown -f username * faq-1: faq-1: 8. If em_services is currently running, please run faq-1: "em_services -s" to stop it, so later the non-root users faq-1: can restart it. faq-1: faq-1: b. Since the original database files were created as root, you must faq-1: remove them, so when em_services is restarted, the files will take faq-1: on the permission of the user starting them. faq-1: faq-1: 1. Log in as root faq-1: 2. rm -rf /var/opt/SUNWconn/em/* faq-1: 3. chmod 777 /var/opt/SUNWconn/em faq-1: 4. Log in as normal user faq-1: 5. em_services -r faq-1: faq-1: Please be aware of that the permission problem will occur unless you faq-1: stick to the same (non-root) user to run MIS. faq-2: Subject: Changing the fonts on the viewer faq-2: faq-2: Question: faq-2: ========= faq-2: faq-2: For EM 1.0, how can I change the fonts the viewer uses? faq-2: faq-2: Answer: faq-2: ======= faq-2: faq-2: Currently, the only changeable font, is the viewer label. To change this font, faq-2: add the following line to your .Xdefaults file (in your home directory): faq-2: faq-2: em_viewer.viewer_label_font: helvetica-bold-18 faq-2: faq-2: Save the file, then run the command: xrdb ~/.Xdefaults faq-2: Anytime you start the viewer, it will use this font for the glyph labels. faq-3: Subject: Error message "Can't find view" faq-3: faq-3: Question: faq-3: ========= faq-3: faq-3: Why do I get the error message "Can't find view. Going back to 'Root' View"? faq-3: faq-3: faq-3: Answer: faq-3: ======= faq-3: faq-3: At some point, you have set your default view in the Viewer (Options->Set faq-3: Preferences...) to some view which no longer exists in the MIS. The default faq-3: view is stored in ~/.em_viewer.cf faq-4: Subject: How to add glyphs to object palette (EM 1.0) faq-4: faq-4: Question: faq-4: ========= faq-4: faq-4: Using EM 1.0, how do I add my own glyphs to the Object Palette? faq-4: faq-4: faq-4: Answer: faq-4: ======= faq-4: faq-4: This was taken from chapter 13 of the 1.0 User's Guide: faq-4: faq-4: This chapter presents the steps you can follow to add a new object type to the faq-4: Solstice EM Viewer's Object Palette. In this example, a new Container class faq-4: object called SpecialView will be created. After the MIS is restarted, this new faq-4: Container class object will be displayed in the Object Palette. faq-4: faq-4: Warning - The method for adding a new object to the Viewer's Object Palette faq-4: will change in a future release. A GUI will be provided to accomplish this task faq-4: and this method will no longer be supported at that time. faq-4: faq-4: a. Decide the class of object you want to add (Device, Connection, Container) faq-4: to the Object Palette. faq-4: faq-4: In this example a Container object is being added. faq-4: faq-4: b. Edit the /opt/SUNWconn/em/install/platform/map/common/init_map file to add faq-4: the following information: faq-4: faq-4: $df = TOPO'pack_TopoTypes($type{"Container"}); faq-4: &TopoDB'new_type($tdb, "SpecialView", $dl_lvl, $dl_lvl, faq-4: $df, undef, undef), "n"; faq-4: faq-4: The above lines should be added to the file where other lines of the faq-4: same format already exist. faq-4: faq-4: c. Create an icon for the SpecialView Container class object in a file called faq-4: /opt/SUNWconn/em/glyphs/SpecialView.pm. faq-4: faq-4: Note that the Viewer application will look for the SpecialView.pm faq-4: file to obtain the icon that is associated with the SpecialView faq-4: Container class. faq-4: faq-4: d. Add a line of the following format for each object you would like to able faq-4: to create below a special view, to the init_map file: faq-4: faq-4: &TopoType'add_child($type{"SpecialView"}, $type{"Universe"}); faq-4: faq-4: The above line should be added to the file where other lines of the faq-4: same format already exist. faq-4: faq-4: e. Add a line of the following format for each object you wish to be able to faq-4: create a special view under, to the init_map file: faq-4: faq-4: &TopoType'add_child($type{"SubNetwork"}, $type{"SpecialView"}); faq-4: faq-4: The above line should be added to the file where other lines of the faq-4: same format already exist. faq-4: faq-4: f. Restart the MIS: em_services -i faq-4: faq-4: Once you have created the objects (either using the init_map file, the Object faq-4: Editor, or a PMI program), and the object exists in the MIT (can be seen using faq-4: Obed: /emDomainTitle=oid:{1 2 3 1}/emApplicationType="TOPOLOGY" faq-4: /topoDatabaseId="TOPO"/topoTypeId="SpecialView"), if you restart the faq-4: viewer, it reads the topo types, and adds them to the palette. faq-4: faq-4: The viewer looks for the glyph in /opt/SUNWconn/em/glyphs with the file name faq-4: SpecialView.pm faq-4: faq-4: If you use init_map, the create only happens with em_services -i or faq-4: em_services -r. If you create the object yourself the viewer needs to be faq-4: restarted. faq-4: faq-4: If the object exists, and the glyph file exists, then you should be able to faq-4: use it. faq-4: faq-4: The Options -> Configure Device Menus... gets its information from faq-4: a configuration file. This is either in /opt/SUNWconn/em/config/em_viewer.cf faq-4: or in your HOME directory as .em_viewer.cf faq-4: faq-4: If you add a new type, you need to add it to this file. For device type faq-4: SpecialView: faq-4: faq-4: Menu SpecialView faq-4: { faq-4: "Configure..." EM_VIEWERCONFIG faq-4: "View Data..." /opt/SUNWconn/em/bin/em_dataviewer -o EM_OBJNAME faq-4: "Ping" xterm -title Ping -e ping -I 10 EM_OBJNAME faq-4: "Alarms..." /opt/SUNWconn/em/bin/em_alarmmgr -device EM_OBJNAME faq-4: "Reset State" EM_VIEWERRESET faq-4: "Go To View" EM_GOTOVIEW faq-4: } faq-4: faq-4: Activations faq-4: { faq-4: "Bridge" EM_VIEWERCONFIG faq-4: "Container" EM_GOTOVIEW faq-4: "Device" EM_VIEWERCONFIG faq-4: "Host" EM_VIEWERCONFIG faq-4: "SpecialView" EM_GOTOVIEW faq-4: "Hub" EM_VIEWERCONFIG faq-4: "Network" EM_GOTOVIEW faq-4: "Router" EM_VIEWERCONFIG faq-4: "Server" EM_VIEWERCONFIG faq-4: "Subnetwork" EM_GOTOVIEW faq-4: "Universe" EM_GOTOVIEW faq-4: "View" EM_GOTOVIEW faq-4: } faq-4: faq-5: Subject: A question on links being displayed in the viewer faq-5: faq-5: Question: faq-5: ========= faq-5: faq-5: Using EM 1.0, hy don't my links show up? faq-5: faq-5: faq-5: Answer: faq-5: ======= faq-5: faq-5: Links are currently not allowed in the Root view. faq-6: Subject: What is the Unresolved view? faq-6: faq-6: Question: faq-6: ========= faq-6: faq-6: Using EM 1.0, What is the Unresolved view used for? faq-6: faq-6: faq-6: Answer: faq-6: ======= faq-6: faq-6: If you create objects outside of the Topology container, then an faq-6: instance of those objects appears under the Unresolved view. The faq-6: Topology container is meant to show the true containment of the faq-6: network (network-subnetwork-host). faq-6: faq-7: Subject: severity and color related to Glyphs faq-7: faq-7: Question: faq-7: ========= faq-7: faq-7: I created my own icon, but the when the severity changes, only faq-7: the label color changes. Why? faq-7: faq-7: faq-7: Answer: faq-7: ======= faq-7: faq-7: The viewer uses the area defined as rgb #c8c8c8c8c8c8. When faq-7: the status changes, the viewer updates the glyph, and uses that part of faq-7: the glyph which has that rgb value. So, with the following definition, faq-7: anywhere an 'X' appears, would change to the color associated with the faq-7: severity: faq-7: faq-7: " s none m none c none", faq-7: ". s iconGray1 m white c #e1e1e1e1e1e1", faq-7: "X s iconGray2 m white c #c8c8c8c8c8c8", faq-7: "o s iconGray6 m black c #646464646464", faq-7: "O s selectColor m white c #7d7d7d7d7d7d", faq-7: "+ s iconGray7 m black c #4b4b4b4b4b4b", faq-8: Subject: How to make an icon background transparent faq-8: faq-8: Question: faq-8: ========= faq-8: faq-8: How do I make my icons have transparent backgrounds? faq-8: faq-8: faq-8: Answer: faq-8: ======= faq-8: faq-8: If the none is used as a colorname (e.g. " s none m none c none") faq-8: it means that section of the icon will be set to transparent. faq-8: faq-8: Example: faq-8: faq-8: " s none m none c none", faq-8: ". s iconGray1 m white c #e1e1e1e1e1e1", faq-8: "X s iconGray2 m white c #c8c8c8c8c8c8", faq-8: "o s iconGray6 m black c #646464646464", faq-8: "O s selectColor m white c #7d7d7d7d7d7d", faq-8: "+ s iconGray7 m black c #4b4b4b4b4b4b", faq-9: Subject: Renaming a request template faq-9: faq-9: Question: faq-9: ========= faq-9: faq-9: Using EM 1.0, how do I rename a template? faq-9: faq-9: faq-9: Answer: faq-9: ======= faq-9: faq-9: There is no Save As... button, so in order to rename a request template faq-9: you need to change the name (in the Template Name: field), and then use faq-9: the Save button. faq-10: Subject: bug related to restarting a request after modifying the template faq-10: faq-10: Question: faq-10: ========= faq-10: faq-10: Using EM 1.0, I modified a template, and started a request, faq-10: but it looked like the original request. faq-10: faq-10: faq-10: Answer: faq-10: ======= faq-10: faq-10: There is currently a bug in NerveCenter, so anytime you make modifications to faq-10: a request template, it is a good idea to change the name. faq-11: Subject: A problem with request designer locking up faq-11: faq-11: Question: faq-11: ========= faq-11: faq-11: When using EM 1.0, the Request Designer appears to lock up faq-11: occasionally. faq-11: faq-11: faq-11: Answer: faq-11: ======= faq-11: faq-11: This is due to a scheduler bug. This is annoying, but not destructive. faq-11: It can be worked around by starting up a new Request Designer, and faq-11: killing the old one. faq-12: Subject: Saving request designer templates faq-12: faq-12: Question: faq-12: ========= faq-12: faq-12: Using EM 1.0, how do I save my templates, to move them faq-12: to another host? faq-12: faq-12: faq-12: Answer: faq-12: ======= faq-12: faq-12: It is best to create your templates using the Request Designer, then once faq-12: you have a good working template (debugged), write an NCI program which will faq-12: create the template (or templates). faq-13: Subject: MAIL and UNIXCMD Actions dont work? faq-13: faq-13: Question: faq-13: ========= faq-13: faq-13: It appears that MAIL & UNIXCMD Actions don't work? faq-13: faq-13: faq-13: Answer: faq-13: ======= faq-13: faq-13: Whenever you specify an Action of MAIL or UNIXCMD, you need to specify faq-13: the arguments with double quotes (eg. "/usr/openwin/bin/cmdtool") faq-14: Subject: Why icons dont change color when running NC templates faq-14: faq-14: Question: faq-14: ========= faq-14: faq-14: I developed a Request Template, and ran it, but the icons don't change faq-14: colors? faq-14: faq-14: Answer: faq-14: ======= faq-14: faq-14: The colors of the states in the Request Designer don't actually have faq-14: anything to do with changing the icon color. The icon color changes faq-14: happen when using the RCL function alarm(). This sends a NerveCenter faq-14: Alarm to the MIS. There are some predefined Alarms (AlarmMajor, faq-14: AlarmMinor, etc.). The function alarm() allows you to set the severity, faq-14: which the viewer uses to determine the color of the icon. faq-14: faq-15: Subject: question on state transitions faq-15: faq-15: faq-15: Question: faq-15: ========= faq-15: faq-15: When will a running request transition from one state to another? faq-15: faq-15: faq-15: Answer: faq-15: ======= faq-15: faq-15: There are only two times when you can transition from one state to another. faq-15: faq-15: 1. When an attribute is checked. faq-15: 2. When subscribing to an event, and the event happened. faq-15: faq-15: In the first case, you must check an attribute. Even if it is not valid faq-15: for the $pollfdn (see the Jump Condition), an attribute which is defined faq-15: in the MDR must be checked. faq-16: Subject: How to access the SNM agents faq-16: faq-16: Question: faq-16: ========= faq-16: faq-16: Using EM 1.0 how do I access SNM agents? faq-16: faq-16: faq-16: Answer: faq-16: ======= faq-16: faq-16: When you configure a host as SNM manageable (using the Viewers Object faq-16: Configuration Tool), an RPC managed object gets created for that host: faq-16: faq-16: /systemId="mozes"/agentTableType="RPC"/agentId="host" faq-16: faq-16: All the SNM agent data is available below that object: faq-16: faq-16: agentTableType="RPC"/agentId="host"/agentId="hostperf-data" faq-17: Subject: Creating a request template to access SNM agents faq-17: faq-17: faq-17: Question: faq-17: ========= faq-17: faq-17: How do I create request templates to use SNM agents? faq-17: faq-17: faq-17: Answer: faq-17: ======= faq-17: faq-17: Just make sure you set the $pollfdn to the correct managed object. If you faq-17: are interested in ping-reach attributes, you would set the $pollfdn to: faq-17: faq-17: agentTableType="RPC"/agentId="host"/agentId="ping-reach" faq-17: faq-17: Remember, the viewer starts the request setting the $pollfdn to the value faq-17: of the defaultTopoNodeMO, so the request template only needs to append faq-17: the last agentId. faq-18: Subject: A question on dispatch_recursive( ) faq-18: faq-18: faq-18: Question: faq-18: ========= faq-18: faq-18: What is dispatch_recursive( ) and how to use it? faq-18: faq-18: faq-18: Answer: faq-18: ======= faq-18: faq-18: dispatch_recursive() is used by the PMI for communicating with the MIS. Most faq-18: PMI calls use it internally to wait for responses from the MIS. Many faq-18: applications may need to call it directly. faq-18: faq-18: This function does a select on all the open file descriptors to determine their faq-18: state. If the parameter is set to TRUE, the select will block, waiting for faq-18: input. If FALSE, then the select will poll once. faq-18: faq-18: If your application is waiting for events, then you will need to setup a faq-18: routine which calls dispatch_recursive(): faq-18: faq-18: Boolean faq-18: my_dispatcher() faq-18: { faq-18: // call the pmi routine which checks for received events. faq-18: // If an event has been received, the Callback routine faq-18: // specified in plat.when() will get called directly. faq-18: // faq-18: dispatch_recursive((char)FALSE); faq-18: faq-18: usleep(100000); faq-18: faq-18: return FALSE; faq-18: } faq-19: Subject: Scoping & filtering and how to use it? faq-19: faq-19: faq-19: Question: faq-19: ========= faq-19: faq-19: What is scoping & filtering? How do I use it? faq-19: faq-19: faq-19: Answer: faq-19: ======= faq-19: faq-19: The scope is defined as the sub-tree within the MIT to which a management faq-19: command is to be applied. The scope is described by the node of the parent faq-19: tree at which the sub-tree is rooted, and the depth (number of nodes) to which faq-19: the scope extends. faq-19: faq-19: The filter allows you to select objects that fit a specific criteria. For faq-19: example: faq-19: faq-19: album.set_derivation("/systemId="mozes"/LV(1)/ faq-19: CMISFilter(item:equality:{objectClass,log}) faq-19: faq-19: would set the scope to be all object below /systemId="mozes", and the filter faq-19: would be all objects which are of objectClass log. faq-19: faq-19: faq-19: faq-20: Subject: How to invoke an action using the PMI? faq-20: faq-20: faq-20: Question: faq-20: ========= faq-20: faq-20: How can I invoke an ACTION? faq-20: faq-20: faq-20: Answer: faq-20: ======= faq-20: faq-20: Use the Image.call() member function to invoke an ACTION. faq-20: There is an advanced sample in the src directory faq-20: called derive_snmp.cc. It invokes an action to the MDR to get an faq-20: SNMP document. The action is "getDocument", the arg to the action faq-20: is the document name. The return value is a DataUnit: faq-20: faq-20: DU mdr_data = mdr_image.call("getDocument",""IIMCRFC1213-MIB""); faq-21: Subject: A PMI question on TRACKMODE and the Image class faq-21: faq-21: faq-21: Question: faq-21: ========= faq-21: faq-21: When I create an image and set the TRACKMODE to TRACK, I expect to get faq-21: the most recent value of an attribute using get_str(). Why am I seeing the faq-21: same value? faq-21: faq-21: faq-21: Answer: faq-21: ======= faq-21: faq-21: The TRACK mode doesn't happen magically. The program must invoke faq-21: dispatch_recursive() to handle events from the MIS and update faq-21: the Images related to those events. faq-21: faq-21: The get_str() is a "local" operation. It doesn't go to MIS. If faq-21: dispatch_recursive() is added, the next get_str() would get the new value. faq-22: Subject: An explanation of TRACK and SNAP modes faq-22: faq-22: faq-22: Question: faq-22: ========= faq-22: faq-22: How do TRACK & SNAP modes work? faq-22: faq-22: faq-22: Answer: faq-22: ======= faq-22: faq-22: In "TRACK" mode, get_str gets the most recent (real) value, provided faq-22: dispatch_recursive is called. The set_str without store() does not affect faq-22: the return value of get_str faq-22: faq-22: In "SNAP" mode, get_str gets the attribute value when the MO is created. faq-22: Changes of both "imaginary" and "real" values of the attribute do not faq-22: affect the return value of get_str, EXCEPT the "real" value is changed from faq-22: the same image! (i.e. call set_str and then store, you get the updated faq-22: "real" value when you get_str, even it is in "SNAP" mode). faq-22: faq-22: In both "TRACK" and "SNAP" modes, get_set_str gets the value from last faq-22: set_str faq-23: Subject: How to backup the EM run-time object store faq-23: faq-23: faq-23: Question: faq-23: ========= faq-23: faq-23: How do I backup all my data? faq-23: faq-23: faq-23: Answer: faq-23: ======= faq-23: faq-23: There is a way to backup the entire run-time database & restore it: faq-23: faq-23: host# ufsdump 0f /var/opt/SUNWconn/em faq-23: host# ufsrestore xf /var/opt/SUNWconn/em faq-23: faq-23: But this is only effective for full backups. Currently you can't back faq-23: up just TOPOLOGY information, or just Request Template information, and faq-23: there is no support for creating an editable ASCII file (like SNM). faq-23: faq-24: Subject: A question on EM log files faq-24: faq-24: Question: faq-24: ========= faq-24: faq-24: Where are EM log files? How often are logs saved to disk? faq-24: faq-24: faq-24: Answer: faq-24: ======= faq-24: faq-24: Each time em_logd gets started, it creates a log file in faq-24: /var/opt/SUNWconn/em/data/LOG with the date the file was created: faq-24: faq-24: emlog.120594.12:56 faq-24: faq-24: Anytime a log object gets created/deleted/changed, it gets logged to the faq-24: log file. faq-24: faq-25: Subject: Logging to separate files faq-25: faq-25: faq-25: Question: faq-25: ========= faq-25: faq-25: How can I log individual logs to separate files, rather than one big file? faq-25: faq-25: faq-25: Answer: faq-25: ======= faq-25: faq-25: All log records are objects in the MIT. If you want to log each one separately faq-25: it is just a matter of deriving an Album under /systemId, and filter for log faq-25: Objects. Under each log Object are the logRecords: faq-25: faq-25: logId=string:"AlarmLog"/logRecordId=number:0 faq-25: logId=string:"AlarmLog"/logRecordId=number:1 faq-25: faq-25: faq-26: Subject: Adding custom objects to the platform faq-26: faq-26: faq-26: Question: faq-26: ========= faq-26: faq-26: What is involved in adding my own objects? faq-26: faq-26: faq-26: Answer: faq-26: ======= faq-26: faq-26: In order to create your own local objects, you must first define them in GDMO. After faq-26: you write the GDMO, you need to compile it using `em_gdmo' and put the output faq-26: into /var/opt/SUNWconn/em/usr/data/MDR. The MIS needs to know about the new objects, faq-26: so use the CMIP action `compose_oc' and `load_name_bindings'. Type something faq-26: similar to the following (using the name of your objectClass, and the specific faq-26: NAME BINDING which you defined): faq-26: faq-26: % em_gdmo -v -o /var/opt/SUNWconn/em/usr/data/MDR -f xxx.gdmo faq-26: % em_asn1 -v -o /var/opt/SUNWconn/em/usr/data/ASN1 xxx.asn1 faq-26: % em_compose_oc myObjectClass faq-26: % em_load_name_bindings myObjectClass-system faq-26: faq-27: Subject: How to create custom events faq-27: faq-27: faq-27: Question: faq-27: ========= faq-27: faq-27: How do I create and use my own events? faq-27: faq-27: faq-27: Answer: faq-27: ======= faq-27: faq-27: Once you define your own event in GDMO, you need to setup the MIS to translate faq-27: the user defined event to an object class.To add the event mapping you need to faq-27: do a SET on object faq-27: faq-27: /systemId="host"/subsystemId="EM-MIS"/listname="event2ObjectClass" faq-27: faq-27: In the attribute newitem, add the mapping to the user defined event record: faq-27: faq-27: {event_name, Log Object class name} faq-27: faq-27: You can do this in Obed, or write a small PMI program to do this. faq-27: faq-28: Subject: Constructing an SNMP transport address faq-28: faq-28: faq-28: Question: faq-28: ========= faq-28: faq-28: How is the transportAddress attribute constructed? faq-28: faq-28: faq-28: Answer: faq-28: ======= faq-28: faq-28: The transportAddress is represented as a 6 octet field. The first 4 represent faq-28: the internet address, and the second two are the snmp port. This is shown faq-28: in octal, except when there is a printable representation, then the ascii faq-28: character is shown. faq-28: faq-28: Address Port faq-28: 138.20.20.1 161 -> \212\24\24\001\0\241 faq-28: 138.20.20.80 161 -> \212\24\24P\0\241 faq-29: Subject: Constructing an SNMP transport address with the PMI faq-29: faq-29: faq-29: Question: faq-29: ========= faq-29: faq-29: How can I construct an SNMP transportAddress attribute using the PMI? faq-29: faq-29: faq-29: Answer: faq-29: ======= faq-29: faq-29: The transportAddress is represented as a 6 octet field. The first 4 represent faq-29: the internet address, and the second two are the snmp port. This is shown faq-29: in octal, except when there is a printable representation, then the ascii faq-29: character is shown. faq-29: faq-29: Address Port faq-29: 138.20.20.1 161 -> \212\24\24\001\0\241 faq-29: 138.20.20.80 161 -> \212\24\24P\0\241 faq-29: faq-29: To modify the transportAddress via the PMI you should do the following: faq-29: faq-29: char *addr; faq-29: char xx[6]; faq-29: faq-29: addr = im.get_str(attribute_name).chp(); faq-29: faq-29: xx[0] = addr[0]; faq-29: xx[1] = addr[1]; faq-29: xx[2] = addr[2]; faq-29: xx[3] = addr[3]; faq-29: xx[4] = 0x00; faq-29: xx[5] = 0xa3; faq-29: U32 size = 6; faq-29: faq-29: if(!im.set_str(attribute_name, DU(size,(Octet *)xx))) faq-29: { faq-29: printf("set_str() Failed %s\n",im.get_error_string()); faq-29: exit(4); faq-29: } faq-29: if(!im.store()) faq-29: { faq-29: printf("store() Failed %s\n",im.get_error_string()); faq-29: exit(5); faq-29: } faq-29: faq-30: Subject: Using em_compose_oc, em_compose_poc, and em_load_name_bindings faq-30: faq-30: faq-30: Question: faq-30: ========= faq-30: faq-30: What is em_compose_oc used for? When should I use it? faq-30: faq-30: faq-30: Answer: faq-30: ======= faq-30: faq-30: em_compose_oc is used to tell the MIS that it should use default behaviors faq-30: to access your Managed Object Class. So when a create/get/set/etc comes faq-30: in for the specified MOC, the MIS uses its internal secretaries to faq-30: manipulate the object. faq-30: faq-30: em_compose_oc (or em_compose_poc, for persistent objects) must be used on faq-30: local objects. em_load_name_bindings tells the MIS where in the MIT this faq-30: MOC can be created, so will be used on local objects after em_compose_oc. faq-30: For remote objects, the MIS needs to forward the request to the appropriate faq-30: agent, so you would not use compose_oc. faq-30: