Bug 20781
Summary: | Xsession script should be sure session runs as child of user's shell (as a login shell) | ||
---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | dkaplan |
Component: | xinitrc | Assignee: | Mike A. Harris <mharris> |
Status: | CLOSED RAWHIDE | QA Contact: | Dale Lovelace <dale> |
Severity: | medium | Docs Contact: | |
Priority: | high | ||
Version: | 7.0 | ||
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | i386 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2001-07-19 22:15:39 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
dkaplan
2000-11-13 19:39:48 UTC
I also see the behavior described in the second part. Interestingly, it appears that *some* of the scripts in /etc/profile.d are being executed and some are not. In particular, the variables set and exported by gnome-ssh-askpass.sh, kde.sh, less.sh and qt.sh are actually set, but the aliases created by colorls.sh and which-2.sh are not set. I tried defining a variable in colorls.sh and verified that it was not set. If I log in on a console, $SHLVL is 1 but colorls.sh is executed. If the user's shell is tcsh, the corresponding .csh files in /etc/profile.d *are* executed. So this seems to occur only in the combination of bash and gnome-terminal started from the Gnome panel in runlevel 5. I also note that every other way I can think of to start a terminal (xterm, rxvt, kterm fro the Gnome menu, anything from the comand line, startx from runlevel 3, etc) sets $SHLVL greater than 1. For the record, I don't see the behavior described in the first part. In fact my mouse cursor doesn't move at all when I change focus with Alt-Tab. The Alt+Tab thing is a "feature", anyhow it's configurable (look around in the Sawfish control panels). If SHLVL is not 1 then we appear to read /etc/profile from /etc/bashrc. I don't understand why gnome-session launches terminals with SHLVL of 1. Investigating that. The problem is basically that gnome-session blows away the environment before launching apps. *** Bug 37234 has been marked as a duplicate of this bug. *** I was on crack about gnome-session and the empty environment. The problem is simply that /etc/X11/xdm/Xsession should do: exec -l $SHELL -c 'foobar --frobate' instead of: exec foobar Fixed in rawhide for a while now. |