Re: how to reinstall bash

2014-09-14 Thread Marko Randjelovic
On Sun, 14 Sep 2014 13:29:15 +0800
lina lina.lastn...@gmail.com wrote:

 $ ls -l /bin/sh /bin/bash /bin/dash
 -rwxr-xr-x 1 root root 1029624 Aug 22 05:15 /bin/bash
 -rwxr-xr-x 1 root root  117176 Jan 10  2014 /bin/dash
 lrwxrwxrwx 1 root root   9 Sep 13 17:48 /bin/sh - /bin/bash
 
 Now it is sane, the mistake came at the first place was due to my slip
 in treating 'ln -sf /bin/sh /bin/bash' and then I realized that
 mistakes but unconsciously still possess enough amount of intuition to
 repeat this mistake.

I don't know what Debian release do you use, but since Squeeze, /bin/sh
should point to dash.

Kind regards

-- 
http://markorandjelovic.hopto.org

One should not be afraid of humans.
Well, I am not afraid of humans, but of what is inhuman in them.
Ivo Andric, Signs near the travel-road


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/20140914084454.50319...@sbb.rs



Re: how to reinstall bash

2014-09-14 Thread songbird
Marko Randjelovic wrote:
 On Sun, 14 Sep 2014 13:29:15 +0800
 lina lina.lastn...@gmail.com wrote:

 $ ls -l /bin/sh /bin/bash /bin/dash
 -rwxr-xr-x 1 root root 1029624 Aug 22 05:15 /bin/bash
 -rwxr-xr-x 1 root root  117176 Jan 10  2014 /bin/dash
 lrwxrwxrwx 1 root root   9 Sep 13 17:48 /bin/sh - /bin/bash
 
 Now it is sane, the mistake came at the first place was due to my slip
 in treating 'ln -sf /bin/sh /bin/bash' and then I realized that
 mistakes but unconsciously still possess enough amount of intuition to
 repeat this mistake.

 I don't know what Debian release do you use, but since Squeeze, /bin/sh
 should point to dash.

 Kind regards

  i'm not sure about that...

  i've been upgrading via testing and unstable
and my links show:

-rwxr-xr-x 1 root root 1101744 Aug 21 17:51 bash
-rwxr-xr-x 1 root root  112204 Jan 10  2014 dash
lrwxrwxrwx 1 root root   4 Aug 21 17:51 rbash - bash
lrwxrwxrwx 1 root root   4 Mar  4  2012 sh - bash
lrwxrwxrwx 1 root root   4 Jan 10  2014 sh.distrib - dash


/etc/debian_version

  says jessie/sid


  songbird


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/ol4geb-e7h@id-306963.user.uni-berlin.de



Re: how to reinstall bash

2014-09-14 Thread Martin Read

On 14/09/14 10:44, songbird wrote:

Marko Randjelovic wrote:

I don't know what Debian release do you use, but since Squeeze, /bin/sh
should point to dash.


   i'm not sure about that...


I suspect it to be the case that if you've been continuously upgrading 
since before the change was made, your existing symlink will not have 
been changed.


My current jessie system was originally installed as a wheezy system, 
and has /bin/sh as a link to /bin/dash.



--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org

Archive: https://lists.debian.org/54156e6e.20...@zen.co.uk



Re: how to reinstall bash

2014-09-14 Thread songbird
Martin Read wrote:
 songbird wrote:
 Marko Randjelovic wrote:

 I don't know what Debian release do you use, but since Squeeze, /bin/sh
 should point to dash.

i'm not sure about that...

 I suspect it to be the case that if you've been continuously upgrading 
 since before the change was made, your existing symlink will not have 
 been changed.

  upgrading from testing/unstable for several years.
likely a Lenny install to start with.

  recently i installed Wheezy 7.5 into a spare 
partition that i can check...  yes, it is pointing 
at dash.


 My current jessie system was originally installed as a wheezy system, 
 and has /bin/sh as a link to /bin/dash.


  songbird


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/0hgheb-m11@id-306963.user.uni-berlin.de



Re: how to reinstall bash [Update]

2014-09-13 Thread Hans
Am Samstag, 13. September 2014, 17:39:04 schrieb lina:
 By some mistake, I remove the /bin/bash
 
 Any suggestions?
 
 Thanks,

If my previos hints, do not work, start a livefile system (debian live or 
knoppix), get the binary from there, mount the partiion wherer /usr/bin 
resides and copy the binary from there.

Best 

Hans


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/18096031.s2GflDIiAy@protheus2



Re: how to reinstall bash

2014-09-13 Thread lina
Done by following the link:

http://ubuntuforums.org/showthread.php?t=1618902


namely,

1] ln -sf /bin/sh /bin/bash
2] apt-get install --reinstall bash


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: 
https://lists.debian.org/CAG9cJmm=bdoCoHHOFU=wjxf6ymih9c-ehgrtq78sv_xqtco...@mail.gmail.com



Re: how to reinstall bash

2014-09-13 Thread Pascal Obry
Le samedi 13 septembre 2014 à 17:39 +0800, lina a écrit : 
 By some mistake, I remove the /bin/bash
 
 Any suggestions?

In a console:

$ sudo aptitude reinstall bash

-- 
  Pascal Obry /  Magny Les Hameaux (78)

  The best way to travel is by means of imagination

  http://v2p.fr.eu.org
  http://www.obry.net

  gpg --keyserver keys.gnupg.net --recv-key F949BD3B


--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/1410601486.2213.204.ca...@obry.net



Re: how to reinstall bash

2014-09-13 Thread Hans
Am Samstag, 13. September 2014, 17:39:04 schrieb lina:
 By some mistake, I remove the /bin/bash
 
 Any suggestions?
 
 Thanks,

Try first:

apt-get --reinstall install bash

if this does not work, try

dpkg --force-overwrite -i /var/cache/apt/archive/bash.deb

if this does not work, try:

apt-get remove bash
apt-get install bash

Good luck

Hans


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/1783505.HrkSpcY2Vb@protheus2



Re: Re: how to reinstall bash

2014-09-13 Thread Clive Standbridge
 Done by following the link:
 http://ubuntuforums.org/showthread.php?t=1618902
 namely,
 
 1] ln -sf /bin/sh /bin/bash

That is an unfortunate mistake; the link name and target are the wrong
way round. It will make /bin/bash into a symbolic link when it should
be an ELF binary.

 2] apt-get install --reinstall bash

I'm not sure whether that would repair the damage caused by [1]. To
check, please run this command and paste the output into your reply:

ls -l /bin/sh /bin/bash /bin/dash


-- 
Cheers,
Clive


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/20140913150638.GA11020@rimmer.localdomain



Re: Re: how to reinstall bash

2014-09-13 Thread lina
Thanks for your scrupulous attitude.

$ ls -l /bin/sh /bin/bash /bin/dash
-rwxr-xr-x 1 root root 1029624 Aug 22 05:15 /bin/bash
-rwxr-xr-x 1 root root  117176 Jan 10  2014 /bin/dash
lrwxrwxrwx 1 root root   9 Sep 13 17:48 /bin/sh - /bin/bash

Now it is sane, the mistake came at the first place was due to my slip
in treating 'ln -sf /bin/sh /bin/bash' and then I realized that
mistakes but unconsciously still possess enough amount of intuition to
repeat this mistake.

Have a nice weekend,

P.S. I have some lousy code, which complained the 'sh: Syntax error:
Bad fd number', which drove me to compromise to link the sh with the
bash, not dash.

On Sat, Sep 13, 2014 at 11:06 PM, Clive Standbridge
list-u...@tgstandbridges.plus.com wrote:
 Done by following the link:
 http://ubuntuforums.org/showthread.php?t=1618902
 namely,

 1] ln -sf /bin/sh /bin/bash

 That is an unfortunate mistake; the link name and target are the wrong
 way round. It will make /bin/bash into a symbolic link when it should
 be an ELF binary.

 2] apt-get install --reinstall bash

 I'm not sure whether that would repair the damage caused by [1]. To
 check, please run this command and paste the output into your reply:

 ls -l /bin/sh /bin/bash /bin/dash


 --
 Cheers,
 Clive


 --
 To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org
 with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
 Archive: https://lists.debian.org/20140913150638.GA11020@rimmer.localdomain



-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: 
https://lists.debian.org/cag9cjmmmbh+cos7wci5xk8bewn-4uracuxffidpwxh9eo_j...@mail.gmail.com