LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-08-2013, 12:56 PM   #1
vignesh_murali2003
LQ Newbie
 
Registered: Jun 2013
Posts: 24

Rep: Reputation: Disabled
Could not chdir to home directory


Could not chdir to home directory /net/tiger/home/vlad: Permission denied
-bash: /net/tiger/home/vlad/.bash_profile: Permission denied

all the users when I try to ssh have the same problem. But when I login from other system it is working fine. I checked with the permissions it is set correctly.
 
Old 06-08-2013, 01:57 PM   #2
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
Are you logged in as vlad when you get that error message? Can you post the output of
Code:
ls -l /net/tiger/home/
jdk
 
Old 06-08-2013, 02:43 PM   #3
vignesh_murali2003
LQ Newbie
 
Registered: Jun 2013
Posts: 24

Original Poster
Rep: Reputation: Disabled
ls: cannot open directory /net/tiger/home/: Permission denied

the permissions are 700 but when i set it to 755 it works. But for my company rules it should be 700

Last edited by vignesh_murali2003; 06-08-2013 at 02:45 PM.
 
Old 06-08-2013, 11:58 PM   #4
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
You didn't answer my question. Who owns the file/directory and who are you logged in as.
Mode 700 allows only the owner of the file/folder to read it. Mode 755 allows anyone to read it. I deduce that you are not logged in as the owner of the file/folder. If you log in as the owner of the file/folder then your command will succeed.
Got it?
jdk
 
Old 06-09-2013, 12:22 AM   #5
Madhu Desai
Member
 
Registered: Mar 2013
Distribution: Rocky, Fedora, Ubuntu
Posts: 541

Rep: Reputation: 153Reputation: 153
home directory must always be set to 755(rwxr-xr-x), and within that all individual users directories must be set to 700(rwx------).

Example:
Code:
$ ls -ld /home
drwxr-xr-x. 5 root root 4096 Jun  9 10:40 /home

$ ls -l /home
total 24
drwx------. 52 user1 user1  4096 Jun  9 10:21 user1
drwx------.  4 user2 user2  4096 Jun  9 10:42 user2
 
Old 06-09-2013, 01:46 AM   #6
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
You must be logged in as user1 to look at the user1 folder or chown to another owner
You must be logged in as user2 to look at the user2 folder or chown to another owner
jdk
 
Old 06-09-2013, 09:04 PM   #7
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
You need to be root to chown files/dirs.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Could not chdir to home directory; permission denied dmz1213 Linux - Newbie 6 09-03-2012 02:02 PM
ssh could not chdir to home directory pccdrussell Linux - General 27 08-24-2012 10:30 AM
[SOLVED] 'Could not chdir to home directory /home/[user]: Permission denied' arashi256 Linux - Newbie 25 11-11-2011 09:29 AM
can't chdir /export/home/user/ perky.nishi Linux - Newbie 5 08-23-2010 12:37 AM
NFS problem: "Could not chdir to home directory /home/USER: Permission denied" sumanc Linux - Server 4 07-22-2010 04:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:24 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration