<?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: Sed query in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036926#M95320</link>
    <description>Answered and points assigned, thanks.</description>
    <pubDate>Wed, 28 Mar 2007 10:41:19 GMT</pubDate>
    <dc:creator>NOreen Merrick</dc:creator>
    <dc:date>2007-03-28T10:41:19Z</dc:date>
    <item>
      <title>Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036917#M95311</link>
      <description>Hi Guys,&lt;BR /&gt;&lt;BR /&gt;I just want to use sed as a search function on a file instead of grep.&lt;BR /&gt;&lt;BR /&gt;I want to seach for all instances of "Authentication Failure" in the syslog.log file.&lt;BR /&gt;&lt;BR /&gt;I know how to search and replace but can't seem to do the search.&lt;BR /&gt;OS is HP-UX&lt;BR /&gt;Any help is most appreciated.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;&lt;BR /&gt;N</description>
      <pubDate>Wed, 28 Mar 2007 06:55:58 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036917#M95311</guid>
      <dc:creator>NOreen Merrick</dc:creator>
      <dc:date>2007-03-28T06:55:58Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036918#M95312</link>
      <description>posted in wrong forum, moved to more appropriate forum</description>
      <pubDate>Wed, 28 Mar 2007 08:03:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036918#M95312</guid>
      <dc:creator>melvyn burnard</dc:creator>
      <dc:date>2007-03-28T08:03:23Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036919#M95313</link>
      <description>&lt;BR /&gt;This should work.&lt;BR /&gt;&lt;BR /&gt;sed -n '/Authenication Failure/p' /var/adm/syslog/syslog.log&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 28 Mar 2007 09:08:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036919#M95313</guid>
      <dc:creator>Sundar_7</dc:creator>
      <dc:date>2007-03-28T09:08:14Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036920#M95314</link>
      <description>Hi Noreen:&lt;BR /&gt;&lt;BR /&gt;# sed -ne '/Authentication Failure/p' /var/adm/syslog/syslog.log&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Wed, 28 Mar 2007 09:08:39 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036920#M95314</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-03-28T09:08:39Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036921#M95315</link>
      <description>&amp;gt; I just want to use sed as a search function&lt;BR /&gt;&amp;gt; on a file instead of grep.&lt;BR /&gt;&lt;BR /&gt;Why?&lt;BR /&gt;&lt;BR /&gt;Q: I want to use a hammer as a screwdriver,&lt;BR /&gt;but it keeps damaging my screws.  What should&lt;BR /&gt;I do?&lt;BR /&gt;&lt;BR /&gt;A: Use a screwdriver.</description>
      <pubDate>Wed, 28 Mar 2007 09:09:05 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036921#M95315</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2007-03-28T09:09:05Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036922#M95316</link>
      <description>Noreen,&lt;BR /&gt;how about:&lt;BR /&gt; sed -n "1,$ s/Authentication Failure/Authentication Failure/p" data.lis&lt;BR /&gt;&lt;BR /&gt;what is wrong with grep ?</description>
      <pubDate>Wed, 28 Mar 2007 09:12:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036922#M95316</guid>
      <dc:creator>Peter Godron</dc:creator>
      <dc:date>2007-03-28T09:12:03Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036923#M95317</link>
      <description>Hi (again) Noreen:&lt;BR /&gt;&lt;BR /&gt;I would have to agree with Steven, too.  If you sole objective is to find lines where you match a pattern, then 'grep' is probably the simplest tool to use.&lt;BR /&gt;&lt;BR /&gt;The value of 'sed' (or 'awk' or Perl) begins to appear if you want to match *ranges* of lines with patterns or when you want to extract pieces of lines that have a matching pattern.  For example, if you wanted to print lines in a file that began with the pattern 'begin' and ended with the pattern 'end', using 'sed' you could do:&lt;BR /&gt;&lt;BR /&gt;# sed -ne '/^begin/,/^end/p' file&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Wed, 28 Mar 2007 09:37:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036923#M95317</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-03-28T09:37:06Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036924#M95318</link>
      <description>Hi Guys,&lt;BR /&gt;&lt;BR /&gt;thanks they all work. I don't really want to use Sed at all , Grep is fine for me but am doing some "exercises" on grep and that was one of the questions!! Hope i'm not wasting any valuable admin time.&lt;BR /&gt;&lt;BR /&gt;N&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 28 Mar 2007 10:07:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036924#M95318</guid>
      <dc:creator>NOreen Merrick</dc:creator>
      <dc:date>2007-03-28T10:07:52Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036925#M95319</link>
      <description>Hi (again) Noreen:&lt;BR /&gt;&lt;BR /&gt;The question is not a waste of our time, but points for the efforts to respond *are* appreciated.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Wed, 28 Mar 2007 10:34:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036925#M95319</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2007-03-28T10:34:27Z</dc:date>
    </item>
    <item>
      <title>Re: Sed query</title>
      <link>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036926#M95320</link>
      <description>Answered and points assigned, thanks.</description>
      <pubDate>Wed, 28 Mar 2007 10:41:19 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/sed-query/m-p/5036926#M95320</guid>
      <dc:creator>NOreen Merrick</dc:creator>
      <dc:date>2007-03-28T10:41:19Z</dc:date>
    </item>
  </channel>
</rss>

