Provisioning Services: PVS Servers May Stop Responding Or Target Devices May Freeze During Startup Due To Large Size Of MS SQL Transaction Logs

Backup the XenApp/XenDesktop Site and PVS database and the Transaction log file to trigger the Transaction log auto truncation.

The transaction log should be backed up on the regular basis to avoid the auto growth operation and filling up a transaction log file.

Reference: https://docs.microsoft.com/en-us/sql/relational-databases/backup-restore/back-up-a-transaction-log-sql-server?view=sql-server-2017​

ADDITIONAL INFORMATION

Ideally Transaction log will be truncated automatically after the following events:

  • Under the simple recovery model, unless some factor is delaying log truncation, an automatic checkpoint truncates the unused section of the transaction log.In the Simple recovery there is little chance for the transaction log growing – just in specific situations when there is a long running transaction or transaction that creates many changes
  • By contrast, under the full and bulk-logged recovery models, once a log backup chain has been established, automatic checkpoints do not cause log truncation. Under the full recovery model or bulk-logged recovery model, if a checkpoint has occurred since the previous backup, truncation occurs after a log backup (unless it is a copy-only log backup). There is no automated process of transaction log truncation, the transaction log backups must be made regularly to mark unused space available for overwriting. Bulk-logged recovery model reduces transaction log space usage by using minimal logging for most bulk operations

Transaction log file size may not decrease even if transaction log has been truncated automatically.

Log truncation frees space in the log file for reuse by the transaction log. Log truncation is essential to keep the log from filling. Log truncation deletes inactive virtual log files from the logical transaction log of a SQL Server database, freeing space in the logical log for reuse by the Physical transaction log. If a transaction log were never truncated, it would eventually fill all the disk space that is allocated to its physical log files.

It is recommended also to keep the transaction log file in a separate drive from the database data files, as placing both data and log files on the same drive can result poor database performance.

Related:

Case Analyzer is not working

CaseAnalyzer is not working, no latest audit log although service is running

Error in log:

“CAPublisher c2dce3b9 [Error] Unexpected exception occurred while
processing task CAPublisher for store CASTORE.; Exception:
com.microsoft.sqlserver.jdbc.SQLServerException: The query processor
ran out of internal resources and could not produce a query plan. This
is a rare event and only expected for extremely complex queries or
queries that reference a very large number of tables or partitions.
Please simplify the query. If you believe you have received this
message in error, contact Customer Support Services for more
information.”

Related:

WTRN0025E exceptions causing WebSphere Application Server V8.5.5 startup failure

WTRN0025E:Recovery of Transaction failed javax.transaction.SystemException:
java.lang.Exception: Invalid Xid/recoveryId in transaction log
at com.ibm.ws.tx.jta.RegisteredResources.reconstruct
(RegisteredResources.java:240)
at com.ibm.tx.jta.impl.TransactionImpl.reconstruct(TransactionImpl.java:747)
at com.ibm.ws.tx.jta.RecoveryManager.handleTranRecord(RecoveryManager.java:1015)
at com.ibm.tx.jta.impl.RecoveryManager.replayTranLog(RecoveryManager.java:497)
at com.ibm.tx.jta.impl.RecoveryManager.run(RecoveryManager.java:2108)
at java.lang.Thread.run(Thread.java:801)
Caused by: java.lang.Exception: Invalid Xid/recoveryId in transaction
log
at com.ibm.tx.jta.impl.JTAXAResourceImpl.(JTAXAResourceImpl.
java:193)
at com.ibm.ws.tx.jta.JTAXAResourceImpl.(JTAXAResourceImpl.
java:131)
at com.ibm.ws.tx.jta.RegisteredResources.reconstruct
(RegisteredResources.java:218)

WTRN0045W: The transaction service cannot recover resource
00000000000000000000000a0002. The exception stack trace follows:
java.lang.Exception: Invalid Xid/recoveryId in transaction log
at
com.ibm.tx.jta.impl.JTAXAResourceImpl.(JTAXAResourceImpl.java:193)
at
com.ibm.ws.tx.jta.JTAXAResourceImpl.(JTAXAResourceImpl.java:131)
at
com.ibm.ws.tx.jta.RegisteredResources.reconstruct(RegisteredResources.ja
va:218)
at
com.ibm.tx.jta.impl.TransactionImpl.reconstruct(TransactionImpl.java:747
)
at
com.ibm.ws.tx.jta.RecoveryManager.handleTranRecord(RecoveryManager.java:
1015)
at
com.ibm.tx.jta.impl.RecoveryManager.replayTranLog(RecoveryManager.java:4
97)
at
com.ibm.tx.jta.impl.RecoveryManager.run(RecoveryManager.java:2108)
at
java.lang.Thread.run(Thread.java:801)

Related:

Questions related to storing transaction and compensation logs in a relational database for high availability and disaster recovery

I have a few questions about this developerWorks article:

Storing transaction and compensation logs in a relational database for high availability and disaster recovery in IBM Business Process Manager
https://www.ibm.com/developerworks/bpm/bpmjournal/1409_wang/1409_wang.html

Q1: When writing transaction and compensation logs to the database, there is a field that requires either the Transaction Log Directory or Recovery Log Directory set. The last parameter is for the tablesuffix. If I have only one cluster, can I name tablesuffix the same for both my cluster members?

Q2: I am using Stray Node topology. Should the transaction and compensation logs on the standby node be configured to write to the database or would that be only for primary?

Q3: Does it matter which schema owner is used in the data source authentication?

Q4: With a single cluster, the App/Sup/ME Clusters are all combined. Since all the transaction and compensation logs are combined, would the Container Settings for both Transaction Services and Compensation Settings be the same?

Related:

Which databases are supported in WAS v8.5.5.x for storing transaction logs?

I want to find out, which databases are supported to store transaction logs in WAS v8.5.5.x. I already found the following link: http://www-01.ibm.com/support/docview.wss?uid=swg27038432
But in this link I did not notice if any other databases like postgresql or MariaDB are supported. So do you know, which databases are supported in WAS v8.5.5.x?
transaction, log, database, supported, WAS

Related:

NetWorker: MSSQL backup and logs truncation

NetWorker Module for Microsoft

How NetWorker Module for Microsoft backup works with MSSQL logs truncation?

The “truncation of logs” will happen under the following only when backup software used:

– Incremental or differential backups only if the DB running full or full-bulk recovery model.

– Full backup if “-T” trailed to the backup command.

Log truncation frees space in the log file for reuse by the transaction log. Log truncation is essential to keep the log from filling. Log truncation deletes inactive virtual log files from the logical transaction log of a SQL Server database, freeing space in the logical log for reuse by the Physical transaction log. If a transaction log were never truncated, it would eventually fill all the disk space that is allocated to its physical log files. To avoid this problem, unless log truncation is being delayed for some reason, truncation occurs automatically after the following events:

Under the simple recovery model, after a checkpoint. (Not support with NetWorker Module for Microsoft (NMM))

Under the full recovery model or bulk-logged recovery model, if a checkpoint has occurred since the previous backup, truncation occurs after a log backup (unless it is a copy-only log backup).

Log truncation does not reduce the size of the physical log file.

For a detailed resolution please refer to DELL EMC Support Solution 479280https://support.emc.com/kb/479280



YOU MAY ALSO BE INTERESTED IN THE FOLLOWING CONTENTS FOR NetWorker:



Top Services Topics

Video Playlist

p

Related:

How is possible to monitor on DB2 how many LOGs are span the active transaction on the system?

The command db2pd -d -transactions can be used for this porpouse. but
I couldn’t find an equivalent table function or administrative view for db2pd -transaction output which shows
the the LOG file names for First LSN and Last LSN..

For Linux platform, I wrote the following command using db2pd and db2flsn which shows you by application handle having an active transaction which is the starting and finishing LOG file name.

You must only replace the database name “sam” with your database.

db2pd -d sam -transactions | tail -n +6 | head -n -3 | awk ‘{ if ($9 != “0x0000000000000000”) {system(“echo APP handle “$2″”);$9=substr($9,3,17);$10=substr($10,3,17);system(“echo START with”);system(“db2flsn -db sam “$9″”);system(“echo FINISH with”);system(“db2flsn -db sam “$10″”);system(“echo n”)}}’

Output will be like:

APP handle 353
START with
Given LSN is in log file S0000008.LOG
FINISH with
Given LSN is in log file S0000008.LOG

APP handle 440
START with
Given LSN is in log file S0000008.LOG
FINISH with
Given LSN is in log file S0000010.LOG

Related: