Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

.bash_profile is not being executed

Posted on 2007-04-10
1
Medium Priority
?
506 Views
Last Modified: 2013-12-06
The .bash_profile is not being executed when we are invoking the bash profile.

To execute this shell script I have to specifically run

. .bash_profile

Then only the commands in .bash_profile is being executed.
How to make .bash_profile to be executed when we call the bash shell?


OS: Red Hat Enter PRise linux Advanced Server4
0
Comment
Question by:durgap
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 58

Accepted Solution

by:
amit_g earned 2000 total points
ID: 18884191
~/.bash_profile is executed only if the shell is a login shell i.e. when you log in or bash is invoked with --login option. Also it should be in the HOME directory. When is it not executed?
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you use Debian 6 Squeeze and you are tired of looking at the childish graphical GDM login screen that is used by default, here's an easy way to change it. If you've already tried to change it you've probably discovered that none of the old met…
This article will explain how to establish a SSH connection to Ubuntu through the firewall and using a different port other then 22. I have set up a Ubuntu virtual machine in Virtualbox and I am running a Windows 7 workstation. From the Ubuntu vi…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question