<?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: stty: : Not a typewriter in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804760#M82737</link>
    <description>Thanks for that, it was an unrelated problem which occurred the same time I made the changes to the .profile.&lt;BR /&gt;&lt;BR /&gt;Many Thanks&lt;BR /&gt;</description>
    <pubDate>Fri, 13 Sep 2002 01:41:45 GMT</pubDate>
    <dc:creator>Arman Mahboobi</dc:creator>
    <dc:date>2002-09-13T01:41:45Z</dc:date>
    <item>
      <title>stty: : Not a typewriter</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804754#M82731</link>
      <description>Hello,&lt;BR /&gt;&lt;BR /&gt;I am running a script through cron and I am receiving "stty: : Not a typewriter" message in my mail. Could anyone please assist.&lt;BR /&gt;&lt;BR /&gt;Below is a list of stty commands in my profile.&lt;BR /&gt;###############################################&lt;BR /&gt;stty erase "^H" kill "^U" intr "^C" eof "^D" susp "^Z"&lt;BR /&gt;[[ $TERM = vt220 ]] &amp;amp;&amp;amp; stty erase  "^?"&lt;BR /&gt;[[ $TERM = vt200 ]] &amp;amp;&amp;amp; stty erase  "^?"&lt;BR /&gt;stty hupcl ixon ixoff &lt;BR /&gt;tabs&lt;BR /&gt;###############################################&lt;BR /&gt;Thanks&lt;BR /&gt;</description>
      <pubDate>Thu, 12 Sep 2002 03:52:01 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804754#M82731</guid>
      <dc:creator>Arman Mahboobi</dc:creator>
      <dc:date>2002-09-12T03:52:01Z</dc:date>
    </item>
    <item>
      <title>Re: stty: : Not a typewriter</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804755#M82732</link>
      <description>Hi Arman,&lt;BR /&gt;&lt;BR /&gt;The error messages are telling you that you are trying to set up a terminal environment when there isn't one to set up - you are running your script from "cron".&lt;BR /&gt;&lt;BR /&gt;The messages are harmless but you could maybe check in your .profile if it is being run from cron by using:&lt;BR /&gt;echo "$-"&lt;BR /&gt;and if there is an "i" in the returned string then the shell is interactive.&lt;BR /&gt;&lt;BR /&gt;Hope this helps,&lt;BR /&gt;&lt;BR /&gt;Ollie.</description>
      <pubDate>Thu, 12 Sep 2002 04:14:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804755#M82732</guid>
      <dc:creator>Ollie R</dc:creator>
      <dc:date>2002-09-12T04:14:00Z</dc:date>
    </item>
    <item>
      <title>Re: stty: : Not a typewriter</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804756#M82733</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;The job run by cron do not assiociate with a terminal so the stty command will be failed when called. You can just skip it.&lt;BR /&gt;&lt;BR /&gt;But if you want to define the stty command in your profile, you can make some checking before issue the command.&lt;BR /&gt;&lt;BR /&gt;== Begin&lt;BR /&gt;&lt;BR /&gt;tty &amp;gt; /dev/null&lt;BR /&gt;rc=$?&lt;BR /&gt;&lt;BR /&gt;if [ $rc -eq 0 ]&lt;BR /&gt;then&lt;BR /&gt;stty erase "^H" kill "^U" intr "^C" eof "^D" susp "^Z" &lt;BR /&gt;[[ $TERM = vt220 ]] &amp;amp;&amp;amp; stty erase "^?" &lt;BR /&gt;[[ $TERM = vt200 ]] &amp;amp;&amp;amp; stty erase "^?" &lt;BR /&gt;stty hupcl ixon ixoff &lt;BR /&gt;tabs &lt;BR /&gt;fi&lt;BR /&gt;&lt;BR /&gt;== End&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Patrick&lt;BR /&gt;</description>
      <pubDate>Thu, 12 Sep 2002 04:55:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804756#M82733</guid>
      <dc:creator>Patrick Chim</dc:creator>
      <dc:date>2002-09-12T04:55:17Z</dc:date>
    </item>
    <item>
      <title>Re: stty: : Not a typewriter</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804757#M82734</link>
      <description>As mentioned, you must protect all tty commands fromj being run in /etc/profile and .profile since there is no tty. In addition to your list of stty and tabs, add any command with tput, ttytype and tset.&lt;BR /&gt;&lt;BR /&gt;You can protect the commands with:&lt;BR /&gt;&lt;BR /&gt;if [ -o interactive ]&lt;BR /&gt;then&lt;BR /&gt;   &lt;TTY commands="" here=""&gt;&lt;BR /&gt;fi&lt;BR /&gt;&lt;/TTY&gt;</description>
      <pubDate>Thu, 12 Sep 2002 12:05:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804757#M82734</guid>
      <dc:creator>ASO CENTRAL</dc:creator>
      <dc:date>2002-09-12T12:05:35Z</dc:date>
    </item>
    <item>
      <title>Re: stty: : Not a typewriter</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804758#M82735</link>
      <description>Hi,&lt;BR /&gt;Thanks for the response.&lt;BR /&gt;&lt;BR /&gt;I have changed the .profile to look like this.&lt;BR /&gt;&lt;BR /&gt;###############################################&lt;BR /&gt;tty &amp;gt; /dev/null&lt;BR /&gt;rc=$?&lt;BR /&gt;if [ $rc -eq 0 ]&lt;BR /&gt;then&lt;BR /&gt;stty erase "^H" kill "^U" intr "^C" eof "^D" susp "^Z" &lt;BR /&gt;[[ $TERM = vt220 ]] &amp;amp;&amp;amp; stty erase "^?" &lt;BR /&gt;[[ $TERM = vt200 ]] &amp;amp;&amp;amp; stty erase "^?" &lt;BR /&gt;stty hupcl ixon ixoff &lt;BR /&gt;tabs &lt;BR /&gt;fi&lt;BR /&gt;###############################################&lt;BR /&gt;&lt;BR /&gt;Now I am experiencing a different problem with the script.&lt;BR /&gt;&lt;BR /&gt;stty: : Not a typewriter&lt;BR /&gt;/u/script&lt;BR /&gt;cannot create&lt;BR /&gt;stty: : Not a typewriter&lt;BR /&gt;&lt;BR /&gt;From what I can see from the script its trying to redirect output to a logfile but its experiencing problems creating it.&lt;BR /&gt;&lt;BR /&gt;The command being used is below,&lt;BR /&gt;&lt;BR /&gt;exec &amp;gt;&amp;gt; $directory/$logfile 2&amp;gt;&amp;gt; $directory/$logfile&lt;BR /&gt;&lt;BR /&gt;Although the script is not interactive can I not create a logfile? Do I have to set a different tty setting if its not interactive?&lt;BR /&gt;&lt;BR /&gt;Your help is much appreciated.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 12 Sep 2002 23:20:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804758#M82735</guid>
      <dc:creator>Arman Mahboobi</dc:creator>
      <dc:date>2002-09-12T23:20:49Z</dc:date>
    </item>
    <item>
      <title>Re: stty: : Not a typewriter</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804759#M82736</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Of course you can create any logfile in a script either by command execution or cron.&lt;BR /&gt;&lt;BR /&gt;The command you run is going to append to a log as you use '&amp;gt;&amp;gt;'. Then what is the owner of that file ? Can you have the permission to write on it ?&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Patrick</description>
      <pubDate>Fri, 13 Sep 2002 00:47:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804759#M82736</guid>
      <dc:creator>Patrick Chim</dc:creator>
      <dc:date>2002-09-13T00:47:09Z</dc:date>
    </item>
    <item>
      <title>Re: stty: : Not a typewriter</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804760#M82737</link>
      <description>Thanks for that, it was an unrelated problem which occurred the same time I made the changes to the .profile.&lt;BR /&gt;&lt;BR /&gt;Many Thanks&lt;BR /&gt;</description>
      <pubDate>Fri, 13 Sep 2002 01:41:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/stty-not-a-typewriter/m-p/2804760#M82737</guid>
      <dc:creator>Arman Mahboobi</dc:creator>
      <dc:date>2002-09-13T01:41:45Z</dc:date>
    </item>
  </channel>
</rss>

