LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 06-06-2004, 02:20 AM   #1
johnpipe
LQ Newbie
 
Registered: Jun 2004
Distribution: RedHat 6.1
Posts: 3

Rep: Reputation: 0
why did bash 2.05b install delete /bin/bash & "/bin/sh -> bash"?


In preparation for trying to build glibc-2.2.4 from source, I've been upgrading various programs (per the Glibc Installation HOWTO on tldp), including static-building bash-2.05b, on a RedHat 6.1 (i586, Intel P233) with gcc 2.95-3, using checkinstall-1.5.2-1 to do "make install", create the rpm and update the package database.

I got a strange behavior; once the new bash was installed in /usr/local/bin (the default for the GNU source), I could no longer open a terminal window. Rebooting gave errors because /bin/bash and the "/bin/sh -> bash" symlink had vanished! I fixed this using Tom's RTBT to access the HD and copy the new bash to /bin and create a new symlink, but I'm wondering why these had disappeared in the first place? I haven't had this happen with any other programs built from source and installed using checkinstall ( I'm usually building new programs from source because of dependency "hell", and am not particularly keen on updating my distribution version as I'm using old hardware).

Thanks in advance,

Johnpipe
 
Old 06-06-2004, 05:51 AM   #2
320mb
Senior Member
 
Registered: Nov 2002
Location: pikes peak
Distribution: Slackware, LFS
Posts: 2,577

Rep: Reputation: 47
Uh, $BASH does not get installed to /usr/local/bin
it goes in /bin, there is a symlink from /usr/bin that points
to /bin, if you want you can put a symlink in /usr/local/bin
BUT, $BASH has to be accessible to all users...........so it
gets install to /bin
 
Old 06-06-2004, 06:42 PM   #3
johnpipe
LQ Newbie
 
Registered: Jun 2004
Distribution: RedHat 6.1
Posts: 3

Original Poster
Rep: Reputation: 0
The question I was asking was why did this install delete /bin/bash, and the /bin/sh symlink (which shouldn't
have been touched at all) .

I know that bash is supposed to install to /bin; however, almost all, if not all, GNU sources of any program
default to installing under /usr/local/ (this makes it possible to have installed, for example, two different versions
of some programs (one under /usr/local and one under /usr or / for example), necessary in case of problems
with the new version). I could have added --prefix=/ (to get the new version to install directly to /bin) to
the ./configure command line, but didn't want to replace the existing bash until the new build was tested.

As I used the GNU defaults for configure, the new bash installed to /usr/local/bin, and should not have
touched anything at all in /bin. My only immediate mistake was failing to copy the new bash immediately
to /bin before rebooting, and if I had done that, I would not have discovered that the original /bin/bash
had disappeared (though with /bin/sh -> bash gone, the lack of sh would have been noticed quickly!)

If I had not had at least one emergency rescue disk available (I've got Knoppix, Tom's RTBT & LinuxCare
Rescue), I'd have had to re-install and re-build the entire 6.1 distribution.

Regards, John
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why "bash-2.05b$" in Terminal instead of "username@localhost username" jayelitumbiolo Linux - General 9 10-04-2009 03:16 AM
$LINENO can't be modified in bash 3.0, while it can be in bash 2.05b Darwish Linux - Software 1 11-07-2005 02:57 PM
bash equivalence of tcsh "alias em "emacs \!:1 &""? rgiggs Slackware 3 07-29-2004 02:07 AM
bash-2.05b# Xlib: extension "XFree86-DRI" missing on display ":0.0". citrus Linux - General 8 02-22-2004 10:43 AM
bin/bash:usr/bin/lpr NO SUCH FILE OR DIRECTORY Adibe_Hamm Linux - Newbie 3 10-14-2003 02:30 AM


All times are GMT -5. The time now is 04:32 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration