docs/87351: Jail building instructions don't work as described with default CSH shell

Andreas Klemm andreas at freebsd.org
Sat Oct 29 08:50:09 UTC 2005


On Fri, Oct 28, 2005 at 11:49:26AM -0400, John Baldwin wrote:
> On Wednesday 26 October 2005 05:01 pm, Eli K. Breen wrote:
> > I realize I may be opening a can of worms, but as I agree with you on
> > the usefulness of csh(1), why do we continue to use csh as the default
> > shell being that I'd hazard most sane mortals use sh or bash?

Many people use sh / csh because its the standard which is installed
on every commercial (and of course free) unix system.

csh brought a little comfort in the past where no bash or zsh or alike
was available, since it has something like a commandline history which
helped a lot for interactive typing.

But csh was also known as to be a little buggy concerning programming.
At least one could read this in books and articles at that time.
I don't know if this is still the truth for nowadays csh's incl.
tcsh.

This lead to a situation, that most people use csh for interactive
use and sh for writing portable scripts.

If it comes to desaster recovery then you need to use a shell,
that is capable to run even if your shared libraries are damaged.

Or figure out the situation, that your shell is under /bin, but
at the moment you can't mount /usr or whatever.

Therefore for disaster recovery reasons many systems install
a statically linked shell as /sbin/sh, which one would not
use for every day usage because of the bigger size of the
binary.

We can be lucky, that we included tcsh as csh in FreeBSD.
So we are still "standard" with respect to BSD history, but
if the user / admin wants he has a little more comfort.

But concerning real administration work or single user mode
and such, I still see /bin/sh as the shell, which is invoked.

To sum up, for me the Bourne Shell is the No. 1 standard for
doing administration tasks, doing one liners.

Normally you can execute "one line" commands the same way 
in every shell.

If you have more complicated tasks, then you need a script
with variables to avoid a huge number of lines or redundancy
in typing.

Perhaps for these more complicated stuff we could introduce
the concept of a "shell box" in handbook ? Kind of an
xml macro that makes up a box including code ? Perhaps with
a nice warm pastell color (light steel blue or alike) which
represents a "Bource Shell Script", which the user is adviced
to type in shell or write to a file and execute with #! /bin/sh ??


	Andreas ///

-- 
Andreas Klemm - Powered by FreeBSD 6
Need a magic printfilter today ? -> http://www.apsfilter.org/



More information about the freebsd-doc mailing list