Questions tagged [chmod]

chmod is used to change the commonly used read, write, and execute permissions on files. It can change these permission bits for the file owner, the file's group owner, and everyone else. It can also change the more esoteric ‘permissions’ (attributes, reall) like set-user-ID, set-group-ID, and sticky bits.

Filter by
Sorted by
Tagged with
2
votes
2answers
7k views

Meaning of chmod 1775

Created a folder "Sample_dir" and analysed its permissions. $ mkdir Sample_dir $ ll Sample_dir/ total 36 drwxrwxr-x 2 user user 4096 Jul 1 19:26 ./ drwx------ 71 user user 28672 Jul 1 19:26 ../ ...
1
vote
1answer
1k views

Safe to change owner of OS X system folders?

I'm trying to get Homebrew to work. That program's diagnosis tool gives me these suggestions: You should probably chown /usr/local/etc ... You should probably chown them: /usr/local/...
7
votes
2answers
592 views

Can't remove a file with file mode bits a+rw

I have a file with the following file mode bits (a+rw): [0] mypc<johndoe>:~>sudo touch /tmp/test [0] mypc<johndoe>:~>sudo chmod a+rw /tmp/test [0] mypc<johndoe>:~>ls -l ...
5
votes
2answers
1k views

Is it possible to represent the +X symbolic permission with an octal value?

Is it possible to represent the +X symbolic permission with an octal value? The chmod(1) man page says: execute/search only if the file is a directory or already has execute permission for some ...
3
votes
1answer
923 views

What does it mean if a directory has only x (executable) permission for certain user/group?

I stumbled across the directory /etc/ssl/private on Ubuntu (12.04), it has following permission: drwx--x--- 2 root ssl-cert 4096 7月 8 2012 private/ I wonder what does this mean for group ssl-...
3
votes
1answer
645 views

chmod 600 fails silently

Here is what happens: $ chmod 600 foobar.txt $ ls -l total 1 -rwx------ 0 sampablokuper sampablokuper 13 Feb 19 21:00 foobar.txt Why is the last line not reading as follows? -rw------- 0 ...
2
votes
1answer
283 views

Recovering from removing execute permission from ld-linux.so

After reading about removing the execute permission from chmod, I got curious. Is it possible to recover from removing the execute permission from ld-linux.so without rebooting if I haven't yet exited ...
2
votes
1answer
3k views

Setting up permissions for common folder

I am trying to setup a little home network using Linux as the File Server and have run into a bit of problems w.r.t. to folder permissions that I can't seem to solve. The setup: An Ubuntu 14.04 Linux ...
2
votes
1answer
318 views

How can I grant owning group permissions when POSIX ACLs are applied?

I am trying to understand how I can grant permissions to the owning group once POSIX ACLs have been applied to a file. Normally, I would use chmod g+rwx. However, that does not work when a POSIX ACL ...
1
vote
2answers
3k views

relation between chmod and sudo on an executable file

What is the relationship between chmod and sudo on an executable file for a user? Are the cases that "a user needs sudo to run an executable" the same as the cases that "chmod hasn't set the ...
1
vote
1answer
164 views

Different behaviors between find -exec and piping through xargs [duplicate]

I wanted to recursively run chmod go+w in a particular folder including hidden files, and I first tried find . -name ".*" -o -name "*" -exec chmod go+w {} \; but I found that it wasn't affecting ...
1
vote
1answer
3k views

Change ownership of a share drive

I have a windows machine locally connected to my linux machine. There is a shared folder on the windows machine, which I mounted on my linux machine using sudo mount -t cifs -o username=myuser //xxx....
1
vote
3answers
2k views

Reverse a chmod command on a directory

Is there a way to undo a chmod command on a directory in CentOS ?
0
votes
1answer
908 views

Combine find-chmod for directories and find-chmod for regular files [duplicate]

I have these commands: find /var/www/html/* -type d -exec chmod 755 {} \; find /var/www/html/* -type f -exec chmod 644 {} \; I understood from Stephen Kitt's answer here that I could combine them ...