Login or Register to Ask a Question and Join Our Community

rm Permission Denied error

Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers rm Permission Denied error
# 8  
Old 06-26-2002
Those permission have

owner (infdvlpap) can read and write
group (other) can read and write
all others can only read.

Your user 'approd ' is part of the 'other' group - so has read/write access.

In order to delete a file from a directory the user must have write access to the directory in which it lives...not just to the file itself. In fact if you have write access to the directory but not the file you are still able to delete it. the converse of this is also true...if you own a file but don't have write access to the directory in which it resides - you can't delete it.

Does this help?
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Pipe, permission denied error

Hello, I am trying to stream lines written into file. When first source is down, I expect the code to swap to second line and run it. Script below works as usual and it prints out each line of the input file (s.txt): #!/bin/bash while read -r line; do echo "$line" done <"$1" exit 0Output... (12 Replies)
Discussion started by: baris35
12 Replies

2. Red Hat

Permission denied error using chmod on a cifs mount

I have a RHEL 5.7 system with a cifs mount from a Windows 2007 file server that I need to fix the permissions on. Once the share is mounted the permission for the mount are 777. I need to change that to 770 on the top level directory and to 640 on the sub-directory .ssh/. But when I run chmod... (0 Replies)
Discussion started by: westmoreland
0 Replies

3. UNIX for Dummies Questions & Answers

Webserver permission denied error

Hello, I was trying a perl-cgi tutorial and saving the data from online form to a file named (guests.txt). I am using the localhost port 80 for practice. My page file "guestbook.html" is working as I saw the online form. After filled out the blanks and submit, I was expecting to see the result... (3 Replies)
Discussion started by: yifangt
3 Replies

4. UNIX for Dummies Questions & Answers

Getting Error 0403-006 Execute permission denied.

Hi All, Need your help.. I am writing one script in which I am assigning value to one variable but when i am executing it is showing error "0403-006 Execute permission denied" below is the line of that script : INPUT_COUNT=wc $GIF_DIR/input/VID_RIMS.DAT | awk '{print $1}' and access... (2 Replies)
Discussion started by: NirajThakar
2 Replies

5. Shell Programming and Scripting

Change: xecho: execute permission denied error

Hello, I am have an issues with one of my scripts. I get the following error when I get to the point in the script where I am making the change. The change does take however. the error is "change: xecho: execute permission denied" Everything was working properly until I start cleaning... (3 Replies)
Discussion started by: simpsonjr
3 Replies

6. OS X (Apple)

Permission Denied Error with X11

Hello, I am using Tiger 10.4.11 I am trying out the GIMP, so I installed the X11 package from "Optional Installs" on the cd. Whenever I open X11, I get an error: xterm: could not exec /dev/null: Permission denied I have chmodded /dev/null to 777, as well as the /tmp directory. I deleted... (2 Replies)
Discussion started by: Ricardo-san
2 Replies

7. Shell Programming and Scripting

ERROR : Permission denied (publickey,password,keyboard-interactive).

Hello, when I try to connect to a remote machine through SSH username@host I am getting the error message Permission denied (publickey,password,keyboard-interactive). Can any one tell me what is the problem. the key is added in the remote machines authorized_keys file. (5 Replies)
Discussion started by: deepusunil
5 Replies

8. UNIX for Advanced & Expert Users

Need help with Couldn't canonicalise: Permission denied error

Hi People I am getting this error Couldn't canonicalise: Permission denied. Anyone knows what does this error mean ? It all started when my team members were testing Sftp functions on some directories and they were hitting directory no found errors within their scripts. So when we enquired... (8 Replies)
Discussion started by: wilsontan
8 Replies

9. Shell Programming and Scripting

xterm gives me permission denied error

When I try to run xterm at a command prompt in solaris 2.5.1, i'm getting a permission denied error. But the directory and user permissions look ok, they are part of a users group and then also root,sys,adm so what gives? Any ideas? Thanks! (1 Reply)
Discussion started by: kymberm
1 Replies

10. UNIX for Advanced & Expert Users

getcwd: permission denied error

When I do a 'cd /appl' and issue 'ls -al' command, I get the following error for .. directory. ./..: Permission denied But still I get a listing of other directories under /appl. Also, if I give 'man' for any command under this /appl folder, I get the following error: ... (3 Replies)
Discussion started by: Deepa
3 Replies
Login or Register to Ask a Question
chmod(1)						      General Commands Manual							  chmod(1)

       chmod - change file mode

       chmod [ -fR ] mode file...

       Permissions on files are set according to mode and file parameters.

       For file, you can specify either a full or partial path.  You can specify multiple files, separated by spaces.

       For mode, you specify one of two variants: absolute mode or symbolic mode.

   Absolute Mode
       For mode in absolute form, you specify an octal number constructed from the sum of one or more of the following values:

	      4000	set user ID on execution (applies to executable files only)
	      2000	set group ID on execution (applies to executable files only)
	      1000	set sticky bit (see for more information)
	      0400	read by owner
	      0200	write by owner
	      0100	execute, or search if file is a directory, by owner
	      0040	read by group
	      0020	write by group
	      0010	execute, or search if file is a directory, by group
	      0004	read by others
	      0002	write by others
	      0001	execute, or search if file is a directory, by others

       For  example, the absolute mode value that provides read, write, and execute permission to owner, read and execute permission to group, and
       read and execute permission to others is 755 (400+200+100+40+10+4+1).  The absolute mode value that provides read, write, and execute  per-
       mission to owner and no permission to group or others is 700 (400+200+100).

   Symbolic Mode
       To specify mode in symbolic form, use the following format:

	      [who] op permission [op permission] ...  Spaces are included in the preceding format so that you can read the arguments; however, as
	      will be shown in examples that follow, you do not enter spaces between mode arguments.

       Specify who using the letters u (for owner), g (for group) and o (for others) either alone or in combination.  You  can	also  specify  the
       letter  a (for all), which is is equivalent to the letter combination ugo.  If you omit the who parameter, a is assumed.  For more informa-
       tion, see

       For the op parameter, specify the plus sign (+) to add permission to the file's mode, the minus sign (-)  to  remove  permission  from  the
       file's  mode,  or the equal sign (=) to assign permission absolutely (denying or revoking any permission not explicitly specified following
       the equal sign).  The first command in the following example provides group with execute permission for in addition to  any  other  permis-
       sions group currently has for The second command limits the permission that group has for to execute alone:
       chmod g+x filea
       chmod g=x fileb

       For  the  permission  parameter,  specify any combination of the letters r (read), w (write), x (execute), s (set owner or group id), and t
       (save text - sticky).  Alternatively, you can specify the letter u, g, or o to set permission for the who parameter to be the same  as  the
       permission  currently granted to the user category indicated by the letter.  In the following example, the group (g) is given the same per-
       missions on as currently granted to owner (u):
       chmod g=u filea

       You can revoke all permissions by specifying the who argument followed by =, and omitting the permission argument.  For example,  the  fol-
       lowing command removes all permissions from others for
       chmod o= fileb

       When  specifying  more than one symbolic mode for file, separate the modes with commas. The mode changes are applied in the sequence speci-
       fied.  In the following example, write permission is added to the permissions already granted to the owner of and group is then granted the
       same permissions on as granted the owner:
       chmod u+w,g=u filea

       -f   Inhibits display of errors that are returned if fails to change the mode on a file.

       -R   Causes  to	recursively descend any directories subordinate to file and to set the specified mode for each file encountered.  However,
	    when symbolic links are encountered, does not change the mode of the link file and does not traverse  the  path  associated  with  the
	    link.  Note that the option is useful only when file identifies a directory that is not empty.

       The permission letter s is used only with who letter u or g.

       Only the owner of a file  or someone logged on as superuser may change the mode of that file.

       Using  absolute	mode,  provide	read,  write, and search permission to the owner, and read and search permission to others for a directory
       chmod 755 ~harris/public

       Using absolute mode, set the UID for execution to be the UID of of the file owner rather than the UID of the user running  the  program	as
       chmod 4000 progrmb

       Using symbolic mode, perform the same operation as described for the preceding example:
       chmod u=s progrmb

       Using symbolic mode, deny write permission to others for the file
       chmod o-w ourspec

       Using symbolic mode, give execute permission on file to all user categories:
       chmod +x myprog

       Using symbolic mode, give write permission to all group members, deny write permission to others, and give search permission to owner on
       chmod g+w,o-r,u+x docdir

       Using  symbolic	mode, give read and execute permissions to others for a directory named and then recursively descend the paths subordinate
       to adding the  same permissions for others on all files and directories included in the subordinate paths:
       chmod -R o+rx programs
       In the preceding example, if were the name of a file rather than a directory, would change the mode only of the file.

See Also
       ls(1), chmod(2), stat(2), umask(2), chown(8)


Featured Tech Videos