Tagged Questions

Permissions are the unix way of controlling access to resources such as files, directories and devices and may be specified for an owner, group, or all users.

learn more… | top users | synonyms (1)

3
votes
2answers
123 views

Is there a way to protect a file from being deleted, but not from being altered?

I want certain files to be able to be altered by myself on my basic account. To me, they are high priority files, with many backups. But we have some young'uns in the house and I don't quite trust ...
0
votes
0answers
18 views

Vagrant user permissions

What I like about vagrant is that all the permissions work out of the box when provisioned with Puppet. However I can't get the same permissions to work on my digitalocean droplet. On my vagrant box, ...
1
vote
1answer
46 views

How can a user be prevented from changing a file that has write permissions for other users?

An odd situation came up recently. User1 needed to be able to change files in a directory were the files and the directory were owned by User2 and in group User2. In order to facilitate this ...
1
vote
0answers
40 views

Cron can't access my home directory when I'm logged out

I have quite a strange problem using cron. I distilled it thus far: I created following simple bash script in /home/user1/cron_dir/cron.sh: #!/bin/bash echo "Success" As user1 I created following ...
1
vote
2answers
43 views

Fedora: How can I add myself back to sudoers file?

I've accidentally removed myself from sudoers file by doing usermod -G user group without -a, and now I am not in the sudoers group. I've tried doing su - and entering root's password but it says su: ...
0
votes
1answer
10 views

centos folder permission ftp user and apache

I have some folder, need anybodies php scripts can create sub folder/files and unlink files. I do sudo chown -R apache:apache /var/www/public_html/a But after that, my ftp user cannot upload files ...
1
vote
1answer
36 views

What is the cause of this error: Error: EACCES, permission denied

I have two three users: db, nr, ba All three are members of the group dbp Node.js is installed in /usr/bin If I run the command : /usr/bin/node /home/db/dbb/m/i.js Then it works fine when I run ...
0
votes
1answer
16 views

How to enable a non-root user to empty the linux buffer cache

I'm required to empty the linux buffer cache in a python script, that runs on a Debian wheezy VM. As root I run sync; echo 3 | sudo tee /proc/sys/vm/drop_caches, but the script is run by a user, ...
-4
votes
0answers
40 views

unable to “touch” files and “mkdir” directories being any other user other than root in /

I logged in as a user called "srv1" and tried to create a file and directory called "a22" inside "/" but i got an error message as touch: cannot touch 'a22': permission denied and same for ...
1
vote
0answers
7 views

EACCESS writing /proc/self/oom_score_adj [migrated]

I'm trying to compile "slock" to implement some tweaks. It fails to start, on this: #ifdef __linux__ #include <fcntl.h> static void dontkillme(void) { int fd; fd = ...
0
votes
0answers
26 views

Linux file and directory permissions for newbees? [closed]

I'm missing some basics on that topic and can't find a good logical explanation. Maybe the question is already so trivial that no documentation does really care to explain it in detail. I'm looking ...
4
votes
2answers
31 views

How to run an application with certain group permissions?

I have a 3D printer, with which my PC can communicate through /dev/ttyACM0: crw-rw---- 1 root uucp 166, 0 16 nov 14:58 ttyACM0 The 3D printing application repetierHost requires read/write access ...
1
vote
1answer
14 views

UMASK privacy- how can I make user files private to the users

I have a debian virtual machine set up and thought of something in regards to UMASK. First I would like to ask if the function of UMASK is to set CHMOD values on any file created by a user. Secondly, ...
1
vote
1answer
34 views

How to allow users to copy files with different user and group?

Good Day, There is a linux user and group called "developers" (has no sudo access) with home folder in "/home/developers". There is nginx running on the same server, there is a web folder for a ...
2
votes
1answer
25 views

Why is my pip-installed Python script not executable for everyone?

In my Vagrant instance: vagrant@archlinux:~$ sudo pip2 install vcard Downloading/unpacking vcard Downloading vcard-0.9.tar.gz Running setup.py (path:/tmp/pip_build_root/vcard/setup.py) egg_info ...
1
vote
1answer
45 views

chmod: cannot access 'file' : No such file or directory error when the file exists

I downloaded and saved 2 files on Linux tails live os. I have set the appropriate permissions on those 2 files to allow them as executable. This is the command I used. sudo chmod 777 ...
0
votes
1answer
46 views

How do I search for every file with executable permission (+x) in my system? [duplicate]

I need to find every single file that has executable permissions in my system, i think they end with x@. I tried to ls every file and then grepping the output to match files with x@. Like this: ls ...
1
vote
1answer
34 views

Delete a directory under Cryptkeeper without access to its account

I have a computer with read-write permissions for one of it is directories. I lost the password that can help me to log in to that directory. How can I delete this folder. I am using the following ...
3
votes
4answers
77 views

Forcing owner on created files and folders

I have a directory that contains data shared between a number of users. Access to this directory and anything underneath, will be controlled by the directory's group, which will be added to the users ...
0
votes
2answers
29 views

Automatically set group and permissions on files in a folder? [duplicate]

When I create new files and folders in a specific folder, I would like them to inherit the group and permissions of the parent folder. Is this possible ? For example mkdir -p example.com/public cd ...
0
votes
2answers
55 views

Permission denied when run script via ssh

I wrote script which download via scp and install some packages. SSH keys are added to host and when I run [root@HostB ~]# ./myscript everything is ok and packages are downloaded via scp without ...
9
votes
1answer
596 views

What is the difference between 'ls' and 'ls -l' when I don't have execute permission on that directory?

I created a directory called folder and took away execute permission. $ mkdir folder $ touch folder/innerFile $ mkdir folder/innerFolder $ chmod -x folder Now if I do $ ls folder it outputs a ...
4
votes
1answer
39 views

rsync doesn't preserve directory ownership even with -a

I use this rsync invocation to backup my home directory: rsync -aARrx --info= --force --delete --info=progress2 -F "$USER_HOME" "$BACKUP_MNTPOINT" rsync man page says that -a implies -g and -o ...
1
vote
2answers
13 views

facl ignoring the “x” permission but only on files

When I use setfacl to manage on what permissions should the children files / directories have, for some reason the files have all the permissions except the execute ("x") one. ...
1
vote
1answer
40 views

Installing packages on multiple Centos machines

I have to install standard package like java 1.7 in 40 of my lab machines which are connected over a LAN. I know I can simply write a shell script to install something in user space of each system, ...
1
vote
1answer
18 views

Grant rights to create / manage users

Is there a way I can grant a user or a group the permission to add/edit other users without the ability to alter anything else on the system? The idea is to give helpdesk agents the ability to grant ...
2
votes
1answer
66 views

How do I mount a Windows folder on Linux (with Samba) and see the correct permissions?

I have a Windows 7 box and a Linux machine. I can correctly access the files on the Windows machine from the Linux machine. however, when I look at the permissions from Linux and from Cygwin on my ...
2
votes
1answer
54 views

In a Virtualbox VM how do I set the filesystem permissions?

I have a virtualbox VM with arch Linux running on my windows PC (which I unfortunately have to use for work). I use this to work on my windows PC with a Linux environment as an alternative to Cygwin. ...
1
vote
0answers
29 views

PHP: Check if script is being ran with sudo or if user is not using `php` [migrated]

How to make a check to find whether the script is run with sudo access or not using PHP ?
2
votes
1answer
35 views

Single user for sharing vs. multiple users

In my lab, a group of people work each at one workstation, and they share a number of drives over NFS. They run shared software residing in one of those NFS drive and they run it on the NFS drives ...
2
votes
3answers
100 views

print the /etc/shadow file in the console

How do I change the permissions of an executable file to access the /etc/shadow file? So far I have the following bash script: #!/bin/bash gcc print.c -o print chmod +s print ./print exit 0 and ...
0
votes
0answers
47 views

How to set up the permissions using the CUPS backend?

I'm trying to write a script that takes command line parameters and parameter order, formats the output from CUPS server backend query, and configure the permissions and locations to install the ...
1
vote
1answer
31 views

Permissions for /etc/ssmtp/ssmtp.conf

I'm just starting with my own Virtual Server (and Linux). I've an apache2 and a few wordpress sites. I need to send mails via PHP (contact forms). I managed to install ssmtp with the help of a few ...
0
votes
0answers
29 views

How to correct Linux file system permission?

I've recently install Elementary OS on my PC and i mistakenly installed a program named "mount management", apparently it changed my file-system permission or i guess it does (because i checked theme ...
1
vote
0answers
48 views

How to gain ownership of external HDD (and all files/folders) mounted to /mnt

I've plugged in a USB Hard Drive to my new Debian Jessie machine. I've got it to auto-mount by updating /etc/fstab: UUID=21AE-9B96 /mnt/local/ext001 vfat defaults 0 2 ...but it's owner is root and ...
0
votes
1answer
25 views

What permissions should each file under .ssh have?

What permissions should each file under .ssh have? I just experienced some glitch caused by .ssh/config not having 600. What permissions other files there should have?
5
votes
3answers
393 views

Why is dd not protected against writing on the active disk ?

I use dd a lot. I live in a contant fear of making a mistake one day, for example writing on sda (computer disk) instead of sdb (USB disk) and then erasing everything I have on my computer. I know dd ...
1
vote
1answer
35 views

Moving physical disk from local computer to network server

In my Debian GNU/Linux based workstation I have a big nice disk (3TB), apart from my ssd where the OS is installed. I recently got an intel nuci5 and set it up as a home server, together with my ...
0
votes
1answer
40 views

What has priority - owner/user vs group permission? [duplicate]

I have just run into the case in which the owner-group of a file has more permissions than the owner-user of a file. user1@pc:/tmp$ ls testfile -l ----rw---- 1 user1 user1 9 Okt 16 13:16 testfile ...
1
vote
1answer
40 views

Noip “Can't locate configuration file”, but the file is there

I installed Noip and ran the command which created the config file /usr/local/bin/noip2 -C and then I ran the run command /usr/local/bin/noip2 and it returned Can't locate configuration file ...
1
vote
0answers
22 views

Granting access permission to normal user to a logical volume of a volume group [duplicate]

When I need to run a program with direct disk access, like read/write from /dev/sdb, I simply add the user to 'disk' group. In this way we don't need to disclose the root account the the user. However ...
2
votes
0answers
24 views

Maildir permissions for courier

I'm having difficulty with maildir permissions for Courier, an IMAP server I've installed on a box running Debian Wheezy. The mail directory I use is /var/mail/users, with the following permissions: ...
-4
votes
1answer
26 views

Arrange for files created in a directory to belong to the directory's group

How do I set permissions so that whoever creates any files or directories in /directory, the group owner should automatically be the same group owner of /directory? This is on RHEL.
0
votes
1answer
79 views

Grant FTP access to specific directory

I have setup CentOS on a box on my local network and installed httpd, PHP, Webmin (and UserMin) etc. I opted for ProFTPd and have opened up ports for FTP, Webmin and Apache. I can now access Webmin ...
2
votes
1answer
47 views

Is there a way to prevent git from changing permissions and ownership on pull?

Everytime I do git pull or git reset, git resets changes to permissions and ownership I made. See for yourself: #!/usr/bin/env bash rm -rf 1 2 mkdir 1 cd 1 git init echo 1 > 1 && git add ...
0
votes
2answers
42 views

Do I need to chmod 777 mounted volumes?

I have an openstack VM with the following users: [foo@influxdb ~]$ id root uid=0(root) gid=0(root) groups=0(root) [foo@influxdb ~]$ id foo uid=500(foo) gid=500(foo) groups=500(foo),10(wheel) ...
2
votes
1answer
63 views

can't execute a command even i'm in the group and command is -rwx--x---

I'm in $ORACLE_HOME/OPatch directory and when I type opatch then I get the response as, -bash: opatch: command not found If I do ./opatch, then I get the response as, /bin/sh: ./opatch: ...
0
votes
3answers
22 views

Setting global browsable permissions for subdirectories (r-x) but making files inaccessible to everyone but the owner and group members

I typically have a directory where I want all users to be able to browse through but having files be unreadable and unexecutable. I see some related questions that do not exactly match what I want: ...
1
vote
0answers
61 views

Tomcat unable to create file in dir owned by same group

I have a server running Tomcat, and I need Tomcat to create a file in a particular folder. Tomcat (technically a Java app) runs as the user 'tomcat', as evidenced by top: #top 1251 tomcat 20 0 ...
0
votes
1answer
54 views

Shell script permission denied despite +x flag

This is an odd one, it only happens on one server (shared hosting, so I have limited access to configuration and logs), but I can't wrap my head around it. I have a shell script which runs some app's ...