09-30-2015
The higher parent directories only need an x-bit for basic access.
In Unix the directory where something is deleted|created is updated=changed=written, therefore you need a w-bit for it.
This User Gave Thanks to MadeInGermany For This Post:
10 More Discussions You Might Find Interesting
1. HP-UX
Hi,
I am having hard time to delete a directory:
$ rm -r testoxdwdw
rm: testoxdwdw non-existent
$ rmdir testoxdwdw
rmdir: testoxdwdw: No such file or directory
$ rm -rf testoxdwdw
Thanks! (2 Replies)
Discussion started by: oradbus
2 Replies
2. UNIX for Dummies Questions & Answers
Hi all,
I have an empty directory "-ltr".
How to delete it ?
Thanks (4 Replies)
Discussion started by: madmat
4 Replies
3. Solaris
Hi,
I have a problem on Solaris 10 regarding deletion of files
when I try to recursively delete the directory /opt/Tivoli as root, I get the following error message:
rm: Unable to remove directory Tivoli/lcf/dat/1/no-del/bin/solaris2/TME: File exists
rm: Unable to remove directory... (4 Replies)
Discussion started by: funksen
4 Replies
4. AIX
I've run into a issue where I can not delete directories under a user directory.
There are several of these dir now. I can do a 'mv' of the dir to another dir. ie 'mv sp2456 old/' and it will move the directory, but I can not delete them. Here is all the information I hope you will need to... (9 Replies)
Discussion started by: Clevelaw
9 Replies
5. Solaris
Dear All,
I have problem at T5220 server, when I enter at my server as oracle user and make directory ex. directory test then I will delete directory test with command : rm -rf, what happenned...?? that directory cannot deleted.
What's wrong with my server...?
Note: my server T5220 with... (3 Replies)
Discussion started by: mbah_jiman
3 Replies
6. Shell Programming and Scripting
To find the whole size of a particular directory i use "du -sk /dirname".. but after finding the direcory's size how do i make conditions like if the size of the dir is more than 1 GB i hav to delete some of the files inside the dir (0 Replies)
Discussion started by: shaal89
0 Replies
7. UNIX for Dummies Questions & Answers
Hello,
I am trying to delete a directory but cannot. Can anyone assist?
See attached.
Many thanks. (6 Replies)
Discussion started by: dixer
6 Replies
8. Shell Programming and Scripting
Hi
My directory structure is as below.
dir1, dir2, dir3
I have the list of files to be deleted in the below path as below.
/staging/retain_for_2years/Cleanup/log $ ls -lrt
total 0
drwxr-xr-x 2 nobody nobody 256 Mar 01 16:15 01-MAR-2015_SPDBS2
drwxr-xr-x 2 root ... (2 Replies)
Discussion started by: prasadn
2 Replies
9. Shell Programming and Scripting
Can we force delete the directories despite having files in it? Because I need to delete multiple directories which has multiple files. As of now, I'm deleting the files before deleting the directory. Can't we delete the directory with files? (3 Replies)
Discussion started by: Ram Kumar_BE
3 Replies
10. Shell Programming and Scripting
amigos
necesito dejar en un directorio solo los archivos del dia anterio, como puedo hacer eso con una shell
Hello.
Per our forum rules, all posts must be in English.
We do provide translation services for posts from English to a number of languages as a benefit to users. However,... (16 Replies)
Discussion started by: tricampeon81
16 Replies
mkdir(2) System Calls Manual mkdir(2)
NAME
mkdir - make a directory file
SYNOPSIS
DESCRIPTION
The system call creates a new directory file named by path. The file permission bits of the new directory are initialized from mode, and
are modified by the process's file mode creation mask. For each bit set in the process's file mode creation mask, the corresponding bit in
the new directory's mode is cleared (see umask(2)).
The directory's owner ID is set to the process's effective-user-ID. If the set-group-ID bit of the parent directory is set, the direc-
tory's group ID is set to the group ID of the parent directory. Otherwise, the directory's group ID is set to the process's effective-
group-ID. The set-group-ID bit of the new directory is set to the same value as the set-group-ID bit of the parent directory.
Symbolic constants defining the access permission bits are found in the header and are used to construct the argument mode. The value of
the argument mode is the bitwise inclusive OR of the values of the desired permissions.
Read by owner.
Write by owner.
Execute (search) by owner.
Read by group.
Write by group.
Execute (search) by group.
Read by others (that is, anybody else).
Write by others.
Execute (search) by others.
Access Control Lists - HFS File Systems Only
On HFS file systems implementing access control lists, the directory is created with three base ACL entries, corresponding to the file
access permission bits (see acl(5)).
Access Control Lists - JFS File Systems Only
On JFS file systems that support access control lists, optional ACL entries are created corresponding to the parent directory's default ACL
entries. Also, the parent directory's default ACL entries are copied as the new directory's default ACL entries (see aclv(5)).
RETURN VALUE
returns one of the following values:
Successful completion.
Failure.
An error code is stored in
ERRORS
If fails, no directory is created and is set to one of the following values:
A component of the path prefix denies search permission.
The parent directory of the new directory denies write permission.
User's or group's disk quota block or inode limit
has been reached for this file system.
The named file already exists.
path points outside the process's allocated address space. The reliable detection of this error is implementation dependent.
An I/O error occurred while writing to the file system.
Too many symbolic links are encountered in translating the path name.
The maximum number of links to the parent directory,
would be exceeded.
The length of the specified path name exceeds
bytes, or the length of a component of the path name exceeds bytes while is in effect.
A component of the path prefix does not exist.
Not enough space on the file system.
A component of the path prefix is not a directory.
The named file resides on a read-only file system.
AUTHOR
was developed by the University of California, Berkeley.
SEE ALSO
acl(2), chmod(2), setacl(2), stat(2), umask(2), acl(5), aclv(5), limits(5).
STANDARDS CONFORMANCE
mkdir(2)