0

So I'm adding a new user on a machine to give a family member some remote storage. After setting up their login and home directory. Here's the stat

  File: `/home/heather'
  Size: 4096        Blocks: 8          IO Block: 4096   directory
Device: 831h/2097d  Inode: 89128961    Links: 3
Access: (0755/drwxr-xr-x)  Uid: ( 1002/ heather)   Gid: ( 1004/ heather)
Access: 2014-09-09 17:57:37.059406231 -0400
Modify: 2014-09-09 17:37:32.449432887 -0400
Change: 2014-09-09 17:57:22.939336208 -0400

But they are not able to access it from either local or ssh

$ echo ~
/home/heather
$ cd ~
bash: cd: /home/heather: Permission denied

Unless I'm missing something big, the permissions seem fine.

Please note I've only ever run single-user setups before, I can't find anything similar to this after a good 20 minutes of searching, please don't crucify me if I've overlooked something simple.

migrated from serverfault.com Sep 9 '14 at 23:09

This question came from our site for system and network administrators.

  • What is the output of finger heather command? – Ramesh Sep 9 '14 at 23:14
  • Login: heather Name: Directory: /home/heather Shell: /bin/bash Last login Tue Sep 9 18:45 (EDT) on pts/10 from [snip] No mail. No Plan. – user2085282 Sep 9 '14 at 23:15
  • What are the permissions on /home? – yoonix Sep 9 '14 at 23:17
  • I believe the execute permission might not be set which is causing the issue. So probably, do a chmod -R 755 /home/heather as a root user and then try again. – Ramesh Sep 9 '14 at 23:18
  • 1
    chmod 755 /home should fix this. – Warwick Sep 9 '14 at 23:49
1

Run chmod 755 /home and this should be fixed. Gilles answer here is worth looking at for a full explanation of this.

0

UNIX knows effective users/group with uid/gui not name. So check id and gid of your home directory.

   stat --printf=%u /home/heather  #####print uid of your home dir 
   stat --printf=%g /home/heather  #####print gid of your home dir

Then check with /etc/passwd and /etc/group :

egrep heather /etc/passwd
egrep heather /etc/groups

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.