1838334 Members
3037 Online
110125 Solutions
New Discussion

no shell

 
SOLVED
Go to solution
lydi
Occasional Contributor

no shell

I'm trying to iniciate a session and system send me this message:

HP-UX hpat577 B.11.00 U 9000/800 695389373 unlimited-user license

login: broadvis
Password:
No shell


with all users I manage happen that.

What happened, what can i do ?


7 REPLIES 7
Bill Hassell
Honored Contributor

Re: no shell

There are several possibilities. I am assuming that you are starting a session using telnet. The shell for the user broadvis is found with the command:

grep ^broadvis: /etc/passwd | awk -F : '{print $NF}'

Normally, this would be /usr/bin/sh which is the POSIX shell. If this is not correct, login as root and use the command vipw to edit the /etc/passwd file. However, if all users have the same error message, someone has probably changed the critical permissions of the / and /etc directories. These must never be changed. The permission and ownership should be:

drwxr-xr-x 29 root root 8192 Oct 8 18:41 //
dr-xr-xr-x 31 bin bin 8192 Jan 23 21:38 /etc/



Bill Hassell, sysadmin
Raj D.
Honored Contributor

Re: no shell

No Shell means that the shell given to user is not available,

1. check /etc/passwd , as what shell is assigned to the user broadvis,

# cat /etc/passwd | grep broadvis

2. check that shell is there in the system and valid.

it may be caused by typo error during creation of the user and specifying a shell like /usr/sbin/vsh ,

Cheers,
Raj.
" If u think u can , If u think u cannot , - You are always Right . "
Asif Sharif
Honored Contributor

Re: no shell

Hi lydi,

Yesterday one of my customer has same problem.I found that somebody has
changed the permissions of the / and /etc directories. After changing permissions problem solved. So its better to check permission as per "BILL" suggestion.

Regards,
Asif Sharif
Regards,
Asif Sharif
perumal_2
Frequent Advisor
Solution

Re: no shell

Hi Lydi

Pls check the ownership of the . in your problematic system. Hope the sysmptom is other than root user no one can login.

Do the following
#ls -latr
locate the . and check the ownership.
Did you do a vxrestore any thing in the / file sytem. This is potentailly dangeorus to do a restore in the /.
Or some one might have changed the permission of a "."

It should be root:root

TQ
Perumal



Dennis Handly
Acclaimed Contributor

Re: no shell

>Asif: I found that somebody has changed the permissions of the / and /etc directories

You might want to use swverify on the system to see what else was changed. (There is a -F option to fix.)
spex
Honored Contributor

Re: no shell

Hi,

Make sure /usr and /usr/bin are both r-xr-xr-x.

PCS
lydi
Occasional Contributor

Re: no shell

Thanks for your help.