<?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: cntrl-d in shell script in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121368#M314853</link>
    <description>tried exit 0 - no better</description>
    <pubDate>Thu, 27 Dec 2007 09:28:42 GMT</pubDate>
    <dc:creator>Popy</dc:creator>
    <dc:date>2007-12-27T09:28:42Z</dc:date>
    <item>
      <title>cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121366#M314851</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;What signal I will do the cntrl-d function in a shell script ?&lt;BR /&gt;&lt;BR /&gt;I tried exit, exit 1, but no luck&lt;BR /&gt;&lt;BR /&gt;Vijay</description>
      <pubDate>Thu, 27 Dec 2007 08:54:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121366#M314851</guid>
      <dc:creator>Popy</dc:creator>
      <dc:date>2007-12-27T08:54:31Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121367#M314852</link>
      <description>Have you tried exit 0 ??&lt;BR /&gt;</description>
      <pubDate>Thu, 27 Dec 2007 09:14:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121367#M314852</guid>
      <dc:creator>Mridul Shrivastava</dc:creator>
      <dc:date>2007-12-27T09:14:17Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121368#M314853</link>
      <description>tried exit 0 - no better</description>
      <pubDate>Thu, 27 Dec 2007 09:28:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121368#M314853</guid>
      <dc:creator>Popy</dc:creator>
      <dc:date>2007-12-27T09:28:42Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121369#M314854</link>
      <description>what abt the quit ??&lt;BR /&gt;&lt;BR /&gt;The ascii code for EOF(ctrl+D) is 0x1A,  one way would be this:&lt;BR /&gt;perl -e "print \"\\x1A\";" | blah_command_to_recieve_it&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 27 Dec 2007 09:33:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121369#M314854</guid>
      <dc:creator>Mridul Shrivastava</dc:creator>
      <dc:date>2007-12-27T09:33:50Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121370#M314855</link>
      <description>Control D is EOF, it isn't a signal.&lt;BR /&gt;&lt;BR /&gt;You can use "trap exit ..." but that will only work if you have an interactive shell.  Or when you get to the end of your shell script.&lt;BR /&gt;&lt;BR /&gt;Note: One shell script can read stdin N times, each terminated by the the EOF of the disk file or control D on a terminal.&lt;BR /&gt;&lt;BR /&gt;&amp;gt;Mridul: The ascii code for EOF(ctrl+D) is 0x1A&lt;BR /&gt;&lt;BR /&gt;No, the code is 0x04, see ascii(5).  0x1a, control-Z is the DOS EOF.&lt;BR /&gt;&lt;BR /&gt;&amp;gt;one way would be this:&lt;BR /&gt;perl -e "print \"\\x1A\";" | blah_command_to_receive_it&lt;BR /&gt;&lt;BR /&gt;This won't work.  Control D is only valid for terminals.  Not files nor pipes.</description>
      <pubDate>Thu, 27 Dec 2007 11:00:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121370#M314855</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2007-12-27T11:00:01Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121371#M314856</link>
      <description>Thanks Dennis,&lt;BR /&gt;&lt;BR /&gt;Let me tell you what I want to do, I have script which will send an Email if my ignite fails, &lt;BR /&gt;&lt;BR /&gt;The script stops at this line, I want to come out from this line..&lt;BR /&gt;&lt;BR /&gt;mailx -s "`hostname`: no tape loaded - ignite failed" vijay@xyc.com &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 28 Dec 2007 05:18:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121371#M314856</guid>
      <dc:creator>Popy</dc:creator>
      <dc:date>2007-12-28T05:18:29Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121372#M314857</link>
      <description>&amp;gt;The script stops at this line, I want to come out from this line:&lt;BR /&gt;mailx -s "`hostname`: no tape loaded - ignite failed" vijay@xyc.com&lt;BR /&gt;&lt;BR /&gt;You need to provide stdin for the message body.  You can either use echo, a here document or /dev/null:&lt;BR /&gt;$ echo hi | mailx -s "ho" ...&lt;BR /&gt;$ mailx -s "stuff" ... &amp;lt; /dev/null&lt;BR /&gt;$ mailx -s "more stuff" ... &amp;lt;&lt;EOF&gt;&lt;/EOF&gt;mail body&lt;BR /&gt;EOF</description>
      <pubDate>Fri, 28 Dec 2007 06:01:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121372#M314857</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2007-12-28T06:01:27Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121373#M314858</link>
      <description>&amp;gt;ME: You need to provide stdin for the message body.&lt;BR /&gt;&lt;BR /&gt;You can also provide the ignite error logs in the body:&lt;BR /&gt;$ mailx -s "more errors" ... &amp;lt; some-error-file</description>
      <pubDate>Fri, 28 Dec 2007 06:10:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121373#M314858</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2007-12-28T06:10:31Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121374#M314859</link>
      <description>That did work....thanks Dennis. I've give the recover log as the input thereby avoided a keyboard interaction.&lt;BR /&gt;&lt;BR /&gt;Cheers&lt;BR /&gt;Vijay</description>
      <pubDate>Fri, 28 Dec 2007 08:43:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121374#M314859</guid>
      <dc:creator>Popy</dc:creator>
      <dc:date>2007-12-28T08:43:57Z</dc:date>
    </item>
    <item>
      <title>Re: cntrl-d in shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121375#M314860</link>
      <description>That did work....thanks Dennis. I've given the recovery log as the input, that avoided a keyboard interaction.&lt;BR /&gt;&lt;BR /&gt;Cheers&lt;BR /&gt;Vijay</description>
      <pubDate>Fri, 28 Dec 2007 08:44:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cntrl-d-in-shell-script/m-p/4121375#M314860</guid>
      <dc:creator>Popy</dc:creator>
      <dc:date>2007-12-28T08:44:41Z</dc:date>
    </item>
  </channel>
</rss>

