Bug 63429 - Need tiny /bin/sh to optimize system performance
Summary: Need tiny /bin/sh to optimize system performance
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: initscripts
Version: 7.2
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: wdovlrrw
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2002-04-13 18:16 UTC by Jukka Lehti
Modified: 2008-05-01 15:38 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2002-04-13 21:50:13 UTC
Embargoed:


Attachments (Terms of Use)

Description Jukka Lehti 2002-04-13 18:16:47 UTC
Summary of the problem can been seen below:

sh-2.05a# ls -l /bin/sh
lrwxrwxrwx    1 root     root            9 Apr 13 20:48 /bin/sh -> /bin/bash
sh-2.05a# ls -l /bin/bash
-rwxr-xr-x    1 root     root       541096 Mar 25 19:20 /bin/bash

It's just crazy to use a binary sized over a half megabytes as /bin/sh. When a
system has to run shell scripts constantly, system performance could be improved
by using other shell than the bloated bash2. /bin/ash would be a good candidate:

sh-2.05a# ls -l /bin/ash
-rwxr-xr-x    1 root     root       108326 Feb 21 19:03 /bin/ash

The problem is that /etc/init.d/functions and some other RH provided scripts are
not compatible with /bin/ash (or vice versa, but the point is that /bin/ash
won't understand current scripts).

Are there any plans to use some other shell as /bin/sh than bash2 in the future?

Comment 1 Bernhard Rosenkraenzer 2002-04-15 16:39:18 UTC
No, for the following reasons: 
 
- no smaller shell provides all the things we need during the startup process 
  (Functions?  Internationalization?). 
- bash is the standard shell on Linux; therefore, every 3rd party application 
  expects to see bash as /bin/sh. Even switching to a similarily powerful 
  shell like zsh would cause problems with those scripts 



Note You need to log in before you can comment on or make changes to this bug.