<?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: Changing root's shell in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454958#M770429</link>
    <description>Thank you both, this is exactly what I needed to know.  It is in fact the history which first annoyed me about sh.&lt;BR /&gt;&lt;BR /&gt;Rather than do anything unusual as regards ksh, I set up the history per message above, so I'm satisfied for now.&lt;BR /&gt;&lt;BR /&gt;If I find sh to have other shortcomings in the future I'll consider copying ksh to /sbin, but for now I'll leave it.&lt;BR /&gt;&lt;BR /&gt;Thanks again,&lt;BR /&gt;Fred&lt;BR /&gt;</description>
    <pubDate>Wed, 18 Oct 2000 12:06:16 GMT</pubDate>
    <dc:creator>Fred Martin_1</dc:creator>
    <dc:date>2000-10-18T12:06:16Z</dc:date>
    <item>
      <title>Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454955#M770426</link>
      <description>When I installed HP-UX 10.20, the root user login shell was (is) /sbin/sh.&lt;BR /&gt;&lt;BR /&gt;I'd prefer root have ksh, so I changed it to /usr/bin/ksh ... but I got errors, and I forget them now but in effect the complaint was that the login shell was not in /sbin.&lt;BR /&gt;&lt;BR /&gt;Is it a requirement for the root login shell to be in /sbin?  There is no ksh in there.&lt;BR /&gt;&lt;BR /&gt;So - do I just copy ksh into /sbin from /usr/bin?&lt;BR /&gt;&lt;BR /&gt;Also am wondering if ksh is not there already for some good reason.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Fred&lt;BR /&gt;</description>
      <pubDate>Wed, 18 Oct 2000 11:24:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454955#M770426</guid>
      <dc:creator>Fred Martin_1</dc:creator>
      <dc:date>2000-10-18T11:24:57Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454956#M770427</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;/sbin/sh is the posix shell which has many features of the korn shell.&lt;BR /&gt;When taking /usr/bin/ksh as root shell this is risky because the /usr filesystem is not mounted ie. at single user mode.&lt;BR /&gt;Yes, you can copy /usr/bin/ksh to /sbin/ksh.&lt;BR /&gt;Have you trouble with command history ?&lt;BR /&gt;If so you have to set some varaibles in /etc/profile or $HOME/profile to make it work:&lt;BR /&gt;VISUAL=vi; export VISUAL&lt;BR /&gt;HISTFILE=$HOME/.sh_history; export HISTFILE&lt;BR /&gt;&lt;BR /&gt;(/sbin/sh has also the feature of command history like ksh)&lt;BR /&gt;&lt;BR /&gt;Regards</description>
      <pubDate>Wed, 18 Oct 2000 11:30:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454956#M770427</guid>
      <dc:creator>Andreas Voss</dc:creator>
      <dc:date>2000-10-18T11:30:32Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454957#M770428</link>
      <description>man passwd:  The login shell for the root user (uid 0) must be /sbin/sh.  Other&lt;BR /&gt;  shells such as sh, ksh, and csh are all located under the /usr&lt;BR /&gt;  directory which may not be mounted during earlier stages of the bootup&lt;BR /&gt;  process. Changing the login shell of the root user to a value other&lt;BR /&gt;  than /sbin/sh may result in a non-functional system.&lt;BR /&gt;                                    ================&lt;BR /&gt;The root account must use /sbin/sh, and may not be changed to any&lt;BR /&gt;of the shells in /bin.  There are a couple of reasons for this,&lt;BR /&gt;all of which involve /usr not being mounted in single user mode.&lt;BR /&gt;When the system boots, one of the first things it must do is exec&lt;BR /&gt;a root shell at single user mode to run fsck and the various rc&lt;BR /&gt;scripts.  At this time, the only file systems that are mounted are&lt;BR /&gt;/ and /stand.  /bin is really a symbolic link to /usr/bin, which is&lt;BR /&gt;not mounted, so the shells there are not available until /usr has&lt;BR /&gt;been fsck'd and mounted, so we have no way to exec one of them.  In&lt;BR /&gt;addition, the files under /usr/bin are dynamically linked, meaning&lt;BR /&gt;the shared libraries under /usr and the dynamic linker /usr/lib/dld.sl&lt;BR /&gt;must be available to load them (/lib is also a symbolic link to/usr/lib).&lt;BR /&gt;The executables in /sbin are statically linked and do not require the&lt;BR /&gt;shared libraries or the dynamic linker.&lt;BR /&gt;The shell under /sbin/sh is not the old Bourne shell - it is a statically&lt;BR /&gt;linked version of the posix shell, which should have most, if not all,of&lt;BR /&gt;the functionality of the Korn shell.&lt;BR /&gt;&lt;BR /&gt;HOWEVER =&amp;gt; I heard someone tried to subvert the system sucessfully using the following :.&lt;BR /&gt;He set up a link from /usr/bin/ksh to /sbin/sh that is in effect&lt;BR /&gt;during single user mode. Then when /usr gets mounted the real&lt;BR /&gt;/usr/bin/ksh covers the link.  So the system boots to multiuser&lt;BR /&gt;with /sbin/sh and then root uses /usr/bin/ksh.&lt;BR /&gt;&lt;BR /&gt;STRICTLY UNSUPPORTED though !&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 18 Oct 2000 11:31:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454957#M770428</guid>
      <dc:creator>Alex Glennie</dc:creator>
      <dc:date>2000-10-18T11:31:49Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454958#M770429</link>
      <description>Thank you both, this is exactly what I needed to know.  It is in fact the history which first annoyed me about sh.&lt;BR /&gt;&lt;BR /&gt;Rather than do anything unusual as regards ksh, I set up the history per message above, so I'm satisfied for now.&lt;BR /&gt;&lt;BR /&gt;If I find sh to have other shortcomings in the future I'll consider copying ksh to /sbin, but for now I'll leave it.&lt;BR /&gt;&lt;BR /&gt;Thanks again,&lt;BR /&gt;Fred&lt;BR /&gt;</description>
      <pubDate>Wed, 18 Oct 2000 12:06:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454958#M770429</guid>
      <dc:creator>Fred Martin_1</dc:creator>
      <dc:date>2000-10-18T12:06:16Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454959#M770430</link>
      <description>STRICTLY UNSUPPORTED&lt;BR /&gt;&lt;BR /&gt;'Tis very true!</description>
      <pubDate>Wed, 18 Oct 2000 12:41:43 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454959#M770430</guid>
      <dc:creator>Cheryl Griffin</dc:creator>
      <dc:date>2000-10-18T12:41:43Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454960#M770431</link>
      <description>&lt;BR /&gt;I will never do this.&lt;BR /&gt;&lt;BR /&gt;Not just absolute unsuporported but the begining of problems.&lt;BR /&gt;&lt;BR /&gt;Some process need /sbin/sh strictly to run.&lt;BR /&gt;&lt;BR /&gt;There is a workaround, modify your /.profile &lt;BR /&gt;adding:&lt;BR /&gt;EDITOR=vi&lt;BR /&gt;export EDITOR &lt;BR /&gt;ksh&lt;BR /&gt;exit&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;This workaround let /sbin/sh for not looged in process, and let you to automoticaly start a ksh when you loggin as root.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 18 Oct 2000 13:34:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454960#M770431</guid>
      <dc:creator>Carlos Fernandez Riera</dc:creator>
      <dc:date>2000-10-18T13:34:12Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454961#M770432</link>
      <description>I wouldn't be so categorical Carlos.&lt;BR /&gt;&lt;BR /&gt;The problem with shells other than /sbin/sh is that they are not available to root until after the /usr ist mounted if /usr is a separate volume, which it has absolutely no reason to be.&lt;BR /&gt;&lt;BR /&gt;I usually allow for only 3 volumes in the vg00: boot, swap and root. Therefore I use /usr/bin/ksh for root and didn't have a single problem on account of that.&lt;BR /&gt;&lt;BR /&gt;The real problem is: Why should anyone keep /usr separate from /? The standard way of partitioning into /, /stand, /usr, /opt, /tmp, /var and /home is inviting the trouble which it is supposed to eliminate, namely that in a unified volume a runaway process fills up the volume and cause a stall. By balkanizing the root volume group into so many separate volumes you are actually increasing the probability that any one of them will get full much sooner than if you kept them all coalesced in one huge volume.</description>
      <pubDate>Fri, 20 Oct 2000 18:52:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454961#M770432</guid>
      <dc:creator>Dragan Krnic</dc:creator>
      <dc:date>2000-10-20T18:52:14Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454962#M770433</link>
      <description>Hi:&lt;BR /&gt;&lt;BR /&gt;Dragan makes some very good points.  I suppose, too, if there weren't differences in opinion or differences in "first assumptions" there wouldn't be so many languages and so many operating systems nor even "open" ones where individual contributions are welcomed; nee solicited.&lt;BR /&gt;&lt;BR /&gt;A great article on "Why Root's Default Shell Should Be The Poxix Shell" can be found at the link below.  Agree, or disagree as you wish, but based on some "first assumptions" it does point out some pitfalls if you fail to follow canon.&lt;BR /&gt;&lt;BR /&gt;Regards!&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://education.hp.com/itrc/news/unix_art5.html" target="_blank"&gt;http://education.hp.com/itrc/news/unix_art5.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;...JRF...</description>
      <pubDate>Fri, 20 Oct 2000 21:25:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454962#M770433</guid>
      <dc:creator>James R. Ferguson</dc:creator>
      <dc:date>2000-10-20T21:25:12Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454963#M770434</link>
      <description>Dragan does make some interesting points.  It has made me reconsider the need to split /var into a separate filesystem.  I see a danger, though, in failing to separate /home, /tmp, /usr and /opt.  If these filesystems are segregated, then filling up one of them might cause a disruption in processing, but it will not crash the server.  Filling up a unified / (or a segregated /var) will generally put your server into an unrecoverable state.  You do increase your chances of filling up a filesystem by segregating, but you also protect yourself by walling off critical files from the explosion of a non-critical directory.</description>
      <pubDate>Sun, 22 Oct 2000 13:39:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454963#M770434</guid>
      <dc:creator>Alan Riggs</dc:creator>
      <dc:date>2000-10-22T13:39:11Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454964#M770435</link>
      <description>/sbin/sh is a POSIX shell but without&lt;BR /&gt;support for "exotic" loacles such as Swedish.&lt;BR /&gt;This POSIX shell is an almost true superset&lt;BR /&gt;of the Korn shell, so everything you expect&lt;BR /&gt;from ksh is there in /sbin/sh.  The reason&lt;BR /&gt;for not allowing other shells is that&lt;BR /&gt;the system must be guaranteed to have a&lt;BR /&gt;shell which works without other partitions&lt;BR /&gt;being functional.&lt;BR /&gt;&lt;BR /&gt;Bo</description>
      <pubDate>Sun, 22 Oct 2000 15:08:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454964#M770435</guid>
      <dc:creator>Bo Thide'</dc:creator>
      <dc:date>2000-10-22T15:08:22Z</dc:date>
    </item>
    <item>
      <title>Re: Changing root's shell</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454965#M770436</link>
      <description>&lt;BR /&gt;Perhaps i had a bad experience ;-)&lt;BR /&gt;&lt;BR /&gt;Yes, but in other UNIX O.S. and box did not boot.&lt;BR /&gt;&lt;BR /&gt;The last line in James link is clear.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Mon, 23 Oct 2000 08:39:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/changing-root-s-shell/m-p/2454965#M770436</guid>
      <dc:creator>Carlos Fernandez Riera</dc:creator>
      <dc:date>2000-10-23T08:39:15Z</dc:date>
    </item>
  </channel>
</rss>

