LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-01-2012, 03:09 PM   #1
Sirocco
LQ Newbie
 
Registered: Aug 2012
Posts: 4

Rep: Reputation: Disabled
Login shell


Hi guys,

I have a probably very easy question but I'm struggling to solve it. I wrote a script in sh, changed the shell to /bin/sh, simple as is. Today I changed the shell back to bash (I messed up something so I had to change it in /etc/passwd back to /bin/bash) but every time I launch the terminal, I can see the sh prompt. I use pubuntu, the username is pubuntu as well. Even though the default shell is bash both for the user and root in passwd, every time I start a new session, the default shell is sh. Do anybody know how I can change it?

Every help is much appreciated.

Thanks,
Sirocco
 
Old 08-01-2012, 03:15 PM   #2
towheedm
Member
 
Registered: Sep 2011
Location: Trinidad & Tobago
Distribution: Debian Jessie
Posts: 592

Rep: Reputation: 119Reputation: 119
Change the link pointed to by /bin/sh to /bin/bash.
Code:
ln -s /bin/bash /bin/sh
 
Old 08-01-2012, 03:24 PM   #3
Sirocco
LQ Newbie
 
Registered: Aug 2012
Posts: 4

Original Poster
Rep: Reputation: Disabled
Hi towheedm,

Normally I would say it's the default (sh is linked to bash) but tried it now and works perfectly well. I must have messed something up, echo $0 gives bash immediately. Thanks very much.
 
  


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
How to check in a script whether the shell is login or non login? frankie_DJ Programming 7 10-21-2015 11:09 AM
Difference between normal shell and login shell Manish Linux - General 7 11-14-2012 09:30 AM
How do I get the /etc/login.defs in a non login shell acummings Slackware 7 05-20-2007 11:17 PM
wrong login shell prevent root login cefs99 Linux - Security 4 05-31-2006 09:28 AM
login shell?? Japan Lnx Linux - Newbie 8 01-22-2005 08:37 PM


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

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration