Where allowed to run: All environments (*ALL) Threadsafe: Yes |
Parameters Examples Error messages |
The Change Journaled Object (CHGJRNOBJ) command changes the journaling attributes of a journaled object without the need to end and restart journaling for the object.
The command can be used to change the Images (IMAGES) value for a database file (*FILE) or a data area (*DTAARA) object without the need to end and restart journaling for the object. Otherwise the Start Journal Physical File (STRJRNPF) can be used to set this value for database files. The Start Journal (STRJRN) or the Start Journal Object (STRJRNOBJ) can be used to set this value for data areas.
The command can be used to change the Omit journal entry (OMTJRNE) value for a database file (*FILE), an integrated file system stream file (*STMF) or directory (*DIR) object without the need to end and restart journaling for the object. Otherwise the Start Journal Physical File (STRJRNPF) can be used to set this value for database files. The Start Journal (STRJRN) can be used to set this value for integrated file system objects.
The command can be used to change the New objects inherit journaling (INHERIT) value for an integrated file system directory (*DIR) object without the need to end and restart journaling for the object. Otherwise the Start Journal (STRJRN) can be used to set this value for integrated file system objects.
The command can also be used to allow a database file (*FILE), that contains changes for partial transactions, to be used. Partial transactions can only exist for an object that can be changed under commitment control. Database file objects (*FILE) are the only objects that can be opened using commitment control.
Partial transactions can exist for two reasons:
If a change does not apply to an object type, the objects of that type are ignored and processing continues with the next object. Also, if the object already has the correct value for the attribute being changed no error will be returned.
Restrictions:
Top |
Keyword | Description | Choices | Notes |
---|---|---|---|
OBJ | Objects | Values (up to 300 repetitions): Element list | Optional |
Element 1: Object | Qualified object name | ||
Qualifier 1: Object | Name, *ALL | ||
Qualifier 2: Library | Name, *LIBL, *CURLIB | ||
Element 2: Object type | *FILE, *DTAARA | ||
OBJPATH | Objects | Values (up to 300 repetitions): Element list | Optional |
Element 1: Name | Path name | ||
Element 2: Include or omit | *INCLUDE, *OMIT | ||
OBJFID | File identifier | Values (up to 300 repetitions): Hexadecimal value | Optional |
SUBTREE | Directory subtree | *NONE, *ALL | Optional |
PATTERN | Name pattern | Values (up to 20 repetitions): Element list | Optional |
Element 1: Pattern | Character value, * | ||
Element 2: Include or omit | *INCLUDE, *OMIT | ||
ATR | Attribute | *IMAGES, *OMTJRNE, *INHERIT, *PTLTNS | Optional |
IMAGES | Images | *SAME, *AFTER, *BOTH | Optional |
OMTJRNE | Omit journal entry | *SAME, *NONE, *OPNCLOSYN | Optional |
INHERIT | New objects inherit journaling | *SAME, *NO, *YES | Optional |
PTLTNS | Partial transactions | *SAME, *ALWUSE | Optional |
Top |
Specifies an object or list of objects for which their journaling attributes are to be changed.
Element 1: Object
Qualifier 1: Object
Qualifier 2: Library
Element 2: Object type
Specify the object type of the object that is to have its journaling attributes changed.
Top |
Specifies a maximum of 300 objects for which journaling attributes are to be changed. Only objects whose path name identifies an object of type *STMF, *DIR, *SYMLNK, *DTAARA, or *FILE that is in the "root" (/), QOpenSys, or user-defined file systems are supported. Objects found that match the specified selection criteria but are not currently being journaled are ignored.
Element 1: Name
Symbolic links within the path name will not be followed.
Additional information about path name patterns is in the Integrated file system information in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter.
The second element specifies whether names that match the path name or a pattern should be included or omitted from the operation. Note that in determining whether a name matches a pattern, relative name patterns are always treated as relative to the current working directory.
Note: The SUBTREE parameter specifies whether the subtrees are included or omitted.
Element 2: Include or omit
Top |
Specifies a maximum of 300 file identifiers (FIDs) for which journaling attributes are to be changed. FIDs are a unique identifier associated with integrated file system related objects. This field is input in hexadecimal format. Only objects whose FID identifies an object of type *STMF, *DIR, *SYMLNK, *DTAARA, or *FILE are supported.
Top |
Specifies whether the directory subtrees are included in determining the objects for which journaling attributes are to be changed.
Note: This parameter is only valid if one or more path names were specified on the Objects (OBJPATH) parameter.
Top |
Specifies a maximum of 20 patterns to be used to include or omit objects for which journaling attributes are to be changed.
Note: This parameter is only valid if one or more path names were specified on the Objects (OBJPATH) parameter.
Element 1: Pattern
Additional information about path name patterns is in the Integrated file system information in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter.
The second element specifies whether names that match the pattern should be included or omitted from the operation. Note that in determining whether a name matches a pattern, relative name patterns are always treated as relative to the current working directory.
Element 2: Include or omit
Top |
Specifies which attribute will be selected to be changed.
Top |
Specifies the kinds of images that are written to the journal receiver for changes to objects.
Note: The value *BOTH is only valid for data area (*DTAARA) and database file (*FILE) objects.
Top |
Specifies the journal entries that are omitted.
Note: The value *OPNCLOSYN is only valid for *FILE, *DIR and *STMF objects.
Note: The value *OPNCLOSYN is the same as OMTJRNE(*OPNCLO) on the STRJRNPF command for *FILE objects.
Top |
Specifies whether new objects created within a journaled directory should inherit the journal options and the journal state of its parent directory.
Note: The INHERIT parameter is only valid for *DIR objects.
Top |
Specifies whether an object that contains changes for partial transactions can be used or not.
Note: The PTLTNS parameter is only valid for *FILE objects.
Note: All object (*ALLOBJ) special authority is required if *ALWUSE is specified.
Top |
Example 1: Change File Journaling Attribute IMAGES
CHGJRNOBJ OBJ((LIBA/FILEA *FILE)) ATR(*IMAGES) IMAGES(*BOTH)
This command will change the attribute of file FILEA in library LIBA to now journal both before and after images for the file without having to end journaling and start journaling of the file.
Example 2: Change File Journaling Attribute OMTJRNE
CHGJRNOBJ OBJ((LIBB/FILEB *FILE)) ATR(*OMTJRNE) OMTJRNE(*OPNCLOSYN)
This command will change the attribute of file FILEB in library LIBB to now omit open and close entries.
Example 3: Change Object Journaling Attribute OMTJRNE
CHGJRNOBJ OBJFID(00000000000000007E09BDB000000009) ATR(*OMTJRNE) OMTJRNE(*OPNCLOSYN)
This command will change the attribute of the object represented by the specified file identifier to now omit open, close and force entries. This object can be an object of type *DIR or *STMF.
Example 4: Change File Attribute PTLTNS
CHGJRNOBJ OBJ((LIBC/FILEC *FILE)) ATR(*PTLTNS) PTLTNS(*ALWUSE)
This command will change the file so that it can be used again, however the partial transactions are not themselves completed. This method should only be used in rare circumstances when the file could not be recovered by applying or removing the journaled changes.
Top |
*ESCAPE Messages
Top |