PMF Runtime Scheduler Troubleshooting
Overview
Scheduler job of Persistent Mobile Foundation Runtime.
The scheduler job does the following tasks:
1) Marks the data for License Tracking and saves the data to license tracking related tables.
2) Clean up MFP_TRANSIENT_DATA
and MFP_PERSISTENT_DATA
. For more information, see Purge runtime tables.
JNDI properties for 1 and 2 above are enabled by default for liberty. To enable the scheduler in WebSphere Application Server, set the value to true. If JNDI properties related to 1 or 2 above is enabled, then the scheduler runs.
Persistent Mobile Foundation runtime scheduler runs by default between 1AM and 2AM. In the case of farm with multiple servers, the scheduler runs from all servers. The starting time of scheduler in each server is few random minutes apart. The scheduler runs 4 hours after a server restart. For example, if the servers start at 8PM today, the scheduler runs the following day 1 AM. But if the server was restarted at 11 PM today, the scheduler does not run the following day 1 AM as the gap is not 4 hours between server start and scheduler’s scheduled run time. In this case, the scheduler runs at 1 AM, the day after.
The scheduler start time can be configured using the JNDI property, mfp.scheduler.startHour, which takes values from 1 to 23. With this property, the scheduler run can be set to any time of your preference instead of the default 1 AM. Using this property, you can can configure your scheduler to start at your light traffic hours and can also ensure that the scheduler runs despite the daily start of the server. If you restart your server every night at 1 AM, then you can set the value for mfp.scheduler.startHour
to 5. This ensures a 4 hours gap between server restart and the scheduler runs at 5 AM.
Keep the license tracking disabled as the license tracking activities are database intensive. Only if you use the Persistent Mobile Foundation addressable devices licensing model, you need to run license tracking.
If you have not enabled license tracking, then use the purge feature to do the following:
- Clean up the old records.
- Maintain
MFP_PERSISTENT_DATA
andMFP_TRANSIENT_DATA
tables for better performances of Persistent Mobile Foundation Platform.
Combination of flags and impact on PMF tables
mfp.licenseTracking.enabled | mfp.purgedata.enabled | mfp.purgeOldData.age | MFP_PERSISTENT_DATA | MFP_TRANSIENT_DATA |
---|---|---|---|---|
true | false | 0 (default) | Deletes records older than days = sum of values of JNDI properties, mfp.device.decommission.when and mfp.device.archiveDecommissioned.when |
|
Deletes records with expiresAt value 5 days prior to current day |
||||
true | true | 0 (default) | Deletes records older than days = sum of JNDI properties, mfp.device.decommission.when and mfp.device.archiveDecommissioned.when . |
|
Deletes records with expiresAt value 5 days prior to current day. |
||||
false | true | 0 (default) | Records are not deleted | Delete records with expiresAt column value 5 days prior to the current day. |
false | false | 0 (default) | No action | No action |
true | false | >=90 | Follows rules of License tracking: Deletes records older than days = sum of JNDI properties, mfp.device.decommission.when and mfp.device.archiveDecommissioned.when . The mfp.purgeOldData.age value is not considered. |
Deletes records with expiresAt column value 5 days prior to current day. |
false | true | >=90 | Deletes records older than days specified by JNDI property mfp.purgeOldData.age |
Deletes records with expiresAt column value 5 days prior to current day. |
Messages in PMF logs to troubleshoot purge related issues
-
Default, when there are no messages or traces enabled, the following message is available in the logs:
Configure your apps to collect analytics on the Network device event. FWLSE0293I: License tracking will run at < date and time>
For example:
FWLSE0293I: License tracking will run at 'Wed Nov 11 01:23:00 IST 2020'.` This message is only one time, during server start.
-
The following messages are available in every day log at the time the scheduler starts and ends the license tracking or purge operation:
FWLSE0294I: Processing platform usage on <date and time>` and `FWLSE0295I: Processing platform usage ended at <date and time>`.
-
If the flags
mfp.purgedata.enabled
is true andmfp.purgeOldData.age
is non zero, then records fromMFP_PERSISTENT_DATA
are deleted, base. Deletion happens in batches of 5000 records. This message shows the batch number and time taken to delete that batch:FWLSE0291I: Completed deletion of <number> batches in <time elapsed> ms
-
In addition, there are further logging that can be enabled by setting the tracing option to
com.ibm.mfp.server.core.internal.*=debug