All about Unix groups and access control.

learn more… | top users | synonyms

10
votes
2answers
487 views

How do I grant different permissions for each user?

So, I've been using Linux for a few years now, and I really should know this answer, but I'm having trouble finding it. Specifically I've been using Debian based distro's....mostly Ubuntu. If I have ...
2
votes
0answers
23 views

Ubuntu and web server permissions

I am going to ask a question that has already been posted many times but even though I have read many guides and posts, I still have doubts. I have a server with ubuntu 14.04 on which I have a user ...
0
votes
1answer
22 views

Does LDAP take care of all users and groups on a system?

I have been following the tutorial here to try out LDAP. I know that a Linux system has groups like mysql, sudo, video, dial-out etc. Do I need to add these to my directory? Are these served via LDAP ...
5
votes
0answers
35 views

systemd user cannot get user group's ability

I added a non-root user in docker group, and an other service run as this non-root user connect to docker daemon. but the service can not work. I do a test example for this : root@# systemctl start ...
0
votes
0answers
28 views

access denied for folder in NFS share possibly for new users only. Why? [closed]

On a one of our NFS filers, a user is unable to access the folders having group ownership and permissions. $ id -a uid=3234243(user1) gid=18027(sv_users) groups=18027(sv_users),18606(lts) $ls -ld /...
0
votes
1answer
31 views

How do I add a user to a group

How do I add a user to a group. This is on a system with no root password and only a single user pi with sudo privileges. usermod seems to have been designed to make this as difficult as possible.
0
votes
1answer
31 views

Unix winbind groupmap

i got Linux server (SLES 12) joined in Windows AD with winbind and samba services. I got unix group "mqm" and windows AD group "67uts-mq-admins". I want to map windows AD to unix group with "net ...
0
votes
0answers
20 views

How to prevent special group to delete files or folders?

Folder path: /var/www/html group name: "ftpusers" user: "admini" How to prevent from group "ftpusers" to delete files or folders in html folder, but allow them to create files or folders? User "...
0
votes
1answer
35 views

Centos, uploaded files from application have different owner and group [duplicate]

I have an application that uploads a file via SFTP using sftpuser. Once the file is uploaded the owner and group is user1:user1. The owner of the parent directory is apache:apache. I can not figure ...
0
votes
0answers
13 views

What will be the result when USERGROUPS_ENAB is set to no in /etc/login.defs and no groupname is specified when using the commnd useradd

The default command when we add a user is: sudo adduser -m -g initial_group -G additional_group -s login_shell user_name In /etc/login.defs USERGROUPS_ENAB is set to yes by default This means ...
0
votes
0answers
36 views

Does changing your OS (fedora>OpenSuse) or FS (ext4>btrfs) “break” rsync?

I am using a rather simple script to do incremental backups of my laptop to my external HDD's, where the core line is probably the following: rsync -arbuv --delete --progress -exclude-from=/backup-...
1
vote
0answers
29 views

Cannot add group on RHEL desktop

Question: why does the groupadd fail here? Is it related to SELinux or maybe a bug? I found the mv /etc/group+ /etc/group problem via strace groupadd.. [root@notebook ~]# groupadd testing groupadd:...
3
votes
2answers
94 views

Meaning of the colon and x in getent group

I'm new to Linux and I came across the command getent group sudo to list sudoers in sudo group and I got the output sudo:x:27:lion now I wounder what is the meaning of :x:, colon and 27 ... also I see ...
0
votes
3answers
42 views

Is group priority available?

[tjm@ArchPad bin]$ LANG=en [tjm@ArchPad bin]$ pwd /usr/bin [tjm@ArchPad bin]$ ll | grep wireshark -rwxr-x--- 1 root wireshark 88K Apr 25 00:22 dumpcap -rwxr-xr-x 1 root wireshark 2.0M Apr 25 00:23 ...
1
vote
1answer
10 views

Significance of groups assigned to user by Debian installer (only)?

I want to remove my default user from the sudo group. IOW I want to change it to an unprivileged account. However it also seems to be a member of ten other system groups. What is the overall ...
0
votes
1answer
62 views

Cannot Bash chgrp GROUP /home/*/SOMEFILE/ How to do it?

So am setting a code that will change group owner of the file to a specific group. PS there are more than 10 users, with same folder and file structure, and i want change the ownership of a specific ...
0
votes
1answer
70 views

usermod -a -G group user not work [duplicate]

I use Ubuntu 12.04. I am trying to add the user gefalko to the www-data group. I use root@xxx~# usermod -a -G www-data gefalko If I understand correctly, I should now see www-data in the output of ...
1
vote
1answer
34 views

Linux, having trouble adding user to second group

Redhat Linux 5.10 (Tikanga) I'm trying to add an existing user to a second group. The user is already part of the primary group called "prim" and the secondary group I want to add him to is "sec". I'...
1
vote
1answer
49 views

Where does Linux track who is a group admin through the gpasswd command?

If I modify group membership and admins using the gpasswd command and add a user as a group admin Linux will allow that user to perform tasks otherwise reserved by root. Ex. [test1@centos ~]$ ...
0
votes
0answers
17 views

useradd failing [duplicate]

Debian 8, I'm trying to allow a user to run Wireshark. user1@system:~$ sudo useradd -G wireshark user11 useradd: user 'user11' already exists However: user11@system:~$ groups user11 cdrom floppy ...
3
votes
2answers
103 views

Primary and secondary groups

So I've got the basics of primary and secondary groups down, but still have some questions I can't seem to find solid answers to: Can many users belong to the same primary group? Can one user's ...
1
vote
5answers
60 views

Show a user exists command

Is there a command that shows a user exists and is assigned to a group? I have just used the command usermod -a -G [GROUP] [NAME OF USER] and assigned a user to a group but, I was wondering if there ...
1
vote
1answer
58 views

How to avoid that Geany editor changes owner of file when it's edited?

I use Geany to edit files in a web app that resides in /var/www. The owner and group of /var/www and all sub directories and files are www-data:www-data. My user account is a member of that group and ...
1
vote
3answers
88 views

Predefined group ids across Linux distros?

In order to successfully implement w/r access via ACL for external storage with ext4 fs I need to assign default group id for files on storage. LSB_5.0.0 say: This specification makes no attempt to ...
0
votes
1answer
63 views

trouble understanding GID and chmod g+s

I am having trouble understanding the GID and the command chmod g+s I read this as setting the permissions of the passed file or directory, for the group, as +s (sticky im assuming?) Does the +s mean ...
1
vote
2answers
69 views

Why do you have to be a member of a group to make that group the group owner of your file?

In unix, I know that you have to be a member of a group to change the group owner of a file to that group even if you own it, but can someone please tell me why. I don't understand why you shouldn't ...
1
vote
2answers
64 views

Files are created with old group ownership even though the creator doesn't belong to old group anymore

I am currently preparing for LPIC Level 1 exam and I have been practicing management of user accounts on CentOS 7 system installed on VirtualBox. Firstly, as root, I created a user 'foo' with group '...
1
vote
2answers
64 views

How can I create a sub-directory where my group has no write permissions?

I am working in my Tomcat deployment directory. The files in the directory have the permission: drwxrwsr-x. 10 tomcat www 4.0K Mar 15 15:14 webapps A sample sub-directory within webapps looks ...
1
vote
3answers
146 views

File System Permissions: User who can backup all files

I am setting up an automated backup job for some computers on my network. There is a server that will, daily, run an rsync command to backup each of the other computers. I'd like the user that the ...
0
votes
1answer
30 views

What is each group's permissions, and what is the “ranking” of each group (most privileged to least)?

My question is basically the title, but for further clarification with the ranking part, I'm asking about who inherits permissions from who, along with any additional permissions for the group as well?...
0
votes
0answers
50 views

How to set correct user group rights to application running with java?

How to set correct user group rights to application using java? There is this scenario: 1) I have created user group and user (the same) - call it "groupgroup" 2) When I create a file with this ...
3
votes
2answers
63 views

Why are privs required to setgid() to supplementary groups

The various set*gid() system calls require privileges to change groups except in a very few cases. Changing primary group to one of the processes' supplementary groups does not appear to be one of ...
0
votes
1answer
81 views

Access from multiple users to same directory but can't change directory group to a common one

I need to give full access to user1 and user2 to this directory: drwxr-xr-- 3 oracle dba 4096 feb 9 23:16 scripts I can't change directoy group because probably that group is needed for other ...
0
votes
1answer
62 views

How can I add all my groups to a different user in bash?

I've got a user named foo. I'd like foo to have all the same group memberships that I do. I thought I was close, with this: sudo usermod -a -G $(id -Gn | tr " " ",") node4 The id piped to tr is ...
0
votes
2answers
50 views

How to count how many files belong to each user/group combination?

How to count how many files belong to each user/group combination? I need to do this for each user/group combination that exists, in each of the directory trees /etc, /usr, and /var.
2
votes
4answers
362 views

Can a Linux user have multiple primary user groups?

How many primary groups can an individual Linux user have? If they can have more than one, how does one go about assigning multiple primary groups to a user? If it's just one, what's the cause?
1
vote
1answer
170 views

Is there a whoami to find the current group I'm logged in as?

I'm trying to find my current logged in group without wanting to use newgrp to switch.
3
votes
1answer
144 views

What is the purpose of the 'ssh' group?

There is a system user named sshd on my system, and a group named ssh: $ cat /etc/passwd | grep ssh sshd:x:120:65534::/var/run/sshd:/usr/sbin/nologin $ cat /etc/group | grep ssh ssh:x:117: My guess ...
-2
votes
2answers
143 views

Delete all users and groups except root in debian

I would like to delete all users present by default on my Debian, but I wonder what can happen if I delete them... I am learning linux so I want to clean everything except root and play around with ...
1
vote
1answer
183 views

logrotate fails to rotate logs: error setting owner

Recently I've noticed that logrotate does not rotate my logs. user1@host:~$ /usr/sbin/logrotate /home/user1/logrotate.conf -v gives me an error: error: error setting owner of /home/logs/mylog.log.1 ...
1
vote
1answer
183 views

share encfs folder within the same group

given an encfs folder mounted under its own user, is it possible to permit read access to someone else (especially a system user), who belongs to the same group? For example user1 owns ...
1
vote
1answer
15 views

Access rights for directory, when you are a part of owner group [duplicate]

Right to the business, here is what I am trying to do foverzar@subsystem /home> ls -aln total 16 drwxr-xr-x 4 0 0 4096 Dec 12 23:07 ./ drwxr-xr-x 17 0 0 4096 Dec 4 13:51 ../ drwx-----...
1
vote
1answer
118 views

How to add users to Linux through a shell script

The shell script that I have to write has to create new users and automatically assign them to groups. This is my code so far: echo -n "Enter the username: " read text useradd $text I was able to ...
1
vote
1answer
479 views

Add multiple user to UNIX group in one line

On Centos 6.5 (and probably any) linux, I can create a group: sudo groupadd mygroup and add several users to it: sudo usermod -a -G mygroup userA sudo usermod -a -G mygroup userB sudo usermod -a -...
1
vote
1answer
118 views

group files into fixed-size chunks

Example: Say I have 20 000 images and I need to group them into folders in order to burn them to a CD (max 700MB / folder). General: I have N files and I need to group them into M groups, so that all ...
0
votes
1answer
60 views

Cannot edit visudo

I have to give my user permission to run sudo. I am using CentOs # uname -a Linux lab-hv1-centos1 3.10.0-229.el7.x86_64 #1 SMP Fri Mar 6 11:36:42 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux and have ...
1
vote
0answers
45 views

What command should I use to explicitly set list of groups and execute a command?

To execute a command as other uid, one uses su. The list of supplementary groups is not specified on command line, but instead read from configuration files (/etc/passwd, /etc/group), etc. Which tool ...
1
vote
1answer
108 views

How to switch a group without asking for a password?

In linux, there's two files where group definitions are specified. One of them is /etc/group and the other is /etc/gshadow. I want my regular user to be able to switch a group while starting a process ...
4
votes
2answers
468 views

Can users in a group access a file that is in another user's home directory?

I have 3 users A,B and C inside a group 'admin'. I have another user 'D' in whose home directory, there is a project folder. I have made D as the owner of that folder and assigned 'admin' as the group ...
1
vote
1answer
37 views

(vsftpd) uploaded file group

I'm creating an ftp server with vsftpd, and I've almost finished, the only thing remaining is when I upload a file (logged as an user U), the file belongs to a group which has the same name (so group ...