Re: I cannot login coz bash is deinstalled

2009-03-04 Thread Wojciech Puchar


- boot in singkle user mode
- mount all your s=disks: mount -a
- edit /etc/passwd with your favourite editor

it won't work.

databases must be rebuild, you have to use chsh or vipw
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: I cannot login coz bash is deinstalled

2009-03-04 Thread Wojciech Puchar

login.

I can only login in with single user mode which freebsd proovide, but few
tools are provided.

How can I change my shell to sh without logining?


run chsh on single user



I have a debian cd which can bring me to its shell,but when i mount /dev/hda
,it says no such device.

Thanks.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"



___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: I cannot login coz bash is deinstalled

2009-03-03 Thread lacalling
I tried to vi /etc/passwd and change the path of shell to sh from bash.
it did not work coz it is encrypted?

anyway i suceessed with chsh finally.


On Wed, Mar 4, 2009 at 1:02 PM, Tim Judd  wrote:

>
>
> On Tue, Mar 3, 2009 at 9:49 PM, Olivier Nicole  wrote:
>
>> Hi,
>>
>> > How can I change my shell to sh without logining?
>>
>> You cannot!
>>
>> But what you can:
>>
>> - boot in singkle user mode
>> - mount all your s=disks: mount -a
>> - edit /etc/passwd with your favourite editor
>>
>> Bests,
>>
>> olivier
>
>
>
> WRONG!
>
> DO NOT EDIT /etc/passwd DIRECTLY!!!
> vipw, or change your EDITOR environment variable to use something else
> other than vi.
>
> Otherwise correct.
>
>
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: I cannot login coz bash is deinstalled

2009-03-03 Thread Tim Judd
On Tue, Mar 3, 2009 at 9:49 PM, Olivier Nicole  wrote:

> Hi,
>
> > How can I change my shell to sh without logining?
>
> You cannot!
>
> But what you can:
>
> - boot in singkle user mode
> - mount all your s=disks: mount -a
> - edit /etc/passwd with your favourite editor
>
> Bests,
>
> olivier



WRONG!

DO NOT EDIT /etc/passwd DIRECTLY!!!
vipw, or change your EDITOR environment variable to use something else other
than vi.

Otherwise correct.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: I cannot login coz bash is deinstalled

2009-03-03 Thread Bryant Eadon

Bryant Eadon wrote:

lacalling wrote:

I forget to change shell before I deinstalled bash.
A errer occurs when i try to login with my user or root. And it 
returns to

login.

I can only login in with single user mode which freebsd proovide, but few
tools are provided.

How can I change my shell to sh without logining?

I have a debian cd which can bring me to its shell,but when i mount 
/dev/hda

,it says no such device.

Thanks.


Have you tried 'chsh -s /bin/sh' ?
mount /usr, it's in /usr/bin/chsh by default.

This is one of the reasons to leave the root shell at a safe default. 
Alternatively, a different super-user account could be created to avoid 
this problem -- leaving root with it's mostly stock (safe) setup.




I should note that you'll need to be logged in as single user. And according to 
the man pages it should go something like this :


/usr/bin/chsh -s /bin/sh root

(not tested)
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: I cannot login coz bash is deinstalled

2009-03-03 Thread Bryant Eadon

lacalling wrote:

I forget to change shell before I deinstalled bash.
A errer occurs when i try to login with my user or root. And it returns to
login.

I can only login in with single user mode which freebsd proovide, but few
tools are provided.

How can I change my shell to sh without logining?

I have a debian cd which can bring me to its shell,but when i mount /dev/hda
,it says no such device.

Thanks.


Have you tried 'chsh -s /bin/sh' ?
mount /usr, it's in /usr/bin/chsh by default.

This is one of the reasons to leave the root shell at a safe default. 
Alternatively, a different super-user account could be created to avoid this 
problem -- leaving root with it's mostly stock (safe) setup.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: I cannot login coz bash is deinstalled

2009-03-03 Thread Olivier Nicole
Hi,

> How can I change my shell to sh without logining?

You cannot!

But what you can:

- boot in singkle user mode
- mount all your s=disks: mount -a
- edit /etc/passwd with your favourite editor

Bests,

olivier
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"