Bug 72262
| Summary: | .bashrc evaluated before /etc/profile.d/ in xterms | ||
|---|---|---|---|
| Product: | [Retired] Red Hat Linux | Reporter: | Keith Howanitz <howanitz> | 
| Component: | gnome-core | Assignee: | Havoc Pennington <hp> | 
| Status: | CLOSED RAWHIDE | QA Contact: | Mike McLean <mikem> | 
| Severity: | low | Docs Contact: | |
| Priority: | medium | ||
| Version: | 7.3 | ||
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2002-08-29 23:03:23 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
        
        
          Keith Howanitz
        
        
        
        
        
          2002-08-22 15:31:06 UTC
        
       hp: How does gnome launch its shells? This works just as intended in KDE... works fine in gnome for me too, in rawhide. In 7.3 if it doesn't work I'm not sure what's wrong... maybe you need to toggle the "--login" or "login shell" option in gnome-terminal preferences. The .bashrc in /etc/skel sources /etc/bashrc, which in turn sources the scripts
in /etc/profile.d.  Is it possible that these lines are still in your .bashrc
and occur after your modifications?
Experimenting with strace reveals the following order of access in various
situations:
bash --login
  /etc/profile
  ...which in turn sources /etc/profile.d scripts
  ~/.bash_profile 
  ...which in turn sources ~/.bashrc
     ...which in turn sources /etc/bashrc
        ...which in turn sources /etc/profile.d scripts again
  yes, only /etc/profile and ~/.bash_profile are sourced directly in this case.
If you remove this line from .bash_profile, ~/.bashrc (and hence /etc/bashrc)
will not be sourced in this case.
bash -norc
  none of these files are sourced
bash
  ~/.bashrc is sourced
  ...which in turn sources /etc/bashrc
     ...which in turn sources the /etc/profile scripts
In *all* of these cases, user controlled config files have the final say.
 |