<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Script help in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602997#M104183</link>
    <description>Completed: drop rollback segment RB31&lt;BR /&gt;Fri Aug 12 05:34:56 2005&lt;BR /&gt;drop rollback segment RB32&lt;BR /&gt;Completed: drop rollback segment RB32&lt;BR /&gt;Fri Aug 12 05:36:08 2005&lt;BR /&gt;drop tablespace RBS&lt;BR /&gt;Fri Aug 12 05:36:36 2005&lt;BR /&gt;Errors in file /oracle/admin/COREPROD/bdump/coreprod_j002_7027.trc:&lt;BR /&gt;ORA-12012: error on auto execute of job 137728&lt;BR /&gt;ORA-01405: fetched column value is NULL&lt;BR /&gt;ORA-06512: at "SYS.DBMS_AQADM_SYS", line 5636&lt;BR /&gt;ORA-06512: at "SYS.DBMS_AQADM_SYS", line 6061&lt;BR /&gt;ORA-06512: at "SYS.DBMS_AQADM", line 895&lt;BR /&gt;ORA-06512: at line 1&lt;BR /&gt;Fri Aug 12 05:36:36 2005&lt;BR /&gt;Errors in file /oracle/admin/COREPROD/bdump/coreprod_j001_7025.trc:&lt;BR /&gt;&lt;BR /&gt;Here are errors pasted. &lt;BR /&gt;While these errors can be many in file, if provision can be made to see from recent dates of 2-3 days will be great. &lt;BR /&gt;Thanks&lt;BR /&gt;Prashant</description>
    <pubDate>Fri, 12 Aug 2005 16:00:17 GMT</pubDate>
    <dc:creator>Prashant Zanwar_4</dc:creator>
    <dc:date>2005-08-12T16:00:17Z</dc:date>
    <item>
      <title>Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602993#M104179</link>
      <description>Hi, &lt;BR /&gt;I want a script which will get for a pattern, and depending on Line number pattern, will display 4Lines above the line and 4Line Below that line. I am finding it challening! &lt;BR /&gt;Thanks in advance&lt;BR /&gt;Prashant</description>
      <pubDate>Fri, 12 Aug 2005 15:34:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602993#M104179</guid>
      <dc:creator>Prashant Zanwar_4</dc:creator>
      <dc:date>2005-08-12T15:34:35Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602994#M104180</link>
      <description>&lt;BR /&gt;Prashant,&lt;BR /&gt;&lt;BR /&gt;Could you send an example of input and what you would like to see on output?  How big is the input data file (under 2GB?)  I'm thinking awk can do this using arrays.  But I'd like an example so that it is clear what we are trying to do.  Thanks!&lt;BR /&gt;&lt;BR /&gt;-- Tom</description>
      <pubDate>Fri, 12 Aug 2005 15:42:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602994#M104180</guid>
      <dc:creator>Tom Schroll</dc:creator>
      <dc:date>2005-08-12T15:42:26Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602995#M104181</link>
      <description>I am trying to Trace oracle errors, Just want to check for particular ora error, few lines before that and few lines after it. &lt;BR /&gt;Thanks and regards&lt;BR /&gt;Prashant</description>
      <pubDate>Fri, 12 Aug 2005 15:48:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602995#M104181</guid>
      <dc:creator>Prashant Zanwar_4</dc:creator>
      <dc:date>2005-08-12T15:48:15Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602996#M104182</link>
      <description>What would be a good example of the oracle error you are trying to extract from the file. A concrete example will help.&lt;BR /&gt;&lt;BR /&gt;cheers!</description>
      <pubDate>Fri, 12 Aug 2005 15:58:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602996#M104182</guid>
      <dc:creator>Sandman!</dc:creator>
      <dc:date>2005-08-12T15:58:18Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602997#M104183</link>
      <description>Completed: drop rollback segment RB31&lt;BR /&gt;Fri Aug 12 05:34:56 2005&lt;BR /&gt;drop rollback segment RB32&lt;BR /&gt;Completed: drop rollback segment RB32&lt;BR /&gt;Fri Aug 12 05:36:08 2005&lt;BR /&gt;drop tablespace RBS&lt;BR /&gt;Fri Aug 12 05:36:36 2005&lt;BR /&gt;Errors in file /oracle/admin/COREPROD/bdump/coreprod_j002_7027.trc:&lt;BR /&gt;ORA-12012: error on auto execute of job 137728&lt;BR /&gt;ORA-01405: fetched column value is NULL&lt;BR /&gt;ORA-06512: at "SYS.DBMS_AQADM_SYS", line 5636&lt;BR /&gt;ORA-06512: at "SYS.DBMS_AQADM_SYS", line 6061&lt;BR /&gt;ORA-06512: at "SYS.DBMS_AQADM", line 895&lt;BR /&gt;ORA-06512: at line 1&lt;BR /&gt;Fri Aug 12 05:36:36 2005&lt;BR /&gt;Errors in file /oracle/admin/COREPROD/bdump/coreprod_j001_7025.trc:&lt;BR /&gt;&lt;BR /&gt;Here are errors pasted. &lt;BR /&gt;While these errors can be many in file, if provision can be made to see from recent dates of 2-3 days will be great. &lt;BR /&gt;Thanks&lt;BR /&gt;Prashant</description>
      <pubDate>Fri, 12 Aug 2005 16:00:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602997#M104183</guid>
      <dc:creator>Prashant Zanwar_4</dc:creator>
      <dc:date>2005-08-12T16:00:17Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602998#M104184</link>
      <description>FILE=filename.here&lt;BR /&gt;PATTERN="string_here"&lt;BR /&gt;for lineno in `grep -n $PATTERN $FILE|cut -d: -f1`&lt;BR /&gt;do&lt;BR /&gt;(( TOP=$lineno-5 ))&lt;BR /&gt;(( BOT=$lineno+5 ))&lt;BR /&gt;cat $FILE | sed -e "${BOT},\$d" | sed -e "1,${TOP}d"&lt;BR /&gt;echo "=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=" # block separator&lt;BR /&gt;done&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;this should do the trick.. even for multiple instances of the same string repeating in the source file.&lt;BR /&gt;&lt;BR /&gt;HTH</description>
      <pubDate>Fri, 12 Aug 2005 16:02:37 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602998#M104184</guid>
      <dc:creator>Mel Burslan</dc:creator>
      <dc:date>2005-08-12T16:02:37Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602999#M104185</link>
      <description>If you're trying to capture 4-5 lines above/below the "ORA-06512" errors that are popping up in your trace file then a short script like the one below will do what you are interested in accomplishing:&lt;BR /&gt;&lt;BR /&gt;=============================================&lt;BR /&gt;# cat - &amp;lt;&lt;EOF&gt;&lt;/EOF&gt;&amp;gt; /ORA-06512/-4,/ORA-06512/+4 p&lt;BR /&gt;&amp;gt; wq&lt;BR /&gt;&amp;gt; EOF&lt;BR /&gt;=============================================&lt;BR /&gt;&lt;BR /&gt;cheers!!!&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 12 Aug 2005 16:07:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3602999#M104185</guid>
      <dc:creator>Sandman!</dc:creator>
      <dc:date>2005-08-12T16:07:34Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603000#M104186</link>
      <description>Change the "wq" to "q" as you're not writing the output to a file.</description>
      <pubDate>Fri, 12 Aug 2005 16:34:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603000#M104186</guid>
      <dc:creator>Sandman!</dc:creator>
      <dc:date>2005-08-12T16:34:05Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603001#M104187</link>
      <description>Thanks you both, 1st soluion by Mel is working ! &lt;BR /&gt;While I dont find 2nd solution from Sandman not working, basically whole file is scrolling..AM I doing anything wrong. &lt;BR /&gt;Prashant</description>
      <pubDate>Fri, 12 Aug 2005 18:40:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603001#M104187</guid>
      <dc:creator>Prashant Zanwar_4</dc:creator>
      <dc:date>2005-08-12T18:40:18Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603002#M104188</link>
      <description>Prashant,&lt;BR /&gt;&lt;BR /&gt;I tested this code on your trace file and it worked fine. But, I'm not sure why its not working on yours.&lt;BR /&gt;&lt;BR /&gt;Try this one and replace string ORA-6512 with actual pattern you are searching for:&lt;BR /&gt;&lt;BR /&gt;# ex -s &lt;YOUR_FILE_NAME&gt; &amp;lt;&lt;EOF&gt;&lt;/EOF&gt;&amp;gt; /ORA-06512/-4,/ORA-06512/+4 p&lt;BR /&gt;&amp;gt; EOF&lt;/YOUR_FILE_NAME&gt;</description>
      <pubDate>Sat, 13 Aug 2005 11:39:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603002#M104188</guid>
      <dc:creator>Sandman!</dc:creator>
      <dc:date>2005-08-13T11:39:58Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603003#M104189</link>
      <description>Hi, &lt;BR /&gt;&lt;BR /&gt;please try the attached script.&lt;BR /&gt;It should perfectly match your needs.&lt;BR /&gt;Docu and help is included.&lt;BR /&gt;&lt;BR /&gt;Max&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 17 Aug 2005 12:39:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603003#M104189</guid>
      <dc:creator>Max Kublin</dc:creator>
      <dc:date>2005-08-17T12:39:21Z</dc:date>
    </item>
    <item>
      <title>Re: Script help</title>
      <link>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603004#M104190</link>
      <description>.. on a side note .. Have you thought of installing GNU's 'grep' ?  It has the -A, -B and -C flags, for lines-after, lines-before, and lines-before-and-after..&lt;BR /&gt;&lt;BR /&gt;unf.. ;)</description>
      <pubDate>Thu, 18 Aug 2005 08:21:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/script-help/m-p/3603004#M104190</guid>
      <dc:creator>Stuart Browne</dc:creator>
      <dc:date>2005-08-18T08:21:42Z</dc:date>
    </item>
  </channel>
</rss>

