Tagged Questions
2
votes
2answers
87 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 ...
1
vote
7answers
181 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
48 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 ...
1
vote
1answer
248 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
93 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, ...
0
votes
1answer
76 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
293 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 ...
1
vote
1answer
90 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 ...
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 ...
3
votes
1answer
116 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
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 ...
6
votes
4answers
481 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:
...
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 ...
2
votes
3answers
655 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:
...
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 ...
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 ...
2
votes
2answers
143 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 ...
4
votes
2answers
1k views
If I change permissions on a tar file, will that apply to the files inside it?
I have a script that runs regularly via cron, that creates a tar.gz file for the purpose of backing up a directory.
For reasons beyond my control, the only user who can execute the script via cron is ...
1
vote
4answers
556 views
grant permission in linux
I have a linux web server with 2 hard-drives.
There are 2 users, one can access /home/user1 and the other user can access /home2/user2
I would like to grant user1 permissions to access /home2/users/ ...
0
votes
2answers
576 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 ...
0
votes
1answer
422 views
Chmod u-x isn't changing anything and I have no idea why
I'm a user on a Debian machine. When I create a file in my home directory, the default permissions appear to be 700, even though umask returns 0022:
eulerz@foo:~$ touch testing
eulerz@foo:~$ ls -l ...
3
votes
1answer
99 views
Make group permissions same as user permissions
I want to set the group permissions for all files and subdirectories within a certain parent directory to whatever the user permission setting for that specific file or directory is.
For example, ...
4
votes
2answers
1k views
Why can't I run programs on another partition in Linux?
So for convenience, I store all my data on my Windows partition so that I can access my data easily from both Linux and Windows. However, I tried compiling a C++ program with g++, and found out that I ...
3
votes
2answers
394 views
How to make a folder request root password to view execute?
I am running Ubuntu 10.04 LTS. I want to use my laptop to play music in a party. MY screensaver does not need a password to deactivate. I would like to allow people to use my computer to play the ...
0
votes
2answers
134 views
is setting a 0 permission on a directory an effective way to protect its contents?
Let's say that permissions for user and group are set up correctly on a directory. Would a 0 permission for other on that directory provide effective access control for the directory's files and ...
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 ...
1
vote
3answers
419 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 ...
5
votes
1answer
468 views
Can't get directory listing of folder I have permissions to
I was having some permission problems and used the following command on directory Media:
chmod -R ugo+r Media
It didn't help so then I did:
chmod -R 775 Media
Now I get this error when I try to ...
4
votes
3answers
1k views
Write access without read access
Is it possible for a user to have a write access to a file and not be able to read it? How is it possible?
I tried the following commands:
debianbox@debian:~/posix/io$ touch filetest
...
3
votes
2answers
630 views
recursively change file permission but not directories?
I was doing a mass recursive change of permissions of some files that I had migrated to a unix system. I changed them to ug+rw, but then I found that I could not traverse subdirectories. I looked at ...
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?
4
votes
2answers
165 views
Directory special permission problem
When I write:
chmod g=rws,u=rwx,o=rx folder_name
I get:
drwxrwSr-x
But S is not the same as s, right?
1
vote
1answer
392 views
Temporary Permissions when installing DokuWiki?
I'm trying to upgrade to the latest version of DokuWiki, and I'm finding that the easiest way to do this is to install the upgrade plugin and just click a few buttons. But there are permissions ...
5
votes
1answer
2k views
NTFS under linux
I'm having some doubts about how to install and allow linux to correctly read/write to a NTFS formated harddrive used as backup of various machines (windows included, that's how I need NTFS).
For now ...
5
votes
4answers
3k views
Is there a web based converter between rwx and the octal version?
I can never remember what the conversion is from something like rw-r--r-- to 644. Is there a simple web based converter between the 2?
3
votes
3answers
370 views
Unix users, groups, and permissions
I don't understand unix users, groups, permissions, etc. For example, things managed by the chmod, chgrp, usermod, groupadd, etc. commands. How do all these things work?
7
votes
2answers
475 views
How are file permissions calculated?
Using chmod I could set the permissions for a file, but if the parent ( .. ) directory had conflicting permissions, what would happen?
And if I create a new file, using touch or something similiar, ...
11
votes
3answers
1k views
I accidentally chmod -R +x on a directory. How do I restore the correct permissions?
Well, to be specific, it was chmod -R 755. Now every file is executable, which I don't want.
I am thinking that I should look at the first two bytes of each file for the #!, but will this cover ...