<?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 shell script in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499033#M20561</link>
    <description>I downloaded a script from the web that sets an oracle variable or sid from a list of possible databases. I want to run the script when the oracle dba logs on to the server. If i place the script name in the .profile it runs a subshell and the exported variables are lost when the script exits. If I run the script from the command line like this it works '. ./scriptname'. Is there a way to run the script at login and set environmental variables in the current shell?</description>
    <pubDate>Tue, 27 Feb 2001 22:41:38 GMT</pubDate>
    <dc:creator>Scott Gilchrist</dc:creator>
    <dc:date>2001-02-27T22:41:38Z</dc:date>
    <item>
      <title>shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499033#M20561</link>
      <description>I downloaded a script from the web that sets an oracle variable or sid from a list of possible databases. I want to run the script when the oracle dba logs on to the server. If i place the script name in the .profile it runs a subshell and the exported variables are lost when the script exits. If I run the script from the command line like this it works '. ./scriptname'. Is there a way to run the script at login and set environmental variables in the current shell?</description>
      <pubDate>Tue, 27 Feb 2001 22:41:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499033#M20561</guid>
      <dc:creator>Scott Gilchrist</dc:creator>
      <dc:date>2001-02-27T22:41:38Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499034#M20562</link>
      <description>&lt;A href="http://forums.itrc.hp.com/cm/QuestionAnswer/1,1150,0xdbbc6af52b04d5118fef0090279cd0f9,00.html" target="_blank"&gt;http://forums.itrc.hp.com/cm/QuestionAnswer/1,1150,0xdbbc6af52b04d5118fef0090279cd0f9,00.html&lt;/A&gt;</description>
      <pubDate>Tue, 27 Feb 2001 22:49:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499034#M20562</guid>
      <dc:creator>Curtis Larson</dc:creator>
      <dc:date>2001-02-27T22:49:27Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499035#M20563</link>
      <description>Add the line, . ./scriptname, to your .profile</description>
      <pubDate>Tue, 27 Feb 2001 23:01:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499035#M20563</guid>
      <dc:creator>James A. Donovan</dc:creator>
      <dc:date>2001-02-27T23:01:46Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499036#M20564</link>
      <description>When I put. ./scriptname in the . profile I get the following error .profile [37]: 1: Parameter not Set&lt;BR /&gt;&lt;BR /&gt;../scriptname -&amp;gt; .profile [37] ../scriptname not found&lt;BR /&gt;&lt;BR /&gt;alias ss=". ./scriptname" -&amp;gt; sh: 1: Parameter not set</description>
      <pubDate>Tue, 27 Feb 2001 23:31:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499036#M20564</guid>
      <dc:creator>Scott Gilchrist</dc:creator>
      <dc:date>2001-02-27T23:31:16Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499037#M20565</link>
      <description>Is this script in the users home directory? If not then you need to specify the path to the script.&lt;BR /&gt;&lt;BR /&gt;. ${PATH_TO_SCRIPT}/scriptname&lt;BR /&gt;&lt;BR /&gt;e.g.&lt;BR /&gt;&lt;BR /&gt;. /var/opt/oracle/scriptname</description>
      <pubDate>Wed, 28 Feb 2001 00:16:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499037#M20565</guid>
      <dc:creator>James A. Donovan</dc:creator>
      <dc:date>2001-02-28T00:16:08Z</dc:date>
    </item>
    <item>
      <title>Re: shell script</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499038#M20566</link>
      <description>Just two things to check.&lt;BR /&gt;&lt;BR /&gt;First of all check the options for your shell (you are running POSIX/Korn? If not then alias may not work).&lt;BR /&gt;&lt;BR /&gt;Check for 'nounset' in the shell environment (either found by default as 'set -u' in the /etc/profile or your own .profile.&lt;BR /&gt;&lt;BR /&gt;Our Oracle DBAs had set up a similar script and were flummoxed when they kept getting the same error.&lt;BR /&gt;&lt;BR /&gt;Adam</description>
      <pubDate>Wed, 28 Feb 2001 08:41:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/shell-script/m-p/2499038#M20566</guid>
      <dc:creator>Unix Systems Admin</dc:creator>
      <dc:date>2001-02-28T08:41:23Z</dc:date>
    </item>
  </channel>
</rss>

