Difference between revisions of "RCUG 6 Deploying The RootCause Workspace"

From OC Systems Wiki!
Jump to: navigation, search
m
m
Line 1: Line 1:
  
<div><div>
+
 
  
 
[[RCUG_RootCause_Files_and_Environment_Variables|Next]] [[RCUG_5_RootCause_Demo|Previous]] [[RCUG_Index|Index]] [[RCUG_Top|Top]]
 
[[RCUG_RootCause_Files_and_Environment_Variables|Next]] [[RCUG_5_RootCause_Demo|Previous]] [[RCUG_Index|Index]] [[RCUG_Top|Top]]
Line 6: Line 6:
 
RootCause User Guide
 
RootCause User Guide
  
</div>
 
  
 
= Deploying the RootCause Workspace =
 
= Deploying the RootCause Workspace =
  
 
----
 
----
</div><div><div>
+
<DIV ID="LINK-06deploy_rc.fm-firstpage"></DIV><DIV ID=HEADING9-0></DIV>
 
+
<DIV ID="UID-06deploy_rc.fm-864080"></DIV>
<!-- header -->      {{FULLPAGENAME}}
 
 
 
 
 
 
 
 
 
<DIV>
 
<A NAME=HEADING9></A>
 
 
 
<DIV>
 
<P>
 
<A HREF=rcc-10.html>[Next]</A> <A HREF=rcc-8.html>[Previous]</A> <A HREF=rcc-1.html>[Top]</A> <A HREF=rcc-3.html>[Contents]</A> <A HREF=rcc-14.html>[Index]</A></P>
 
<P>RootCause</P>
 
 
 
</DIV>
 
<A NAME="LINK-06deploy_rc.fm-firstpage"></A><A NAME=HEADING9-0></A>
 
<A NAME="UID-06deploy_rc.fm-864080"></A>
 
  
<!-- <H1>  <A NAME=MARKER-9-873></A> Deploying the RootCause Workspace</H1>  -->
+
<!-- <H1>  <DIV ID=MARKER-9-873></DIV> Deploying the RootCause Workspace</H1>  -->
 
<HR>
 
<HR>
 
<P> RootCause performs root cause analysis of problems at the user's site, in the production system. This chapter discusses how to run traces on a remote computer.</P>
 
<P> RootCause performs root cause analysis of problems at the user's site, in the production system. This chapter discusses how to run traces on a remote computer.</P>
<A NAME=HEADING9-2></A>
+
<DIV ID=HEADING9-2></DIV>
<A NAME="UID-06deploy_rc.fm-953141"></A>
+
<DIV ID="UID-06deploy_rc.fm-953141"></DIV>
<H2> <A NAME=MARKER-9-874></A>Installing The RootCause Agent</H2>
+
<H2> <DIV ID=MARKER-9-874></DIV>Installing The RootCause Agent</H2>
 
<P> RootCause has two components: the RootCause Console and the RootCause Agent. The Agent is the subset of RootCause that is used to run RootCause traces on a remote computer. The Console is the full product that allows one to define and view traces as well as run them (that is, the Console also includes the Agent).</P>
 
<P> RootCause has two components: the RootCause Console and the RootCause Agent. The Agent is the subset of RootCause that is used to run RootCause traces on a remote computer. The Console is the full product that allows one to define and view traces as well as run them (that is, the Console also includes the Agent).</P>
 
<P> If you're just "trying out" the deploy process on a single computer, your Console installation can also serve as the remote installation. If you really are deploying RootCause to a remote site you will want to install just the RootCause Agent subset there, and enable remote execution using RootCause agent licenses.</P>
 
<P> If you're just "trying out" the deploy process on a single computer, your Console installation can also serve as the remote installation. If you really are deploying RootCause to a remote site you will want to install just the RootCause Agent subset there, and enable remote execution using RootCause agent licenses.</P>
<P> Follow the installation directions in <A HREF="rcc-5.html#MARKER-9-251">"RootCause Agent Installation"</A> to install the RootCause Agent on the remote computer; this only needs to be done once per remote computer. </P>
+
<P> Follow the installation directions in [["rcc-5.html#MARKER-9-251">"RootCause Agent Installation"</DIV> to install the RootCause Agent on the remote computer; this only needs to be done once per remote computer. </P>
<P> <A NAME=MARKER-10-875></A>After this is installed on the remote computer, you deploy RootCause trace definitions to the remote RootCause Agent and get back files that contain the logged trace data.</P>
+
<P> <DIV ID=MARKER-10-875></DIV>After this is installed on the remote computer, you deploy RootCause trace definitions to the remote RootCause Agent and get back files that contain the logged trace data.</P>
 
<P> The Agent installation does not have its own license--the license is delivered with the deployed probes. Instead, you will obtain one or more agent license keys from OC Systems and append them to the file </P>
 
<P> The Agent installation does not have its own license--the license is delivered with the deployed probes. Instead, you will obtain one or more agent license keys from OC Systems and append them to the file </P>
 
<PRE>
 
<PRE>
<CODE>$<A NAME=MARKER-10-876></A>APROBE<A NAME=MARKER-10-877></A>/<A NAME=MARKER-10-878></A>licenses/<A NAME=MARKER-10-879></A>agent_license.dat</CODE>
+
<CODE>$<DIV ID=MARKER-10-876></DIV>APROBE<DIV ID=MARKER-10-877></DIV>/<DIV ID=MARKER-10-878></DIV>licenses/<DIV ID=MARKER-10-879></DIV>agent_license.dat</CODE>
 
</PRE>
 
</PRE>
<P> in your RootCause Console installation. Agent licenses will be automatically copied into the deployed workspace (see <A HREF="#MARKER-9-887">"Deploying A RootCause Workspace"</A>). See <A HREF="rcc-5.html#MARKER-9-259">"Licensing"</A> for a more in-depth discussion on licensing issues.</P>
+
<P> in your RootCause Console installation. Agent licenses will be automatically copied into the deployed workspace (see [["#MARKER-9-887">"Deploying A RootCause Workspace"</DIV>). See [["rcc-5.html#MARKER-9-259">"Licensing"</DIV> for a more in-depth discussion on licensing issues.</P>
<A NAME=HEADING9-10></A>
+
<DIV ID=HEADING9-10></DIV>
<A NAME="UID-06deploy_rc.fm-949698"></A>
+
<DIV ID="UID-06deploy_rc.fm-949698"></DIV>
<H2> <A NAME=MARKER-9-880></A>Building a "Traceable" Application</H2>
+
<H2> <DIV ID=MARKER-9-880></DIV>Building a "Traceable" Application</H2>
<P> <A NAME=MARKER-10-881></A>Production systems often have their applications stripped of debug and symbol information to save space and increase security. The program runs fine in the field without this information. However, meaningful tracing information cannot be obtained without this debug and symbol information.</P>
+
<P> <DIV ID=MARKER-10-881></DIV>Production systems often have their applications stripped of debug and symbol information to save space and increase security. The program runs fine in the field without this information. However, meaningful tracing information cannot be obtained without this debug and symbol information.</P>
<P> RootCause solves this problem by allowing one to define the trace on a version of the application that contains debug and symbol information and then to run that trace against a version of the same application <A NAME=MARKER-10-882></A>from which this debug information has been removed by the "strip" command. RootCause will "remember" the necessary debug and symbol information for the <A HREF="rcc-6.html#MARKER-9-468">stripped</A> application.</P>
+
<P> RootCause solves this problem by allowing one to define the trace on a version of the application that contains debug and symbol information and then to run that trace against a version of the same application <DIV ID=MARKER-10-882></DIV>from which this debug information has been removed by the "strip" command. RootCause will "remember" the necessary debug and symbol information for the [["rcc-6.html#MARKER-9-468">stripped</DIV> application.</P>
<P> The presence or absence of debug and symbol information should be the <EM>only</EM> difference between the development and production versions. You should define your traces based on the <EM>exact same object code</EM> on which the traces will be run. This is a requirement if you wish to trace source lines or access local data values. So, to be assured of reliable traces regardless of what you select, you must develop your traces against the program you will be shipping, <A NAME=MARKER-10-883></A>and then strip (using a "strip" command) the executable files prior to distribution. RootCause has been designed so that you can define your traces on the application in which debug information is available, and then run that application under RootCause either with or without that information present in the execution environment.</P>
+
<P> The presence or absence of debug and symbol information should be the <EM>only</EM> difference between the development and production versions. You should define your traces based on the <EM>exact same object code</EM> on which the traces will be run. This is a requirement if you wish to trace source lines or access local data values. So, to be assured of reliable traces regardless of what you select, you must develop your traces against the program you will be shipping, <DIV ID=MARKER-10-883></DIV>and then strip (using a "strip" command) the executable files prior to distribution. RootCause has been designed so that you can define your traces on the application in which debug information is available, and then run that application under RootCause either with or without that information present in the execution environment.</P>
<P> When you perform the RootCause deploy operation (see <A HREF="#MARKER-9-887">"Deploying A RootCause Workspace"</A>) to create the packaged workspace for use in the production environment, you check the module(s) that will be stripped in the remote environment. RootCause collects the necessary information for the trace from the local non-stripped module and writes it to an ADI file. The ADI file is then automatically and invisibly included in the deployed RootCause workspace. The deployed workspace now contains sufficient symbolic information to allow RootCause to run on the stripped application in the production environment. </P>
+
<P> When you perform the RootCause deploy operation (see [["#MARKER-9-887">"Deploying A RootCause Workspace"</DIV>) to create the packaged workspace for use in the production environment, you check the module(s) that will be stripped in the remote environment. RootCause collects the necessary information for the trace from the local non-stripped module and writes it to an ADI file. The ADI file is then automatically and invisibly included in the deployed RootCause workspace. The deployed workspace now contains sufficient symbolic information to allow RootCause to run on the stripped application in the production environment. </P>
 
<P> RootCause ADI files carry the symbolic information necessary to perform RootCause traces, so that information may be stripped from the executables themselves. But there remains the issue of how to develop useful traces on an application built for delivery: must you change your build process in order to accommodate RootCause? In some cases, yes.</P>
 
<P> RootCause ADI files carry the symbolic information necessary to perform RootCause traces, so that information may be stripped from the executables themselves. But there remains the issue of how to develop useful traces on an application built for delivery: must you change your build process in order to accommodate RootCause? In some cases, yes.</P>
<P> <A NAME=MARKER-10-884></A>If you simply wish to trace the functions executed by your program, you do not need debug information; all you need is symbols, which are generally present until you perform a strip command. So, for example, the initial tracing of the "pi_demo" program from <A HREF="rcc-8.html#MARKER-9-707">Chapter 5, &quot;RootCause Demo&quot;</A> would work fine even if the program were compiled with optimize and with no debug information.</P>
+
<P> <DIV ID=MARKER-10-884></DIV>If you simply wish to trace the functions executed by your program, you do not need debug information; all you need is symbols, which are generally present until you perform a strip command. So, for example, the initial tracing of the "pi_demo" program from [["rcc-8.html#MARKER-9-707">Chapter 5, &quot;RootCause Demo&quot;</DIV> would work fine even if the program were compiled with optimize and with no debug information.</P>
 
<P> If you wish to select parameters and data values as part of your trace, the executable or shared module in which the log operation is taking place must be compiled with a debug (-g) flag. If you usually build your application with optimize (-O) and other flags that affect the generated code (e.g., -DNDEBUG) then you must do this on the version to be traced.</P>
 
<P> If you wish to select parameters and data values as part of your trace, the executable or shared module in which the log operation is taking place must be compiled with a debug (-g) flag. If you usually build your application with optimize (-O) and other flags that affect the generated code (e.g., -DNDEBUG) then you must do this on the version to be traced.</P>
 
<P> Note that specifying -g with -O may reduce the effect of optimization, but this compromise is necessary in order to have access to accurate source-level information with which to develop your traces. However, if you cannot use -g on your delivered programs, you can still develop traces by restricting the information you want to log. Also, note that only those files that you desire to trace need be compiled with -g.</P>
 
<P> Note that specifying -g with -O may reduce the effect of optimization, but this compromise is necessary in order to have access to accurate source-level information with which to develop your traces. However, if you cannot use -g on your delivered programs, you can still develop traces by restricting the information you want to log. Also, note that only those files that you desire to trace need be compiled with -g.</P>
 
<P> If you simply wish to log parameter values on function entry, you can build the probes to do this against a debug version of your program and they will probably work against an optimized, non-debug version of the program. However, inlining of function calls may eliminate some or all points at which the probes would be executed.</P>
 
<P> If you simply wish to log parameter values on function entry, you can build the probes to do this against a debug version of your program and they will probably work against an optimized, non-debug version of the program. However, inlining of function calls may eliminate some or all points at which the probes would be executed.</P>
 
<P> Regardless of how you build your application, you can generally get to data within it by generating custom probes that don't require debug information. </P>
 
<P> Regardless of how you build your application, you can generally get to data within it by generating custom probes that don't require debug information. </P>
<P> Please contact <A HREF="mailto:support@ocsystems.com">support@ocsystems.com</A> with any questions you have. We feel confident you can get the trace you want without greatly altering your development practices or sacrificing performance in your production environment.</P>
+
<P> Please contact [["mailto:support@ocsystems.com">support@ocsystems.com</DIV> with any questions you have. We feel confident you can get the trace you want without greatly altering your development practices or sacrificing performance in your production environment.</P>
<A NAME=HEADING9-22></A>
+
<DIV ID=HEADING9-22></DIV>
<A NAME="UID-06deploy_rc.fm-949699"></A>
+
<DIV ID="UID-06deploy_rc.fm-949699"></DIV>
<H2> <A NAME=MARKER-9-887></A>Deploying A RootCause Workspace</H2>
+
<H2> <DIV ID=MARKER-9-887></DIV>Deploying A RootCause Workspace</H2>
<P> When you have built and tested the traces and probes, and you want to apply them to an application that exists at (or will be shipped to) a remote site, you are ready to deploy the workspace containing those traces and probes. This workspace will be your "<A NAME=MARKER-2-888></A>flight recorder" for the application at the remote site. To generate the deploy (<A NAME=MARKER-2-889></A>.dply) file:</P>
+
<P> When you have built and tested the traces and probes, and you want to apply them to an application that exists at (or will be shipped to) a remote site, you are ready to deploy the workspace containing those traces and probes. This workspace will be your "<DIV ID=MARKER-2-888></DIV>flight recorder" for the application at the remote site. To generate the deploy (<DIV ID=MARKER-2-889></DIV>.dply) file:</P>
 
<OL>
 
<OL>
<LI><P>Confirm that you're developing and testing with the same build of the application you'll be shipping. See <A HREF="#MARKER-9-880">"Building a "Traceable" Application"</A>.</P>
+
<LI><P>Confirm that you're developing and testing with the same build of the application you'll be shipping. See [["#MARKER-9-880">"Building a "Traceable" Application"</DIV>.</P>
 
<LI><P>Develop and test your traces locally. When you see the information you think you'll need at the remote site, then you're ready to deploy.</P>
 
<LI><P>Develop and test your traces locally. When you see the information you think you'll need at the remote site, then you're ready to deploy.</P>
<LI><P>Enable the <A HREF="rcc-11.html#MARKER-9-1347">verify</A> predefined UAL in the <EM><A HREF="rcc-11.html#MARKER-9-1321">Workspace Browser</A></EM> window.  This checks the correspondence between the program and modules on the remote system with those in the local (formatting) environment, and alerts the user when an incompatibility is detected.</P>
+
<LI><P>Enable the [["rcc-11.html#MARKER-9-1347">verify</DIV> predefined UAL in the <EM>[["rcc-11.html#MARKER-9-1321">Workspace Browser</DIV></EM> window.  This checks the correspondence between the program and modules on the remote system with those in the local (formatting) environment, and alerts the user when an incompatibility is detected.</P>
<LI><P>Click on the <EM><A HREF="rcc-11.html#MARKER-9-1429">Deploy</A></EM> button in the main <EM><A HREF="rcc-11.html#MARKER-9-1321">Workspace Browser</A></EM> window. This will display the <EM><A HREF="rcc-11.html#MARKER-9-1520">Deploy Dialog</A></EM>.</P>
+
<LI><P>Click on the <EM>[["rcc-11.html#MARKER-9-1429">Deploy</DIV></EM> button in the main <EM>[["rcc-11.html#MARKER-9-1321">Workspace Browser</DIV></EM> window. This will display the <EM>[["rcc-11.html#MARKER-9-1520">Deploy Dialog</DIV></EM>.</P>
<LI><P>In the <A NAME=MARKER-2-890></A>Deploy Dialog, enter a file name for your deploy file. This file will be created by RootCause, and it will contain the trace definitions for your current workspace. </P>
+
<LI><P>In the <DIV ID=MARKER-2-890></DIV>Deploy Dialog, enter a file name for your deploy file. This file will be created by RootCause, and it will contain the trace definitions for your current workspace. </P>
 
<LI><P>Click the <EM>ADI Files</EM> tab in the dialog.</P>
 
<LI><P>Click the <EM>ADI Files</EM> tab in the dialog.</P>
<P> In the ADI files tab, you may specify which, if any, of the <A HREF="rcc-6.html#MARKER-9-440">module</A>s for which you have <A HREF="rcc-6.html#MARKER-9-473">traces</A> and <A HREF="rcc-6.html#MARKER-9-447">probes</A> have been <A HREF="rcc-6.html#MARKER-9-468">stripped</A> of symbol information. RootCause will generate an <A HREF="rcc-6.html#MARKER-9-389">ADI file</A> that contains sufficient symbolic information for the traces and probes to work with the stripped executable at the <A HREF="rcc-6.html#MARKER-9-456">remote</A> site.</P>
+
<P> In the ADI files tab, you may specify which, if any, of the [["rcc-6.html#MARKER-9-440">module</DIV>s for which you have [["rcc-6.html#MARKER-9-473">traces</DIV> and [["rcc-6.html#MARKER-9-447">probes</DIV> have been [["rcc-6.html#MARKER-9-468">stripped</DIV> of symbol information. RootCause will generate an [["rcc-6.html#MARKER-9-389">ADI file</DIV> that contains sufficient symbolic information for the traces and probes to work with the stripped executable at the [["rcc-6.html#MARKER-9-456">remote</DIV> site.</P>
 
<P>Do not generate ADI for any of the system-provided modules and shared libraries; only modules and libraries that you have explicitly stripped. If you have not explicitly stripped an executable or library, then you do not need to generate any ADI files for them.</P>
 
<P>Do not generate ADI for any of the system-provided modules and shared libraries; only modules and libraries that you have explicitly stripped. If you have not explicitly stripped an executable or library, then you do not need to generate any ADI files for them.</P>
<LI><P>In the Deploy window, click "OK". RootCause will attempt to create the <A NAME=MARKER-2-891></A><CODE>dply</CODE> file.  For example, if you're using the pi_demo.aws workspace created in <A HREF="rcc-8.html#MARKER-9-707">Chapter 5, &quot;RootCause Demo&quot;</A>, then this will create <CODE>pi_demo.<A NAME=MARKER-10-892></A>dply</CODE>.</P>
+
<LI><P>In the Deploy window, click "OK". RootCause will attempt to create the <DIV ID=MARKER-2-891></DIV><CODE>dply</CODE> file.  For example, if you're using the pi_demo.aws workspace created in [["rcc-8.html#MARKER-9-707">Chapter 5, &quot;RootCause Demo&quot;</DIV>, then this will create <CODE>pi_demo.<DIV ID=MARKER-10-892></DIV>dply</CODE>.</P>
<P>The <CODE>.dply</CODE> file will also contain the <A NAME=MARKER-2-893></A>license needed to run RootCause on the remote computer. When the <CODE>.dply </CODE>file is created, the file<BR><CODE>$APROBE/<A NAME=MARKER-10-894></A>licenses/<A NAME=MARKER-10-895></A><A NAME=MARKER-2-896></A>agent_license.dat</CODE> mentioned in<BR>see <A HREF="#MARKER-9-874">"Installing The RootCause Agent"</A> is automatically included.  If the license file is not found, or does not contain a license, an error dialog will appear.  If you see this, you can click "Yes" to proceed with deploying, or "No" if you wish to investigate getting a valid Agent license.</P>
+
<P>The <CODE>.dply</CODE> file will also contain the <DIV ID=MARKER-2-893></DIV>license needed to run RootCause on the remote computer. When the <CODE>.dply </CODE>file is created, the file<BR><CODE>$APROBE/<DIV ID=MARKER-10-894></DIV>licenses/<DIV ID=MARKER-10-895></DIV><DIV ID=MARKER-2-896></DIV>agent_license.dat</CODE> mentioned in<BR>see [["#MARKER-9-874">"Installing The RootCause Agent"</DIV> is automatically included.  If the license file is not found, or does not contain a license, an error dialog will appear.  If you see this, you can click "Yes" to proceed with deploying, or "No" if you wish to investigate getting a valid Agent license.</P>
<LI><P>Transfer the <CODE>.dply </CODE>file over to the remote computer (be sure to specify binary mode if you use <A NAME=MARKER-2-897></A>ftp).</P>
+
<LI><P>Transfer the <CODE>.dply </CODE>file over to the remote computer (be sure to specify binary mode if you use <DIV ID=MARKER-2-897></DIV>ftp).</P>
 
</OL>
 
</OL>
<A NAME=HEADING9-35></A>
+
<DIV ID=HEADING9-35></DIV>
<A NAME="UID-06deploy_rc.fm-949712"></A>
+
<DIV ID="UID-06deploy_rc.fm-949712"></DIV>
 
<H2> Registering a Deployed Workspace</H2>
 
<H2> Registering a Deployed Workspace</H2>
 
<OL>
 
<OL>
<LI><P>On the <A HREF="rcc-6.html#MARKER-9-456">remote</A> computer open an xterm or other command shell<A NAME=MARKER-10-898></A>.</P>
+
<LI><P>On the [["rcc-6.html#MARKER-9-456">remote</DIV> computer open an xterm or other command shell<DIV ID=MARKER-10-898></DIV>.</P>
<LI><P> Register the application on the remote computer using the <A HREF="rcc-12.html#MARKER-9-2107">rootcause register</A> command.  For example:</P>
+
<LI><P> Register the application on the remote computer using the [["rcc-12.html#MARKER-9-2107">rootcause register</DIV> command.  For example:</P>
<A NAME=MARKER-10-899></A>rootcause register pi_demo.dply
+
<DIV ID=MARKER-10-899></DIV>rootcause register pi_demo.dply
<P><A NAME=MARKER-10-900></A>This creates a workspace in the current directory (or a path specified with the <CODE>-w</CODE> option) and registers the workspace with the <A NAME=MARKER-10-901></A>application at the same path as on the Console side.  If the application is at a different path, the new (local) path must be specified with the -x option before the deploy file name.  Similarly, each <A HREF="rcc-6.html#MARKER-9-416">dynamic module</A> that is at a differen tlocation from where it was when deployed must be specified with a -m option.  For example:</P>
+
<P><DIV ID=MARKER-10-900></DIV>This creates a workspace in the current directory (or a path specified with the <CODE>-w</CODE> option) and registers the workspace with the <DIV ID=MARKER-10-901></DIV>application at the same path as on the Console side.  If the application is at a different path, the new (local) path must be specified with the -x option before the deploy file name.  Similarly, each [["rcc-6.html#MARKER-9-416">dynamic module</DIV> that is at a differen tlocation from where it was when deployed must be specified with a -m option.  For example:</P>
<A NAME=MARKER-10-902></A>rootcause register <BR> -x /opt/demos/bin/pi_demo.exe <BR> -m /opt/demos/lib/libpi.so <BR> pi_demo.dply
+
<DIV ID=MARKER-10-902></DIV>rootcause register <BR> -x /opt/demos/bin/pi_demo.exe <BR> -m /opt/demos/lib/libpi.so <BR> pi_demo.dply
<LI><P>Enable RootCause on the remote computer in the environment where the application will be run, using the <CODE><A NAME=MARKER-2-903></A><A HREF="rcc-12.html#MARKER-9-2094">rootcause_on</A></CODE> command. Note that this needs to be done in a parent process of the shell that will run the application(s) so that the application(s) will inherit the value of the environment variables it sets.</P>
+
<LI><P>Enable RootCause on the remote computer in the environment where the application will be run, using the <CODE><DIV ID=MARKER-2-903></DIV>[["rcc-12.html#MARKER-9-2094">rootcause_on</DIV></CODE> command. Note that this needs to be done in a parent process of the shell that will run the application(s) so that the application(s) will inherit the value of the environment variables it sets.</P>
 
</OL>
 
</OL>
<A NAME=HEADING9-42></A>
+
<DIV ID=HEADING9-42></DIV>
<A NAME="UID-06deploy_rc.fm-949713"></A>
+
<DIV ID="UID-06deploy_rc.fm-949713"></DIV>
 
<H2> Collecting Data At The Remote Site</H2>
 
<H2> Collecting Data At The Remote Site</H2>
 
<OL>
 
<OL>
 
<LI><P>Run the application(s) as you normally would.</P>
 
<LI><P>Run the application(s) as you normally would.</P>
<LI><P>When you want to <A HREF="rcc-6.html#MARKER-9-404">collect</A> and examine the RootCause trace data, execute the <CODE><A NAME=MARKER-2-904></A><A HREF="rcc-12.html#MARKER-9-2027">rootcause collect</A></CODE> command on the remote computer. For example:</P>
+
<LI><P>When you want to [["rcc-6.html#MARKER-9-404">collect</DIV> and examine the RootCause trace data, execute the <CODE><DIV ID=MARKER-2-904></DIV>[["rcc-12.html#MARKER-9-2027">rootcause collect</DIV></CODE> command on the remote computer. For example:</P>
 
rootcause collect -x $APROBE/demo/RootCause/C++/pi_demo
 
rootcause collect -x $APROBE/demo/RootCause/C++/pi_demo
<P><A NAME=MARKER-10-905></A><A NAME=MARKER-10-906></A>Many <A NAME=MARKER-10-907></A>executables may be collected at once by listing them on the collect command line. The applicable files in each registered workspace will be compressed into a single <CODE>.clct</CODE> file.</P>
+
<P><DIV ID=MARKER-10-905></DIV><DIV ID=MARKER-10-906></DIV>Many <DIV ID=MARKER-10-907></DIV>executables may be collected at once by listing them on the collect command line. The applicable files in each registered workspace will be compressed into a single <CODE>.clct</CODE> file.</P>
 
</OL>
 
</OL>
<A NAME=HEADING9-47></A>
+
<DIV ID=HEADING9-47></DIV>
<A NAME="UID-06deploy_rc.fm-949717"></A>
+
<DIV ID="UID-06deploy_rc.fm-949717"></DIV>
 
<H2> Formatting and Viewing the Remotely-Collected Data</H2>
 
<H2> Formatting and Viewing the Remotely-Collected Data</H2>
 
<OL>
 
<OL>
<LI><P>Transfer the <A NAME=MARKER-2-908></A><CODE>.clct</CODE> file back to the local computer where the RootCause <A HREF="rcc-6.html#MARKER-9-406">Console</A> is installed (be sure to specify binary mode if you use <A NAME=MARKER-2-909></A>ftp).</P>
+
<LI><P>Transfer the <DIV ID=MARKER-2-908></DIV><CODE>.clct</CODE> file back to the local computer where the RootCause [["rcc-6.html#MARKER-9-406">Console</DIV> is installed (be sure to specify binary mode if you use <DIV ID=MARKER-2-909></DIV>ftp).</P>
<LI><P>In the RootCause GUI, click on the <EM><A HREF="rcc-11.html#MARKER-9-1430">Decollect</A></EM> button in the main window.  This will display the <EM><A HREF="rcc-11.html#MARKER-9-1528">Decollect Data Dialog</A></EM>. If the RootCause GUI is not currently running, you may open the collect file when starting the GUI, for example:</P>
+
<LI><P>In the RootCause GUI, click on the <EM>[["rcc-11.html#MARKER-9-1430">Decollect</DIV></EM> button in the main window.  This will display the <EM>[["rcc-11.html#MARKER-9-1528">Decollect Data Dialog</DIV></EM>. If the RootCause GUI is not currently running, you may open the collect file when starting the GUI, for example:</P>
<CODE><A HREF="rcc-12.html#MARKER-9-2101">rootcause open</A></CODE> file.clct
+
<CODE>[["rcc-12.html#MARKER-9-2101">rootcause open</DIV></CODE> file.clct
<LI><P>In the <EM><A HREF="rcc-11.html#MARKER-9-1528">Decollect Data Dialog</A></EM>, enter the name of the <CODE>.clct</CODE> file and the destination directory into which the file will be expanded. The destination directory should be empty as the <A HREF="rcc-6.html#MARKER-9-410">decollect</A> operation will expand a number of files into this directory. Then click "OK". </P>
+
<LI><P>In the <EM>[["rcc-11.html#MARKER-9-1528">Decollect Data Dialog</DIV></EM>, enter the name of the <CODE>.clct</CODE> file and the destination directory into which the file will be expanded. The destination directory should be empty as the [["rcc-6.html#MARKER-9-410">decollect</DIV> operation will expand a number of files into this directory. Then click "OK". </P>
<P>This will create a <A HREF="rcc-6.html#MARKER-9-413">decollection</A>, a directory, with suffix <CODE><A NAME=MARKER-2-910></A>.dclct</CODE>, containing the workspaces collected from the remote computer.  It will then proceed with the <A HREF="rcc-11.html#MARKER-9-1370">Open Decollection</A> operation, which will show a <A HREF="rcc-11.html#MARKER-9-1680">Trace Index Dialog</A> for the newest data in the decollection.</P>
+
<P>This will create a [["rcc-6.html#MARKER-9-413">decollection</DIV>, a directory, with suffix <CODE><DIV ID=MARKER-2-910></DIV>.dclct</CODE>, containing the workspaces collected from the remote computer.  It will then proceed with the [["rcc-11.html#MARKER-9-1370">Open Decollection</DIV> operation, which will show a [["rcc-11.html#MARKER-9-1680">Trace Index Dialog</DIV> for the newest data in the decollection.</P>
<LI><P>Select the event(s) you wish to view, or use <A HREF="rcc-11.html#MARKER-9-1697">Select Data Files</A> to change the data that was indexed.</P>
+
<LI><P>Select the event(s) you wish to view, or use [["rcc-11.html#MARKER-9-1697">Select Data Files</DIV> to change the data that was indexed.</P>
<LI><P>Format the data into a Trace Display.  If you used the <A NAME=MARKER-2-911></A><A HREF="rcc-11.html#MARKER-9-1347">verify</A> <A NAME=MARKER-10-912></A>predefined UAL as suggested in <A HREF="#MARKER-9-887">&quot;Deploying A RootCause Workspace&quot;</A>, you'll see a TEXT node identifying any mismatches that may cause formatting problems.</P>
+
<LI><P>Format the data into a Trace Display.  If you used the <DIV ID=MARKER-2-911></DIV>[["rcc-11.html#MARKER-9-1347">verify</DIV> <DIV ID=MARKER-10-912></DIV>predefined UAL as suggested in [["#MARKER-9-887">&quot;Deploying A RootCause Workspace&quot;</DIV>, you'll see a TEXT node identifying any mismatches that may cause formatting problems.</P>
<LI><P>From the Trace Display for the decollected data, you can use <A HREF="rcc-11.html#MARKER-9-1734">Add Data Files To Display</A> to add in the Decollected <A NAME=MARKER-2-913></A>RootCause Log file and other data.</P>
+
<LI><P>From the Trace Display for the decollected data, you can use [["rcc-11.html#MARKER-9-1734">Add Data Files To Display</DIV> to add in the Decollected <DIV ID=MARKER-2-913></DIV>RootCause Log file and other data.</P>
<A NAME="LINK-06deploy_rc.fm-lastpage"></A></OL>
+
<DIV ID="LINK-06deploy_rc.fm-lastpage"></DIV></OL>
  
 
</DIV>
 
</DIV>
Line 114: Line 97:
 
<DIV>
 
<DIV>
 
<HR>
 
<HR>
<P><A HREF=rcc-10.html>[Next]</A> <A HREF=rcc-8.html>[Previous]</A> <A HREF=rcc-1.html>[Top]</A> <A HREF=rcc-3.html>[Contents]</A> <A HREF=rcc-14.html>[Index]</A></P>
+
<P>[[rcc-10.html>[Next]</DIV> [[rcc-8.html>[Previous]</DIV> [[rcc-1.html>[Top]</DIV> [[rcc-3.html>[Contents]</DIV> [[rcc-14.html>[Index]</DIV></P>
 
<P></P>
 
<P></P>
 
<ADDRESS>Copyright 2006  OC Systems, Inc.</ADDRESS>
 
<ADDRESS>Copyright 2006  OC Systems, Inc.</ADDRESS>

Revision as of 05:06, 15 September 2017


Next Previous Index Top

RootCause User Guide


Deploying the RootCause Workspace



RootCause performs root cause analysis of problems at the user's site, in the production system. This chapter discusses how to run traces on a remote computer.

Installing The RootCause Agent

RootCause has two components: the RootCause Console and the RootCause Agent. The Agent is the subset of RootCause that is used to run RootCause traces on a remote computer. The Console is the full product that allows one to define and view traces as well as run them (that is, the Console also includes the Agent).

If you're just "trying out" the deploy process on a single computer, your Console installation can also serve as the remote installation. If you really are deploying RootCause to a remote site you will want to install just the RootCause Agent subset there, and enable remote execution using RootCause agent licenses.

Follow the installation directions in [["rcc-5.html#MARKER-9-251">"RootCause Agent Installation" to install the RootCause Agent on the remote computer; this only needs to be done once per remote computer.

After this is installed on the remote computer, you deploy RootCause trace definitions to the remote RootCause Agent and get back files that contain the logged trace data.

The Agent installation does not have its own license--the license is delivered with the deployed probes. Instead, you will obtain one or more agent license keys from OC Systems and append them to the file

<CODE>$<DIV ID=MARKER-10-876></DIV>APROBE<DIV ID=MARKER-10-877></DIV>/<DIV ID=MARKER-10-878></DIV>licenses/<DIV ID=MARKER-10-879></DIV>agent_license.dat</CODE>

in your RootCause Console installation. Agent licenses will be automatically copied into the deployed workspace (see [["#MARKER-9-887">"Deploying A RootCause Workspace"). See [["rcc-5.html#MARKER-9-259">"Licensing" for a more in-depth discussion on licensing issues.

Building a "Traceable" Application

Production systems often have their applications stripped of debug and symbol information to save space and increase security. The program runs fine in the field without this information. However, meaningful tracing information cannot be obtained without this debug and symbol information.

RootCause solves this problem by allowing one to define the trace on a version of the application that contains debug and symbol information and then to run that trace against a version of the same application

from which this debug information has been removed by the "strip" command. RootCause will "remember" the necessary debug and symbol information for the [["rcc-6.html#MARKER-9-468">stripped application.

The presence or absence of debug and symbol information should be the only difference between the development and production versions. You should define your traces based on the exact same object code on which the traces will be run. This is a requirement if you wish to trace source lines or access local data values. So, to be assured of reliable traces regardless of what you select, you must develop your traces against the program you will be shipping,

and then strip (using a "strip" command) the executable files prior to distribution. RootCause has been designed so that you can define your traces on the application in which debug information is available, and then run that application under RootCause either with or without that information present in the execution environment.

When you perform the RootCause deploy operation (see [["#MARKER-9-887">"Deploying A RootCause Workspace") to create the packaged workspace for use in the production environment, you check the module(s) that will be stripped in the remote environment. RootCause collects the necessary information for the trace from the local non-stripped module and writes it to an ADI file. The ADI file is then automatically and invisibly included in the deployed RootCause workspace. The deployed workspace now contains sufficient symbolic information to allow RootCause to run on the stripped application in the production environment.

RootCause ADI files carry the symbolic information necessary to perform RootCause traces, so that information may be stripped from the executables themselves. But there remains the issue of how to develop useful traces on an application built for delivery: must you change your build process in order to accommodate RootCause? In some cases, yes.

If you simply wish to trace the functions executed by your program, you do not need debug information; all you need is symbols, which are generally present until you perform a strip command. So, for example, the initial tracing of the "pi_demo" program from [["rcc-8.html#MARKER-9-707">Chapter 5, "RootCause Demo" would work fine even if the program were compiled with optimize and with no debug information.

If you wish to select parameters and data values as part of your trace, the executable or shared module in which the log operation is taking place must be compiled with a debug (-g) flag. If you usually build your application with optimize (-O) and other flags that affect the generated code (e.g., -DNDEBUG) then you must do this on the version to be traced.

Note that specifying -g with -O may reduce the effect of optimization, but this compromise is necessary in order to have access to accurate source-level information with which to develop your traces. However, if you cannot use -g on your delivered programs, you can still develop traces by restricting the information you want to log. Also, note that only those files that you desire to trace need be compiled with -g.

If you simply wish to log parameter values on function entry, you can build the probes to do this against a debug version of your program and they will probably work against an optimized, non-debug version of the program. However, inlining of function calls may eliminate some or all points at which the probes would be executed.

Regardless of how you build your application, you can generally get to data within it by generating custom probes that don't require debug information.

Please contact [["mailto:support@ocsystems.com">support@ocsystems.com with any questions you have. We feel confident you can get the trace you want without greatly altering your development practices or sacrificing performance in your production environment.

Deploying A RootCause Workspace

When you have built and tested the traces and probes, and you want to apply them to an application that exists at (or will be shipped to) a remote site, you are ready to deploy the workspace containing those traces and probes. This workspace will be your "

flight recorder" for the application at the remote site. To generate the deploy (

.dply) file:

  1. Confirm that you're developing and testing with the same build of the application you'll be shipping. See [["#MARKER-9-880">"Building a "Traceable" Application".

  2. Develop and test your traces locally. When you see the information you think you'll need at the remote site, then you're ready to deploy.

  3. Enable the [["rcc-11.html#MARKER-9-1347">verify predefined UAL in the [["rcc-11.html#MARKER-9-1321">Workspace Browser window. This checks the correspondence between the program and modules on the remote system with those in the local (formatting) environment, and alerts the user when an incompatibility is detected.

  4. Click on the [["rcc-11.html#MARKER-9-1429">Deploy button in the main [["rcc-11.html#MARKER-9-1321">Workspace Browser window. This will display the [["rcc-11.html#MARKER-9-1520">Deploy Dialog.

  5. In the

    Deploy Dialog, enter a file name for your deploy file. This file will be created by RootCause, and it will contain the trace definitions for your current workspace.

  6. Click the ADI Files tab in the dialog.

    In the ADI files tab, you may specify which, if any, of the [["rcc-6.html#MARKER-9-440">modules for which you have [["rcc-6.html#MARKER-9-473">traces and [["rcc-6.html#MARKER-9-447">probes have been [["rcc-6.html#MARKER-9-468">stripped of symbol information. RootCause will generate an [["rcc-6.html#MARKER-9-389">ADI file that contains sufficient symbolic information for the traces and probes to work with the stripped executable at the [["rcc-6.html#MARKER-9-456">remote site.

    Do not generate ADI for any of the system-provided modules and shared libraries; only modules and libraries that you have explicitly stripped. If you have not explicitly stripped an executable or library, then you do not need to generate any ADI files for them.

  7. In the Deploy window, click "OK". RootCause will attempt to create the

    dply file. For example, if you're using the pi_demo.aws workspace created in [["rcc-8.html#MARKER-9-707">Chapter 5, "RootCause Demo", then this will create pi_demo.
    dply
    .

    The .dply file will also contain the

    license needed to run RootCause on the remote computer. When the .dply file is created, the file
    $APROBE/
    licenses/
    agent_license.dat
    mentioned in
    see [["#MARKER-9-874">"Installing The RootCause Agent" is automatically included. If the license file is not found, or does not contain a license, an error dialog will appear. If you see this, you can click "Yes" to proceed with deploying, or "No" if you wish to investigate getting a valid Agent license.

  8. Transfer the .dply file over to the remote computer (be sure to specify binary mode if you use

    ftp).

Registering a Deployed Workspace

  1. On the [["rcc-6.html#MARKER-9-456">remote computer open an xterm or other command shell

    .

  2. Register the application on the remote computer using the [["rcc-12.html#MARKER-9-2107">rootcause register command. For example:

    rootcause register pi_demo.dply

    This creates a workspace in the current directory (or a path specified with the -w option) and registers the workspace with the
    application at the same path as on the Console side. If the application is at a different path, the new (local) path must be specified with the -x option before the deploy file name. Similarly, each [["rcc-6.html#MARKER-9-416">dynamic module that is at a differen tlocation from where it was when deployed must be specified with a -m option. For example:

    rootcause register
    -x /opt/demos/bin/pi_demo.exe
    -m /opt/demos/lib/libpi.so
    pi_demo.dply
  3. Enable RootCause on the remote computer in the environment where the application will be run, using the

    [["rcc-12.html#MARKER-9-2094">rootcause_on command. Note that this needs to be done in a parent process of the shell that will run the application(s) so that the application(s) will inherit the value of the environment variables it sets.

Collecting Data At The Remote Site

  1. Run the application(s) as you normally would.

  2. When you want to [["rcc-6.html#MARKER-9-404">collect and examine the RootCause trace data, execute the

    [["rcc-12.html#MARKER-9-2027">rootcause collect command on the remote computer. For example:

    rootcause collect -x $APROBE/demo/RootCause/C++/pi_demo

    Many
    executables may be collected at once by listing them on the collect command line. The applicable files in each registered workspace will be compressed into a single .clct file.

Formatting and Viewing the Remotely-Collected Data

  1. Transfer the

    .clct file back to the local computer where the RootCause [["rcc-6.html#MARKER-9-406">Console is installed (be sure to specify binary mode if you use
    ftp).

  2. In the RootCause GUI, click on the [["rcc-11.html#MARKER-9-1430">Decollect button in the main window. This will display the [["rcc-11.html#MARKER-9-1528">Decollect Data Dialog. If the RootCause GUI is not currently running, you may open the collect file when starting the GUI, for example:

    [["rcc-12.html#MARKER-9-2101">rootcause open file.clct
  3. In the [["rcc-11.html#MARKER-9-1528">Decollect Data Dialog, enter the name of the .clct file and the destination directory into which the file will be expanded. The destination directory should be empty as the [["rcc-6.html#MARKER-9-410">decollect operation will expand a number of files into this directory. Then click "OK".

    This will create a [["rcc-6.html#MARKER-9-413">decollection, a directory, with suffix

    .dclct, containing the workspaces collected from the remote computer. It will then proceed with the [["rcc-11.html#MARKER-9-1370">Open Decollection operation, which will show a [["rcc-11.html#MARKER-9-1680">Trace Index Dialog for the newest data in the decollection.

  4. Select the event(s) you wish to view, or use [["rcc-11.html#MARKER-9-1697">Select Data Files to change the data that was indexed.

  5. Format the data into a Trace Display. If you used the

    [["rcc-11.html#MARKER-9-1347">verify
    predefined UAL as suggested in [["#MARKER-9-887">"Deploying A RootCause Workspace", you'll see a TEXT node identifying any mismatches that may cause formatting problems.

  6. From the Trace Display for the decollected data, you can use [["rcc-11.html#MARKER-9-1734">Add Data Files To Display to add in the Decollected

    RootCause Log file and other data.


[[rcc-10.html>[Next]

[[rcc-8.html>[Previous] [[rcc-1.html>[Top] [[rcc-3.html>[Contents] [[rcc-14.html>[Index]

<ADDRESS>Copyright 2006 OC Systems, Inc.</ADDRESS>




Copyright 2006-2017 OC Systems, Inc.

Next Previous Index Top