Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm a little confused on how to get this working.

I have ACL working and I need to create two goups:

  • github-total: group that the users in that group have permissions to the folder "/var/git" to read/write/execute.
  • github-read: group that the users in that group have permissions to the folder "/var/git" to read.

For the group "github-total" I have done the following:

As "git" user:

$ cd /var
$ mkdir github
$ chmod 770 github
$ ls -al
drwxrwx---+  3 git git   4096 Oct  4 21:48 github

# useradd andre -m
# passwd andre
# groupadd github-total
# usermod -a -G github-total andre
# id andre
uid=500(andre) gid=500(andre) groups=500(andre),502(github-total) context=user_u:system_r:unconfined_t
# cd /var
# setfacl -R -m group:github-total:rwx github
# setfacl -R -d -m group:github-total:rwx github
# getfacl github
file: github
owner: git
group: git

Unfortunately this is not working for me, with user "andre", I cannot list "/var/github"

$ cd /var/github
bash: cd: /var/github: Permission denied

How can I list this folder adding a group to the ACL?

Best Regards,

PS: Sorry for my english...


I have found that if I do id without arguments with the user "andre" I got this:

$ id
uid=500(andre) gid=500(andre) groups=500(andre) context=user_u:system_r:unconfined_t

The group "github-total" is not included as a group for user "andre"

If I do:

$ id andre
uid=500(andre) gid=500(andre) groups=500(andre),502(github-total) context=user_u:system_r:unconfined_t

What does this mean?

share|improve this question

migrated from Oct 6 '11 at 7:16

This question came from our site for professional and enthusiast programmers.

possible duplicate of How to get ACL to allow group to have permission to folder – grawity Feb 1 '12 at 12:40

Your ACL is correct, so that's not the problem. I think it's a problem with andre's group membership.

If you add a user to a group while the user is logged in, the group membership won't take effect until the user logs out and back in. Try logging out and back in and see if that works.

By the way, when you create the group "github-read", the group will need both read and execute permissions on the directory, not just read permission. I don't know if you already knew that, but I thought it would be best to tell you anyway.

share|improve this answer

What is the mode of SELinux? If you are running "enforcing" then you will have to adjust the context of the folder you have created. Run command sestatus and if it is enabled then temporarily turn it off with setenforce 0 and see if you can access the folder.

For CentOS, RedHat or Scientific Linux this link should help CentOS SELinux Wiki

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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