DB2常见问题解决

本文主要探讨了DB2数据库遇到事务日志已满(SQL0964C错误)的问题,并提供了通过获取数据库配置(db2 get db cfg)来检查和解决此问题的方法。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

 
DB2常见问题解决

 

1. DB2 SQL error code -964 while migrating data
  • SQL0964C The transaction log for the database is full.

1.1Get SQLCODE: -964, SQLSTATE: 57011

You get this error message when migrating IBM TotalStorage Productivity Center data.
Problem
When migrating IBM TotalStorage Productivity Center data, you get this error message in the database installation log:

Instruction SQL : insert into t_stat_file_temp
SQLSTATE: 57011, Vendor error code: -964
DB2 SQL error: SQLCODE: -964, SQLSTATE: 57011,
SQLERRMC: null
Explanation:

All space in the transaction log is being used.

If a circular log with secondary log files is being used, an
attempt has been made to allocate and use them. When the file
system has no more space, secondary logs cannot be used.

If an archive log is used, then the file system has not provided
space to contain a new log file.

The statement cannot be processed.
This indicates that the transaction log file is not large enough to handle the migration.

Action
To configure the size of the transaction log, modify the following parameters:

Log file size (4KB) (LOGFILSIZ) = 1024
Number of primary log files (LOGPRIMARY) = 3
Number of secondary log files (LOGSECOND) = 2

When connected to the database, under the DB2 command line processor, you can update the parameters using the following command:

update db cfg using <parameter> <value>

For example, to modify the LOGFILSIZ parameter, run this command:

update db cfg using logfilsiz 1024

解决方案:
To check the current configuration settings, run the following the command from a DB2 Command prompt:

  1. db2 get db cfg

This error message is a result of running out of space in the transaction log. The transaction log configuration is set as:

db2 update db cfg for $DBNAME using logprimary 8
db2 update db cfg for $DBNAME using logsecond 16
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值