Apply Program Temporary Fix (APYPTF)

The Apply Program Temporary Fix (APYPTF) command applies program temporary fixes (PTF) to a specified product. Before a PTF can be applied, it must first be loaded by the Load Program Temporary Fix (LODPTF) command.

When a PTF is applied, it completely replaces the affected objects in the product. PTFs can be applied temporarily or permanently. If they are applied temporarily, the replaced objects are saved by the system and can later be restored to the product by the Remove Program Temporary Fix (RMVPTF) command. If PTFs are applied permanently, the replaced objects are deleted from the system.

The APYPTF command is used to apply immediate PTFs at the time the command is run, or to request PTFs to be applied during the next unattended initial program load (IPL). During an attended IPL, the Work with PTFs display is used to apply PTFs at the time the system is started.

Some IPLs may take longer than others when PTFs are being applied. More information about applying PTFs is in the IBM i and related software category in the IBM i Information Center at http://www.ibm.com/systems/i/infocenter/.

Restrictions:

Parameters

Keyword Description Choices Notes
LICPGM Product Character value, *ALL Required, Positional 1
RLS Release Character value, *ONLY, *ALL Optional
SELECT PTF numbers to select Single values: *ALL
Other values (up to 300 repetitions): Character value
Optional
OMIT PTF numbers to omit Values (up to 300 repetitions): Character value Optional
APY Extent of change *TEMP, *PERM Optional
DELAYED Delayed PTFs *NO, *YES, *IMMDLY Optional
IPLAPY IPL apply options Single values: *NO
Other values: Element list
Optional
Element 1: Apply at unattended IPL *YES
Element 2: Prerequisite lic int code *APYPERM, *NOAPY
APYREQ Apply requisite PTFs *NO, *YES Optional

Product (LICPGM)

Specifies the 7-character identifier of the product for which the PTFs are to be applied.

Note: LICPGM(*ALL) is valid only if SELECT(*ALL) is specified, and OMIT is not specified on this command.

This is a required parameter.

*ALL
PTFs are applied to all products installed on the system.
character-value
Specify the 7-character product identifier to which PTFs are applied.

Release (RLS)

Specifies the release level of the software product. If multiple releases are installed, the release is required.

*ONLY
This value is valid only when one release of the product's base option is installed on the system. PTFs for all installed options of the product are applied regardless of the release-level of the option.
*ALL
The PTFs for all releases of the installed products are applied. This value is valid only when LICPGM(*ALL) is specified.
character-value
Specify the release level in one of the following formats:
  • VxRyMz, where Vx is the version number, Ry is the release number, and Mz is the modification level. The variables x and y can be a number from 0 through 9, and the variable z can be a number from 0 through 9 or a letter from A through Z.
  • vvrrmm, where version vv and release rr must be a number from 00 through 35, and modification mm must be a number from 00 through 09 or a letter from 0A through 0Z. The leading zeros are required. This format must be used if the version or release of the product is greater than 9.

PTF numbers to select (SELECT)

Specifies the previously loaded PTFs that are to be applied to the specified product. The PTF numbers to omit (OMIT) parameter cannot be specified if single PTF numbers are specified on the SELECT parameter.

Single values

*ALL
All the PTFs that were loaded are to be applied to the product. If all PTFs cannot be applied, messages are sent indicating the PTFs that were not applied and the reasons (for example, required PTFs were not yet applied).

Other values (up to 300 repetitions)

character-value
Specify the identification number of each PTF to apply.

PTF numbers to omit (OMIT)

Specifies the PTF numbers that are not applied. Up to 300 PTF numbers can be specified.

Note: The OMIT parameter cannot be specified if single PTF numbers are specified for the PTF numbers to select (SELECT) parameter.

character-value
Specify the identification number of each PTF to omit.

Extent of change (APY)

Specifies whether the PTFs are applied on a temporary or permanent basis. Permanently applied PTFs cannot be removed; temporarily applied PTFs can be removed by the Remove Program Temporary Fix (RMVPTF) command.

*TEMP
The PTFs are applied as temporary PTFs.
*PERM
The PTFs are applied permanently.

Delayed PTFs (DELAYED)

Specifies whether immediate PTFs are applied at the time the command is processed or whether immediate and delayed PTFs are applied during the next unattended IPL.

*NO
Immediate PTFs that do not supersede delayed PTFs are applied at the time the command is processed. Delayed PTFs and immediate PTFs with delayed prerequisite or corequisite PTFs are ignored during the APYPTF request and are not applied. Immediate PTFs which have preconditions that are not satisfied are not applied. Immediate PTFs that supersede delayed PTFs are only applied when the delayed superseded PTFs have a status of Permanently applied or Superseded where the "Superseded by" PTF has a status of Permanently applied. A message is sent for each PTF that is not applied.
*YES
The PTFs identified, regardless of whether they are defined as delayed or immediate, are applied during the next unattended IPL. The Apply on unattended IPL (IPLAPY) parameter determines whether the PTFs are applied during the next unattended IPL, or whether a previous request to apply the PTFs during the next unattended IPL is canceled.
*IMMDLY
All the immediate PTFs that do not supersede delayed PTFs are applied and the delayed PTFs or PTFs with delayed prerequisites or corequisites are set to be applied at the next unattended IPL. Any immediate PTFs which have preconditions that are not satisfied are set to be applied at the next unattended IPL. Immediate PTFs that supersede delayed PTFs will be applied if the delayed superseded PTFs have a status of Permanently applied or Superseded where the "Superseded by" PTF has a status of Permanently applied. Otherwise, immediate PTFs that supersede delayed PTFs will be set to be applied at the next unattended IPL.

IPL apply options (IPLAPY)

Specifies the action that is done for delayed or immediate PTFs at the next unattended IPL.

Single values

*NO
Previous requests to apply the identified PTFs at the next unattended IPL are canceled.

Element 1: Apply at unattended IPL

*YES
The identified PTFs are applied at the next unattended IPL. The Extent of change (APY) parameter determines whether the apply operation is temporary or permanent.

Element 2: Prerequisite lic int code

The Licensed Internal Code prerequisites are applied immediately or at the next IPL depending on the values specified on the DELAYED parameter.

*APYPERM
If LICPGM(*ALL) is specified or APYREQ(*YES) is specified and a product's PTFs have prerequisite Licensed Internal Code fixes, then the required Licensed Internal Code fixes are also identified to be permanently applied.
*NOAPY
Prerequisite Licensed Internal Code fixes are not identified to be applied during the next unattended IPL. If prerequisite Licensed Internal Code fixes exist that are not permanently applied, this command stops.

Apply requisite PTFs (APYREQ)

Specifies whether the prerequisite and corequisite PTFs of the PTFs specified on the SELECT parameter, that are within the same product and release, are applied with the PTFs specified on the SELECT parameter list.

This parameter is valid only when *ALL is not specified in the SELECT parameter.

*NO
The corequisite and prerequisite PTFs are not applied with the SELECT parameter list. No PTFs are applied if any PTF specified in the list has requisite PTFs not also in the list or already applied. Messages identify the missing requisite PTFs and the PTFs that require them.
*YES
The PTFs are applied with the SELECT parameter list.

Examples

Example 1: Applying PTFs Temporarily

APYPTF   LICPGM(57xxSS1)  DELAYED(*YES)

This command applies all the programming fixes that affect the operating system (57xxSS1). The fixes are temporarily applied at the next IPL.

Example 2: Applying PTFs Permanently

APYPTF   LICPGM(57xxSS1)  SELECT(SI00003 SI00008 SI00012)
         APY(*PERM)  DELAYED(*YES)

This command permanently applies PTFs SI00003, SI00008, and SI00012 to the operating system in library QSYS at the next IPL.

Example 3: Applying All Loaded PTFs

APYPTF   LICPGM(*ALL)  DELAYED(*IMMDLY)

This command permanently applies all PTFs that can be applied immediately and sets the rest to be applied at the next IPL.

Example 4: Applying Immediate PTFs and their Immediate Corequisites and Prerequisites at the Time the Command is Run

APYPTF   LICPGM(57xxSS1)  SELECT(SI00003 SI00008 SI00012)
         APYREQ(*YES)

This command applies the identified PTFs and their corequisites and prerequisites at the time the command is run if the PTFs and their corequisites and prerequisites are defined as immediate. PTFs defined as delayed or defined with corequisites or prerequisites defined as delayed are ignored along with the delayed requisites.

Example 5: Applying PTFs and their corequisites and prerequisites at the next IPL

APYPTF   LICPGM(57xxSS1)  SELECT(SI00003 SI00008 SI00012)
         DELAYED(*YES)  APYREQ(*YES)

This command applies the identified PTFs and their corequisites and prerequisites at the next IPL regardless of whether they are defined as delayed or immediate.

Example 6: Applying PTFs and their corequisites and prerequisites as soon as possible

APYPTF   LICPGM(57xxSS1)  SELECT(SI00003 SI00008 SI00012)
         DELAYED(*IMMDLY)  APYREQ(*YES)

This command applies the identified PTFs and their corequisites and prerequisites at the time the command is run if the PTFs and their corequisites and prerequisites are defined as immediate. PTFs defined as delayed or defined with corequisites or prerequisites defined as delayed are applied during the next IPL along with the delayed requisites.

Error messages

*ESCAPE Messages

CPF0C4B
Product availability object &2/&1 recovery required.
CPF0C4C
Cannot allocate object &1 in library &2.
CPF0C4D
Error occurred while processing object &1 in library &2.
CPF2150
Object information function failed.
CPF2151
Operation failed for &2 in &1 type *&3.
CPF35AA
Licensed internal code PTF &2 already applied.
CPF35AB
Licensed Internal Code fix &2 not applied.
CPF35A0
Cannot allocate library &1.
CPF35A1
Wrong copy of Licensed Internal Code in use.
CPF35A2
Required hardware changes not installed for PTF &2.
CPF35A3
Licensed Internal Code fix &2 not temporarily applied.
CPF35A5
Licensed Internal Code fix &2 not permanently applied.
CPF35A9
Error occurred while processing Licensed Internal Code fix.
CPF35CF
PTF &1-&2 not applied.
CPF35D0
Licensed Internal Code fix &1-&2 &4 not set to be removed permanently.
CPF35EB
Multiple releases of product &1 installed.
CPF35E3
Interface error detected.
CPF35E4
Information for PTF &1-&2 &4 not complete.
CPF35FA
PTF &1-&2 not applied.
CPF3544
Apply IPL action cannot be removed for PTF &1-&2 &4.
CPF3558
Cannot allocate &1 in &3 type *&2.
CPF3564
PTF &1-&2 damaged.
CPF3583
PTF not applied because error occurred.
CPF3576
Error occurred while applying PTFs for product &1.
CPF3596
PTF numbers in select/omit list not permitted.
CPF3598
PTF function already in process.
CPF3602
PTF &2 not removed because it is permanently applied.
CPF3606
Product &1 &3 not installed.
CPF361D
Apply order of PTFs cannot be determined.
CPF3612
Library &1 not found.
CPF362C
Insufficient storage for Licensed Internal Code fix.
CPF362D
PTF apply completed successfully, but some PTFs need additional actions.
CPF3640
No immediate PTFs applied.
CPF3660
No program temporary fixes identified.
CPF3693
Service function ended because error occurred.
CPF3931
Required programs not found. PTF incomplete.
CPF3945
Records of PTF activity for licensed program are deleted.
CPF8191
Product definition &4 in &9 damaged.
CPF8193
Product load object &4 in &9 damaged.
CPF9845
Error occurred while opening file &1.
CPF9846
Error while processing file &1 in library &2.