Bug 24500 - ~/.profile needs +x permission
~/.profile needs +x permission
Product: Red Hat Linux
Classification: Retired
Component: bash (Show other bugs)
i686 Linux
medium Severity low
: ---
: ---
Assigned To: Bernhard Rosenkraenzer
David Lawrence
Depends On:
  Show dependency treegraph
Reported: 2001-01-21 07:11 EST by Dimitri Papadopoulos
Modified: 2007-04-18 12:30 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-01-21 07:11:53 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Dimitri Papadopoulos 2001-01-21 07:11:50 EST

Using the /bin/bash shell and a ~/.profile with the following permissions
	-rw-r--r--    1 papadopo papadopo      492 Jan 21 11:40 .profile
I get the following error message and ~/.profile is not executed
	bash: /home/papadopo/.profile: Permission denied
I do have a .bash_profile file as well
	-rw-r--r--    1 papadopo papadopo      230 Jan 13 23:27 .bash_profile
Running chmod +x ~/.profile fixes the problem. However this is not needed
for /etc/profile
	-rw-r--r--    1 root     root          567 Jun 11  2000 /etc/profile

This is unconsistent and the man page does not mention it
       When  bash is invoked as an interactive login shell, or as
       a non-interactive shell with the --login option, it  first
       reads and executes commands from the file /etc/profile, if
       that file exists.  After reading that file, it  looks  for
       ~/.bash_profile,  ~/.bash_login,  and  ~/.profile, in that
       order, and reads and executes commands from the first one
       that  exists and is readable.
Comment 1 Dimitri Papadopoulos 2001-01-21 07:30:22 EST
Aaargh, forget it!

This happens to an account which has a non-default broken ~/.bashrc which
is executed by ~/.profile and tries to execute ~/.profile again!

Sorry about that.

Note You need to log in before you can comment on or make changes to this bug.