[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: /bin/sh and ash, bash

*- On  2 Jan, Ben Collins wrote about "Re: /bin/sh and ash, bash"
> On Sun, Jan 02, 2000 at 03:34:51PM -0600, matt garman wrote:
>> I noticed that Debian makes /bin/sh a symlink to /bin/bash by default.
>> I'd rather have /bin/sh link to /bin/ash.  I tried this quite a while
>> ago, and it seems as though some Debian-specific scripts rely on /bin/sh
>> actually being bash.  In other words, last time I linked /bin/sh to
>> /bin/ash, a few things got broken.
>> I was just curious if anyone knew whether or not it's "safe" to link
>> /bin/sh to /bin/ash?
> That is the goal. If anything breaks when using a posix compliant shell
> for /bin/sh, then a bug should be filed for the package woning them to the
> affect that it needs to have #!/bin/bash for the interpreter.

Except that the bash package now has the /bin/sh symlink in the package
and not as part of the postinst script.  So if you change the link then
the next time you upgrade bash it will reset the /bin/sh link back to

But there is a solution to in the /usr/{share/}doc/bash/README.Debian
file for bash.

A kind of FAQ for bash on Debian/GNU\ {Linux,Hurd}

1. How can I make /bin/sh point to something else?


        dpkg-divert --add /bin/sh

   and then point it to whatever you want. Upgrades to bash  won't upgrade
   the /bin/sh symlink. To put /bin/sh under dpkg control again, type

        dpkg-divert --remove /bin/sh


Brian Servis
Mechanical Engineering              |  Never criticize anybody until you  
Purdue University                   |  have walked a mile in their shoes,
servis@purdue.edu                   |  because by that time you will be a
http://www.ecn.purdue.edu/~servis   |  mile away and have their shoes.

Reply to: