GETSHARED request
To create a shared memory object, use the IARV64 GETSHARED service. While shared memory storage is like common storage in that it is shared across address spaces, it differs because there is not automatic addressability or access to it.
The shared memory object is allocated when you use the GETSHARED service. To access data in a shared memory object you need to use the IARV64 GETSHARED request to create the shared memory object, and the IARV64 SHAREMEMOBJ request to specify an interest in the shared memory object.

Notice that when you create a shared memory object, you specify some of the same attributes as when you create a non-shared memory object through the GETSTOR service.
- SEGMENTS=segments specifies the size, in megabytes, of the shared memory object you are creating.
- FPROT=YES gives the memory object fetch protection. The default is FPROT=NO.
SENSITIVE is an optional parameter that specifies whether the memory object
contains sensitive data (for instance, personal or confidential data), as described in Tagging 64-bit memory objects for data privacy.
- KEY=key specifies its storage key. The key must be in bits 0-3 of the specified byte.
- CHANGEACCESS=scope identifies whether subsequent CHANGEACCESS requests change the access for only the address space specified (LOCAL), or all the address spaces sharing the memory object (GLOBAL). The default is CHANGEACCESS=LOCAL.
- USERTKN=usertoken is a required 8-byte token that relates two or more memory objects to each other. Associate the user token with the memory object, so later you can free several shared memory objects at one time.
- ORIGIN= origin is the name or address that will contain the lowest address in the memory object.
For an example of this request, see Example of creating and using a shared memory object – GETSHARED.