Red Hat Bugzilla – Bug 164112
ksh not run as login shell when logging in via gdm
Last modified: 2007-11-30 17:11:10 EST
Description of problem:
Logging this on behalf of a GLS customer, tho I can reproduce this here.
Logging in via gdm does not run a login shell for ksh users. Instead a non-login
shell is run. The users ~/.profile script is never run.
Steps to Reproduce:
1.Pop something in a users .profile.
2. Log into X
The .profile is never run.
gdm should start a login shell, as it does with other shells, and as other login
apps do for ksh.
The session start up scripts do:
exec -l $SHELL -c <the session scripts>
There is a convention amoung shells that if the shell is invoked with the first
character of argv as - (and then the normal argv) then the shell should
execute as a login shell.
It's possible ksh doesn't follow this convention. If it doesn't it should be fixed.
from the ksh manpage:
If the shell is invoked by exec(2), and the first character of argument
zero ($0) is -, then the shell is assumed to be a login shell and com-
mands are read from /etc/profile and then from either .profile in the
current directory or $HOME/.profile, if either file exists.
I've added an echo in /etc/profile and ~/.profile to see if ksh runs those
hagen:[~] >exec -l ksh -
Looks ok to me.
Mike have you tried test3? if so, do you still see this problem?
Closing due to lack of response.