40% slowdown with dynamic /bin/sh

Tim Kientzle kientzle at acm.org
Tue Dec 2 13:50:13 PST 2003


Daniel C. Sobral wrote:
> Now, my machines usually get by themselves, but all *I* do on them is 
> sh(1) intensive, so I'll probably be using the static root option when 
> it comes time to upgrade them to 5.x.

The static root option exists for people with special requirements:
   * Use a lot of shell scripts
   * Have very high performance requirements for those scripts
   * Does not use LDAP, NIS, or other networked directory services
     (I want to move NIS out of libc.  Its privileged position
     relative to LDAP and other services is rather dated.)

E.g., someone with a standalone server that's using
/bin/sh to run CGIs would be well advised to compile
a static /bin/sh.  Fortunately, that's easy to do.

> And if you are using FreeBSD on desktop you should use bash or some 
> other ports-shell, instead of slowing down _the_ shell for shell 
> scripts.

User shell scripts do rely on tilde expansion.  Having
that break in any environment relying on networked directory
services is a pretty serious loss of functionality.

Tim Kientzle



More information about the freebsd-current mailing list