Dear All,

i have the linux machine. i am a admin(root) of the system. i have create a user yesterday. now i login user i saw this error.. pls help me...

-bash: /home/user/.bash_profile: Permission denied

do: ls -al /home/user/.bash_profile and paste the contents back here. It looks like your permissions are screwed up.

sk:~# cd ~test8
sk:/home/free/test8# chown root:root .bash_profile
sk:/home/free/test8# chmod 700 .bash_profile
sk:/home/free/test8# su - test8
-su: /home/free/test8/.bash_profile: Permission denied
test8@sk:~$ logout
sk:/home/free/test8# id test8
uid=1053(test8) gid=1004(free) groups=1004(free)
sk:/home/free/test8# chown test8:free .bash_profile
sk:/home/free/test8# su - test8
test8@sk:~$

In the above example I simulated and solved the issue you are likely encountering.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.