The chmod tag has no wiki summary.
1
vote
2answers
69 views
Executable located in location A how to run it in location B?
So, I've an executable in my debian server and this executable located in /home/human/ExecuteIt, still i cant figure it out how to run my executable in another location. In my case it is ...
1
vote
1answer
37 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:
...
10
votes
4answers
2k views
Wrongly set chmod / 777. Problems?
I was trying to run chmod -R 777 ./ but ended up typing chmod -R 777 / and set 777 on my entire machine. What can go wrong? How can I fix it?
2
votes
2answers
92 views
Unable to change permissions of file system root
When I write ls -la the output is :
tusharmakkar08-Satellite-C660 tusharmakkar08 # ls -la
total 88
drwxr-x---+ 10 root root 4096 Apr 18 19:43 .
drwxr-xr-x 4 root root 4096 Mar 18 17:35 ..
...
1
vote
1answer
51 views
chmod allowing write when I am not setting it
I've got a perl script which systematically changes permissions. The first thing the script does is remove all permissions. It does this by calling chmod(from perl). I did this as I found the set guid ...
5
votes
4answers
803 views
recursively chmod
I was trying to chmod folders and files with:
find . -type d -exec chmod 755 {} \;
find . -type f -exec chmod 644 {} \;
But I was wondering:
How to do it in one line using find and excluding the ...
3
votes
2answers
50 views
How can a user restrict their own group rights without being root?
How can I change my user rights from rwx to r-x at the group level? I'm trying to ensure that I cannot touch any data belonging to other users when I am developing and debugging my scripts. Once I've ...
1
vote
3answers
72 views
find . .[^.]* -type f -print0 | xargs -0 sudo chmod 664; does not work
I am using this command to set permissions for files recursively
clime@vm6879 /srv/www-php/steeltrading $ find . .[^.]* -type f -print0 | xargs -0 sudo chmod 664
But after executing that command ...
1
vote
1answer
60 views
chmod and chown not working in sudo called script
Based on this Serverfault question, my git user has permission in sudoers to run a wrapper script to move files into my webroot with git.
Everything is working fine except for the chmod and chown ...
1
vote
7answers
185 views
Convert ls -l output format to chmod format
Say I have the following output from ls -l:
drwxr-xr-x 2 root root 4096 Apr 7 17:21 foo
How can I automatically convert this to the format used by chmod?
For example:
$ echo drwxr-xr-x | ...
1
vote
2answers
49 views
Files created by 'make' aren't getting executable permissions by default
I'm trying to build a project, and when I use the command make, I get the following errors:
/bin/sh: line 4: .deps/ipset_bitmap_ipmac.Tpo: Permission denied
make[2]: *** [ipset_bitmap_ipmac.lo] Error ...
1
vote
1answer
36 views
Able to delete file without permission [duplicate]
I've been experimenting with file permissions and ownership lately, and I tried this:
touch a
sudo chown root:root a
sudo chmod 000 a
I can't read, write, or execute the file, but I can still ...
0
votes
1answer
72 views
Find all directories, in which user has access to search and echo this directories in shell
I need to find all directories, in which user has access to search(command find) and echo this directories in shell. USER is read from ksh.
for example:
read user
I know, if user want to use find ...
-1
votes
1answer
58 views
Why is ./filename required to run executable script? [duplicate]
After creating a Python script file, test.py, in my home directory, and running chmod +x test.py to make it executable, and placing #!usr/bin/env as the file header, I expected to be able to run the ...
19
votes
8answers
2k views
Why use `chmod 644` instead of `chmod u=rw,go=r,…`?
I've been working on *nix for a few years now, and one of the things I just can't get used to is octal permissions in code. Is there some other reason than line length to prefer chmod 644 ... over ...
4
votes
2answers
147 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 ...
1
vote
1answer
267 views
script failing with “chmod: … Operation not permitted”
A script of mine works fine when I run it, but fails when run by a different user, with an error of the form
chmod: changing permissions of `/A/B/C/D/E': Operation not permitted
(Here /A/B/C/D/E is ...
1
vote
2answers
96 views
How to make a path world-readable?
To make some item X world-readable, it is not enough for it to have the right permissions: each component of the absolute path leading to it must also have the right permissions. (My understanding, ...
1
vote
2answers
73 views
chmod wont work - no error message
Everytime I try to change the permissions of a file with chmod on my Ubuntu with a command like
chmod 744 /media/DATEN/Dokumente/Coding/Python/DirFileFuncts.py it doesnt work. I tried octal and =rwx ...
0
votes
1answer
78 views
Allow all group members to create directories and files
There are 2 users
sftp_user
apache
Both users belong to the updaters group as well as other groups.
New directories and files are created in the
/updates/ directory.
drwxrwsr-x 8 sftp updaters ...
1
vote
0answers
62 views
External HDD read/write permission changing from a cron job
So, I run an overnight python script that runs a backup of our web data in the /var/www directory, then moves the backups to an external HDD in /media. The script in scheduled in the sudo crontab ...
3
votes
2answers
299 views
Why does “chmod 1777” and “chmod 3777” both set the sticky bit?
To set the sticky bit on a directory, why do the commands chmod 1777 and chmod 3777 both work?
1
vote
1answer
36 views
Securely running LAMP under a specific user
I'm setting up a sandbox type of server that will be used by a couple users as a development environment and knowledge base. The server will have a web frontend so I've installed Apache, MySQL and ...
3
votes
1answer
95 views
Change who is able to chmod
Is there a way to change who can chmod (change the permissions of) a particular file?
It is only the owner of the file (without sudo-ing it), if my experimentation has been correct?
But what I want ...
1
vote
1answer
92 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 ...
0
votes
1answer
172 views
Unable to change file permissions [duplicate]
Possible Duplicate:
No effect of umask and chmod on mounted drives
I am not able to change file permissions using chmod from the user who owns the file as well as from root. I am using ...
3
votes
1answer
117 views
Clear setuid permission using numeric mode
On an Ubuntu Linux I have a directory with the setuid bit set (drwsr-xr-x) which I want to unset.
Neither chmod 755 nor chmod 0755 nor chmod 00755 (I though maybe the first 0 is interpreted as just ...
1
vote
3answers
420 views
chmod - change permissions on a file
I have a Python virtualenv, and the Python executable is located in the /bin directory. In this virtualenv I'll have to execute some unsafe code, that can damage my system. I tried to chmod a-r on the ...
1
vote
2answers
365 views
Fedora 14 command line: assign folder permissions
How can I assign folder permissions in Fedora 14 using the command line?
I'd like to give read/write/execute permissions to :
2 users (tom, jim) to the folder /Home/Share
1 group (employees) to the ...
1
vote
1answer
113 views
Hide parent directory but allow to view dir
I would like the following result on my UNIX system:
ls -l /users/test -> permission denied, or any other way so I can't see the content of it.
ls -l /users/test/testdir/ -> shows all files in the ...
2
votes
1answer
1k views
Why can I not chmod a file?
[nathanb@ka /x/sim/nathanb/nbsim1] ls -al ,nvram
-rw-r--r-- 1 root root 2097152 Jul 5 2011 ,nvram
[nathanb@ka /x/sim/nathanb/nbsim1] sudo chmod a+w ,nvram
chmod: changing permissions of ...
4
votes
1answer
485 views
what is the difference between “chmod 775” and “chmod 2755”?
Question
What is the difference between "chmod 775" and "chmod 2755" ?
6
votes
4answers
488 views
When does chmod fail?
Under what circumstances will chmod fail?
I looked at the man page but it only specifies usage and doesn't go into details about what circumstances it won't work in.
I'd assume chmod will work if:
...
3
votes
1answer
142 views
How to create a folder which will change its contents’ ownership to what the folder has?
In a GNU/Linux OS there is no way to change ownership of a file until you are root. But what if I want to hide my system’s username e.g. before sending a file to someone, because some things like tar ...
3
votes
1answer
518 views
copying device nodes
I'm trying to transfer a working Linux installation to a new larger disk, so I've attached the new disk on a USB port, partitioned it and created filesystems.
While copying all the files over I hit a ...
2
votes
4answers
649 views
How to make executable of all files excluding a few file types?
I have a folder containing many C source file and the same number of its compiled output files.
I set executable bit to all this files but for some reason it was lost, making them not executable. (I ...
0
votes
4answers
2k views
How to permanently change the file/directory permission [closed]
How do I change the permission of file/directories such that I am able to create, edit, delete files/directories anywhere in my system? Currently I am using Ubuntu 12.04.
I tried
sudo chmod 777 -r ...
6
votes
2answers
19k views
Recursive chmod only folders or only files via script or nautilus menu?
This has been discussed before here.
What I'd like to know is how to turn these:
Recursive chmod only files within this folder:
find . -type f -exec chmod 0600 {} \;
Recursive chmod only folders ...
4
votes
2answers
1k views
Get the chmod numerical value for a file
In FreeBSD and also in Linux, how can I get the numerical chmod value of a file? For example, 644 instead of -rw-r--r--? I need an automatic way for a Bash script.
2
votes
3answers
129 views
User with read access to /home
Pardon my ignorance but I can't seem to come up with a solution to this one.
I'd like to create a user that has read access to every user's home catalog located in /home.
Do I need acl's for this or ...
1
vote
1answer
276 views
External drive chmod does nothing
Why is it that I can do chmod on my files when they are on my laptops hard drive, but when i make files on my external drive, i can't change their access rights.
I do:
chmod 755 somefile,
and on my ...
2
votes
3answers
657 views
Change Folder Permissions
I started off with changing to the folder I want to change permissions for, and that is the opt folder.
$ cd /opt/
test@testVM:/opt$
So I tried changing the permissions for this folder now using:
...
3
votes
1answer
416 views
Giving SSH users read-only access to a directory
I'm running Fedora 17 and I want to give several users access to files on my secondary hard drives on /run/media/haukur/. This is what I initially did:
chmod -R 755 /run/media/
But every time I ...
0
votes
2answers
582 views
Giving PHP permission to write to files and folders
UPDATED FOR FURTHER CLARITY:
According to http://expressionengine.com/user_guide/installation/installation.html, it says:
For most Unix hosts the following is typical, but you may check with your ...
2
votes
2answers
1k views
Find web server group? Permissions problem
I'm trying to make Wordpress work. I currently have this error message:
Could not create directory.
/var/www/html/wp-content/upgrade/theme_name
when trying to upload a theme. This is the ...
1
vote
0answers
258 views
Changing file permissions problem [closed]
A few hours earlier I bought a beaglebone (Ångström installed) and now I am trying to add nameserver 8.8.8.8 (google DNS) to /etc/resolv.conf. However when I open it with vim and try to add my ...
5
votes
2answers
231 views
vim: create file with +x bit
Is there any way to set +x bit on script while creating?
For example I run:
vim -some_option_to_make_file_executable script.sh
and after saving I can run file without any additional movings.
ps. ...
13
votes
2answers
1k views
How to apply recursively chmod directories without affecting files?
After I apply chmod -R to a directory, permissions are changed for everything within (files and directories). How can I add execute/search (x) permissions to directories without modifying the files?
2
votes
2answers
144 views
execute bit on directories, but not files [duplicate]
Possible Duplicate:
How to apply recursively chmod directories without affecting files?
What is the command to apply execute permission for directories (for traversal), but leave the ...
3
votes
3answers
925 views
How to get permission number by string : -rw-r--r--
I need to set the same chmod, how to get number for -rw-r--r-- ?

