── MKDIR ── <directory name> ─┬───────────────────────┬────────────────┤ └─ ON ── <family name> ─┘
Explanation
The MKDIR statement creates directories in the permanent directory namespace. Use the MKDIR statement to create a *DIR directory and the subdirectories of *DIR. The directory name specifies the full name of the directory you are creating. If you are creating a subdirectory, the parent directory must already exist. If the directory does not exist, an error message displays.
-
Only privileged users can create a *DIR directory.
-
Users with write and traverse permission to an existing permanent directory can create subdirectories within the existing permanent directory using the MKDIR statement.
-
A file and a permanent directory cannot both have the same name.
-
After a permanent directory has been created, it cannot be overwritten with a file of the same name that is not a permanent directory.
The OWNER attribute of the directory is set to the usercode of the task. The SECURITYMODE attribute is set to OWNERRWX=RWX, GROUPRWX=X, and OTHERRWX=X by default. The NONUSERFILES option has no effect on the security of newly created permanent directories; however, this option does affect other files created in the permanent directory name space.
To set SECURITYMODE and other security-related attributes to values other than the default, use the PROPAGATESECURITYTODIRS file attribute. Setting this attribute on *DIR or any other permanent directory causes newly created subdirectories to inherit the security attributes of their parent directory.