Creates one or more keys in the OpenVMS Registry database. This command requires the SYSPRV privilege or the REG$UPDATE rights identifier. Format: CREATE KEY key-name[,...] key-name[,...] Specifies the name of the key to create. You can create multiple keys by separating the keys with commas.
1 – Qualifiers
1.1 /CACHE_ACTION
/CACHE_ACTION=value Specifies the cache attribute for the new key. The value can be WRITEBEHIND (write to disk later) or WRITETHRU (write to disk immediately). If you omit /CACHE_ACTION, the system creates the key with the cache attribute set to REG$K_WRITEBEHIND.
1.2 /CLASS_NAME
/CLASS_NAME=string Specifies the class name of the key.
1.3 /LINK
/LINK=(TYPE=value, NAME=key-name) Defines the key as a link to another key. The link value must be one of the following: o SYMBOLICLINK o NONE To remove a link, enter the following: /LINK=(TYPE=NONE,NAME="")
1.4 /SECPOLICY
/SECPOLICY=policy Defines the security policy for the key. Currently the only valid policy is NT_40.
1.5 /VOLATILE
/VOLATILE=level /NONVOLATILE (default) Specifies whether or not the new key is volatile. If you are running the OpenVMS Registry on a standalone OpenVMS system, volatile keys are lost when the system reboots. If you are running the OpenVMS Registry in an OpenVMS cluster, volatile keys are lost when all nodes in the cluster are rebooted. The values for level are as follows: o NONE (same as /NONVOLATILE) o CLUSTER
1.6 /WAIT
/WAIT=seconds (default = 90) /NOWAIT Specifies the maximum amount of time, in seconds, that you are willing to wait for command completion. If the Registry server does not complete the request in the specified interval, REG$CP returns REG-F-NORESPONSE. The default interval is 90 seconds. /NOWAIT is equivalent to specifying /WAIT=0, but there may still be a short wait period.
1.7 /WRITEBEHIND
/WRITEBEHIND /NOWRITEBEHIND (default) Specifies when the information can be written to disk. /WRITEBEHIND specifies that the information can be written to disk later. /NOWRITEBEHIND specifies write-through operation (that is, the information must be written to disk immediately).
2 – Example
REG> CREATE KEY/CACHE_ACTION=WRITEBEHIND HKEY_USERS - _REG> \GUEST, HKEY_USERS\SYSTEM Creates the GUEST and SYSTEM keys under the HKEY_USERS entry point. The keys are created with the write-behind attribute.