No prompt after login

Some of my Unix accounts no longer give me a prompt after entering userId and password - I see
output, but never get a prompt from which to work.

Why is that??

Please elaborate - THANKS.
booksplusAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

JackOfAll1Commented:
It sounds like the profile file or files are hosed.  

In AIX check /etc/profile or the /home/user/.profile

add PS1='$PWD: '

or what ever is appropiate for your OS.

Hope this Helps.
0
booksplusAuthor Commented:
.profile is fine - same as other .profile 's that are working (login with prompt).

If I type ctrl-c - I get my prompt - but I shouldn't have to do that - anymore ideas.
0
JackOfAll1Commented:
If you have to type cntrl-c to get your prompt it sounds like a script is being invoked during the login that is not completing.  The cntl-c is exiting the script.
0
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

booksplusAuthor Commented:
There's no script in the .profile - I added an output (echo) statement as the last line
in the file and it outputs fine.

Any other ideas??
0
JackOfAll1Commented:
Are you invoking a new shell in either the profile or .profile scripts?
0
stefan73Commented:
Hi booksplus,
> .profile is fine - same as other .profile 's that are working (login
> with prompt).

> If I type ctrl-c - I get my prompt - but I shouldn't have to do that
> - anymore ideas.

Did you do some blocking commands, such as a single "cat"?

Cheers!

Stefan
0
ahoffmannCommented:
>  I added an output (echo) statement as the last line in the file and it outputs fine.
you mean that ~/.profile contains a echo as last statement which you see after login, but no prompt follows?
0
booksplusAuthor Commented:
ahoffman -

Yes - that is correct.  

my PS1 is fine too (same as other .profile 's and I do get promt after I do crtl-c)

Using Korn and not invoking anyother shell.

stegan73 - sorry, but not sure what you mean by single "cat"

jackOfAll - using Korn shell
0
mike_mianCommented:
>If I type ctrl-c - I get my prompt - but I shouldn't have to do that - anymore ideas.

This implies you have a process that is running and for some reason hanging?
Have you made any edit to your profile recently?
Have the machines you are logging onto be upgraded/changed recently?
Could be a prboem with automounting a drive that has been removed that you explicitly
tryi to acces during  login.
type:
set -v
set -x
in your .profile

that should tell you where things are stopping.
0
mike_mianCommented:
>Did you do some blocking commands, such as a single "cat"?

he means did you  add the line
cat in you strat -up script (eg .profile) as this would cause the out put to wait/block for input.

I f you do the above you will see if you accidently did this, or aleast see the commant that is blocking.
0
ahoffmannCommented:
please post /etc/.profile (without comments and empty lines)
0
yuzhCommented:
Also check /var/adm/messagess file to see if there is any problem with NFS server.
0
booksplusAuthor Commented:
       trap "" 1 2 3
        PATH=/usr/bin:/usr/ccs/bin:/usr/contrib/bin
        MANPATH=/usr/share/man:/usr/contrib/man:/usr/local/man
        if [ ! -d /usr/sbin ]
        then
                PATH=$PATH:/sbin
        else    if [ -r /etc/PATH ]
                then
                        grep -q -e "^/usr/bin$" -e "^/usr/bin:" -e ":/usr/bin:"\
                                -e ":/usr/bin$" /etc/PATH
                        if [ $? -eq 0 ]
                        then
                                PATH=`cat /etc/PATH`
                        else
                                PATH=$PATH:`cat /etc/PATH`
                        fi
                fi
        fi
        export PATH
        if [ -r /etc/MANPATH ]
        then
                MANPATH=`cat /etc/MANPATH`
        fi
        export MANPATH
        if [ -r /etc/TIMEZONE ]
        then
           . /etc/TIMEZONE
        else
            TZ=MST7MDT               # change this for local time.
            export TZ
        fi
   if [ ! "$VUE" ]; then
        if [ "$TERM" = "" -o "$TERM" = "unknown" -o "$TERM" = "dialup"  \
             -o "$TERM" = "network" ]
        then
                eval `ttytype -s -a`
        fi
        export TERM
        if [ "$ERASE" = "" ]
        then
                ERASE="^H"
                export ERASE
        fi
        stty erase $ERASE
        trap "echo logout" 0
        cat /etc/copyright
        if [ -r /etc/motd ]
        then
                cat /etc/motd
        fi

        if [ -f /usr/bin/mail ]
        then
                if mail -e
                then    echo "You have mail."
                fi
        fi
        if [ -f /usr/bin/news ]
        then news -n
        fi
        if [ -r /tmp/changetape ]
        then    echo "\007\nChange backup tape."
                rm -f /tmp/changetape
        fi
   fi
   trap 1 2 3
umask 022

0
JackOfAll1Commented:
I do not see a problem with the .profile.  I cut and pasted it in a new user I set up here and everything worked file.  

Did you check the /etc/profile?
0
JackOfAll1Commented:
Also did you change the .profile to include the
set -x
set -v
and then signon?

What did it show?
0
booksplusAuthor Commented:
yep - The profile posted is from etc.  

I tried (in my personal profile)

set -x
set -v

but my personal profile executes all the
way through to the last echo statement -  then hangs until I type ctrl-c.

0
JackOfAll1Commented:
I am not sure what to try next.  You have eliminated all of the common problems.

I would try.

renaming your .profile and signoff, signon and see if you still have the problem.  If you do the problem is in the /etc/profile if not it is in the .profile.  

After you determine what file the problem is in then I would comment out all the statements and then uncomment and try and repeat until I determine what statement is causing the problem.

I still believe that you have a process running.  It can be invoked from anywhere within the profile scripts or any scripts they invoke.  The fact that your echo at the bottom of your .profile is working does not mean that a process was not launched.  It only means that after a process was invoked the scripts continued.  

Sorry I can not give a direct answer.
   

 
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
booksplusAuthor Commented:
JackOfAll1 - thanks.  Appreciate your input.  I'll leave this open for  a day or two
more to see if there is any other input.  I'll close and award points after that.

Thanks!
0
yuzhCommented:
you debug /etc/profile .profie, you can do:

set -x
. /etc/profile
. /home/booksplus/.profile

Note: there is a WHITE SPACE between the DOT and /
         have you checked  /var/adm/messagess file ?
0
mike_mianCommented:
type alias  to see if any of the standard commands have been changed to something that might block/wait?
0
ahoffmannCommented:
please check if your profile hangs also using yuzh's suggestion http:#13541074
0
booksplusAuthor Commented:
yuzh - typing
set -x
. /etc/profile
. /home/booksplus/.profile

works fine.  By "works fine" I mean it does not hang.  I still hang upon login, but
after I type ctrl-c a few times and get a prompt, then your suggestion works.

There is no /var/adm/messages file.

alias yields the following
autoload=typeset -fu
false=let 0
functions=typeset -f
integer=typeset -i
rm=rm -i
stop=kill -STOP
type=whence -v
hash=alias -t -
history=fc -l
nohup=nohup
r=fc -e -
suspend=kill -STOP $$
true=:
0
tfewsterCommented:
From the format of the .profile (& the reference to "VUE"); I'd guess that this is HP-UX - The system log will be /var/adm/syslog/syslog.log

If Ctrl-C works, that implies the .profile has finished (as the `traps` are no longer active)  - Tho' I can't see what "echo" commands you've put in to test where it is up to?

Please put a line `echo "ENVFILE"='$ENV` as the _last_ line in the .profile of one of the "problem" userids, to see if ksh executes another file after .profile is finished  (man ksh for more info on startup files)
0
yuzhCommented:
put:
set -x

as the first line of your .profile and login again, see where the login script hang.

BTW, which version of OS are you using, post the output of "uname -a".
     
0
booksplusAuthor Commented:
yuzh - I've done "set -x" and the weird thing is that the start up script runs
to the last line (last echo statement outputs successfully) but then hangs from
there.

HP-UX B.11.00 U 9000/800

I appreciate all the help - I'm going to close and split points tomorrow and
pass this problem off to another department.  THANKS
0
yuzhCommented:
Do you mean it run to the last line of /home/booksplus/.profile and than hang? that's weird!

when you type in Ctrl-C, and type in:
pwd

can you see your home dir?, if not, check your NFS mount.

PS: your /etc/profile is the default file from HP-UX.
0
booksplusAuthor Commented:
>when you type in Ctrl-C, and type in:
>pwd

Yes (I see my home prompt after typing ctrl-c a few times).
0
yuzhCommented:
anything in /var/adm/syslog/syslog.log ?
0
booksplusAuthor Commented:
yuzh - no errors - I'll add a solution if I find anything in house.  THANKS everyone.
0
ahoffmannCommented:
in http:#13534286 you posted /etc/profile, can you please post you  /home/booksplus/.profile too
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Unix OS

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.