ibm-information-center/dist/eclipse/plugins/i5OS.ic.rbam6_5.4.0.1/debugrun.htm

86 lines
5.0 KiB
HTML
Raw Permalink Normal View History

2024-04-02 14:02:31 +00:00
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="security" content="public" />
<meta name="Robots" content="index,follow" />
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
<meta name="DC.Type" content="task" />
<meta name="DC.Title" content="Debug a running job" />
<meta name="abstract" content="You can debug a job that is already running if you know what statements the job will run." />
<meta name="description" content="You can debug a job that is already running if you know what statements the job will run." />
<meta name="DC.subject" content="debugging, running job" />
<meta name="keywords" content="debugging, running job" />
<meta name="DC.Relation" scheme="URI" content="usejobdg.htm" />
<meta name="DC.Relation" scheme="URI" content="../cl/dspdbg.htm" />
<meta name="DC.Relation" scheme="URI" content="../cl/dsptrcdta.htm" />
<meta name="DC.Relation" scheme="URI" content="../cl/addbkp.htm" />
<meta name="DC.Relation" scheme="URI" content="../cl/addtrc.htm" />
<meta name="DC.Relation" scheme="URI" content="../clfinder/finder.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="debugrun" />
<meta name="DC.Language" content="en-us" />
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
<link rel="stylesheet" type="text/css" href="./ic.css" />
<title>Debug a running job</title>
</head>
<body id="debugrun"><a name="debugrun"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Debug a running job</h1>
<div><p>You can debug a job that is already running if you know what statements
the job will run.</p>
<div class="section"> <p> For example, you may want to debug a running program if the
job is looping or the job has not yet run a program that is to be debugged.
The following steps allow you to debug a running job: </p>
<ol><li>Use the <span class="cmdname">Work with Active Jobs (WRKACTJOB)</span> command to
find the job that is running. When the display appears, enter option 5 next
to the job to obtain the qualified job name.</li>
<li>Enter the <span class="cmdname">Start Service Job (STRSRVJOB)</span> command as
follows: <pre>STRSRVJOB JOB(qualified-job-name)</pre>
</li>
<li>Enter the <span class="cmdname">Start Debug (STRDBG)</span> command. (Entering the
command does not stop the job from running.) <div class="note"><span class="notetitle">Note:</span> You can use the <span class="cmdname">Display
Debug (DSPDBG)</span> command to show the call stack. However, unless the
program is stopped for some reason, the stack is correct only for an instant,
and the program continues to run.</div>
</li>
<li>If you know a statement to be run, enter the <span class="cmdname">Add Breakpoint (ADDBKP)</span> command
to stop the job at the statement. <p>If you do not know what statements are
being run, do the following: </p>
<ol type="a"><li>Enter the <span class="cmdname">Add Trace (ADDTRC)</span> command.</li>
<li>After a short time, enter the <span class="cmdname">Remove Trace (RMVTRC)</span> command
to stop tracing the program.</li>
<li>Enter the <span class="cmdname">Display Trace Data (DSPTRCDTA)</span> command to
show what statements have processed. Use the trace data to determine which
data statements to process next (for example, statements inside a program
loop).</li>
<li>Enter the <span class="cmdname">Add Breakpoint (ADDBKP)</span> command to stop the
job at the statement.</li>
</ol>
</li>
<li>Enter the desired debug commands when the program is stopped at a breakpoint.</li>
</ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="usejobdg.htm" title="You may want to use a separate job to debug programs running in another job.">Use a job to debug another job</a></div>
</div>
<div class="relinfo"><strong>Related information</strong><br />
<div><a href="../cl/dspdbg.htm">Display Debug (DSPDBG) command</a></div>
<div><a href="../cl/dsptrcdta.htm">Display Trace Data (DSPTRCDTA) command</a></div>
<div><a href="../cl/addbkp.htm">Add Breakpoint (ADDBKP) command</a></div>
<div><a href="../cl/addtrc.htm">Add Trace (ADDTRC) command</a></div>
<div><a href="../clfinder/finder.htm">CL command finder</a></div>
</div>
</div>
</body>
</html>