最近需要把某一数据库版本从V9.7.5到V10.1.2,第一次升级到10版本,相对比较新鲜。此前数据库大小版本升级很多,相对比较轻松,但这次升级遇到了一些问题,从中也学习到了很多东西,升级过程中不是一个人在战斗,需高人点拨,在这里,我心里默默念道他们的名字,感谢他们在我工作中给予得支持。
此次升级采用副本安装的方式进行升级(在DB2软件安装过程中增加了purescale的安装交互,这里选择NO),安装副本成功。
停掉升级的实例后,清理db2相关进程和ipclean缓存。
执行./db2iupgrade instance_name
执行了一段时间后报错,报错信息如下:
AUAT:/dbsoft/DB2/10.1.2/AIX/server#./db2_install -b /db2/software/10.1.2 -p ese
Requirement not matched for DB2 database "Server" "". Version: "10.1.0.2".
Summary of prerequisites that are not met on the current system:
Required minimum "XL C/C++ Runtime" level: "11.1.0.1"
Actual version: "10.1.0.2"
Required minimum technology level: "6" Service pack: "5"
Actual technology level: "4" Service pack: "4"
DBI1324W Support of the db2_install command is deprecated. For
more information, see the DB2 Information Center.
错误很直接,操作系统版本过低,打系统补丁喽。
打完补丁查看信息如下:
$oslevel -s
6100-06-08-1216
$lslpp -l |grep -i xlc
xlC.aix61.rte 11.1.0.1 COMMITTED XL C/C++ Runtime for AIX 6.1
xlC.cpp 9.0.0.0 COMMITTED C for AIX Preprocessor
xlC.msg.EN_US.cpp 9.0.0.0 COMMITTED C for AIX Preprocessor
xlC.msg.ZH_CN.cpp 9.0.0.0 COMMITTED C for AIX Preprocessor
xlC.msg.en_US.cpp 9.0.0.0 COMMITTED C for AIX Preprocessor
xlC.msg.en_US.rte 11.1.0.1 COMMITTED XL C/C++ Runtime
xlC.msg.zh_CN.cpp 9.0.0.0 COMMITTED C for AIX Preprocessor
xlC.rte 11.1.0.1 COMMITTED XL C/C++ Runtime
xlC.sup.aix50.rte 9.0.0.1 COMMITTED XL C/C++ Runtime for AIX 5.2
这次操作系统满足了数据库升级条件,停掉升级的实例后,清理db2 相关进程和ipclean缓存。执行./db2iupgrade instance_name ,执行了一段时间又报错了。
报错信息如下:
DBI1446I The db2iupgrade command is running.
DB2 installation is being initialized.
Total number of tasks to be performed: 4
Total estimated time for all tasks to be performed: 309 second(s)
Task #1 start
Description: Setting default global profile registry variables
Estimated time 1 second(s)
Task #1 end
Task #2 start
Description: Initializing instance list
Estimated time 5 second(s)
Task #2 end
Task #3 start
Description: Configuring DB2 instances
Estimated time 300 second(s)
Task #3 end
Task #4 start
Description: Updating global profile registry
Estimated time 3 second(s)
Task #4 end
A minor error occurred during the execution.
For more information see the DB2 installation log at
"/tmp/db2iupgrade.log.3342696".
Required: Review the following log file also for warnings or errors:
"/tmp/db2iupgrade_local.log.*"
DBI1264E Errors were encountered in running db2iupgrade. Please
refer to the installation log file /tmp/db2iupgrade.log.3342696 for more
information.
Explanation:
All processed and failed operations have been saved into this log file.
User response:
Do not modify this file in any way. This file is for IBM Technical
Support reference.
从升级信息可以知道,一共有4个tasks(#1 Setting default global profile registry variables #2 Initializing instance list #3 Configuring DB2 instances #4 Updating global profile registry ),这里没有明确指出错误,只是说A minor error occurred during the execution.根据以往的经验,直接查看/tmp下的日志能解决基本问题。
于是乎按报错信息,打开/tmp/db2iupgrade.log.3342696
$more /tmp/db2iupgrade.log.3342696
DB2 Setup log file started at: Thu May 16 10:08:04 2013 BEIST
Operating system information: AIX 6.1
Existing instances to configure:
Instance name: peadmin
Instance user information:
User name: peadmin
Fenced user information:
User name: peadmin
Setting default global profile registry variables :.......Success
Initializing instance list :.......Success
ERROR: An error occurred while upgrading the instance "peadmin". The return
value is "1". If the problem persists contact your technical service
representative.
ERROR: An error occurred while configuring the instance "peadmin".
Configuring DB2 instances :.......Failure
Updating global profile registry :.......Success
Post Install Recommendations
-----------------------------
Required steps:
There were some errors detected during DB2 installation. To collect the information files from the system, run the "db2support -install" command with the pro
per options before reporting the problem to IBM service. For information regarding the usage of the db2support tool, check the DB2 Information Center.
DB2 Text Search has not been configured for the instance "peadmin".To automatically configure DB2 text search services, run the db2iupdt command (or the db2n
rupdt command for non-root installations) specifying the -j "TEXT_SEARCH" option.Manual configuration steps can be found in the DB2 Text Search documentation
"http://publib.boulder.ibm.com/infocenter/db2luw/v10r1/topic/com.ibm.db2.luw.admin.ts.doc/doc/t0052968.html".
Optional steps:
To validate your installation files, instance, and database functionality, run the Validation Tool, /db2/software/10.1.1/bin/db2val. For more information, se
e "db2val" in the DB2 Information Center.
Open First Steps by running "db2fs" using a valid user ID such as the DB2 instance owner's ID. You will need to have DISPLAY set and a supported web browser
in the path of this user ID.
Verify that you have access to the DB2 Information Center based on the choices you made during this installation. If you performed a typical or a compact ins
tallation, verify that you can access the IBM Web site using the internet. If you performed a custom installation, verify that you can access the DB2 Informa
tion Center location specified during the installation.
Ensure that you have the correct license entitlements for DB2 products and features installed on this machine. Each DB2 product or feature comes with a licen
se certificate file (also referred to as a license key) that is distributed on an Activation CD, which also includes instructions for applying the license fi
le. If you purchased a base DB2 product, as well as, separately priced features, you might need to install more than one license certificate. The Activation
CD for your product or feature can be downloaded from Passport Advantage if it is not part of the physical media pack you received from IBM. For more informa
tion about licensing, search the Information Center (http://publib.boulder.ibm.com/infocenter/db2luw/v10r1/index.jsp) using terms such as "license compliance
", "licensing" or "db2licm".
根据报错信息,还是没有发现可直接操作的信息,也就是说没有明确说明升级错在哪里,只是知道了Configuring DB2 instances :.......Failure ,问题出现在第三个task,here were some errors detected during DB2 installation. 怀疑可是是安装副本时哪里出了问题。
执行more /tmp/db2prereqcheck.log.3211658 check了一下,信息如下:
Checking DB2 prerequisites for DB2 database version "10.1.0.2" on operating system "AIX"
Validating "kernel level " ...
Required minimum operating system kernel level: "6.1".
Actual operating system kernel level: "6.1".
Requirement matched.
Validating "AIX technology level and service pack " ...
Required minimum technology level: "6" Service pack: "5"
Actual technology level: "6" Service pack: "8"
Requirement matched.
Validating "XL C/C++ Runtime" ...
Required minimum "XL C/C++ Runtime" level: "11.1.0.1"
Actual version: "11.1.0.1"
Requirement matched.
DBT3533I The db2prereqcheck utility has confirmed that all installation prerequisites were met for DB2 database "server " "". Version: "10.1.0.2".
check没有问题。还是安装了一个10.1.1与之前的不一样副本。结果还是报了相同的错误,这次排除了副本的影响。
无奈之下,查看了其它日志记录,在实例目录下的upgrade.log。查看upgrade.log的更新时间与升级时间相符合。
$more upgrade.log
Version of DB2CKUPGRADE being run: VERSION "10.1"
Database: "RSPDB"
DBT5537I The db2ckupgrade utility has completed processing for database "RSPDB".
Database: "RSPDB1"
DBT5537I The db2ckupgrade utility has completed processing for database "RSPDB1".
Database: "PE"
DBT5525N The db2ckupgrade utility failed with an unhandled error.
DBT5537I The db2ckupgrade utility has completed processing for database "PE".
DBT5529N The db2ckupgrade utility did not complete successfully. The database cannot be upgraded. The output log file is named "/home/peadmin/upgrade.log".
在这里有新的发现,升级实例过程中,db2ckupgrade 会检查数据库,RSPDB和RSPDB1着两个库正确,PE检查失败。此次我们把注意力集中到PE数据库(此前升级实例时,没有关注到升级实例会check数据库本身)。数据库若有问题应该会在db2diag.log中有错误记录。
执行db2diag -A,重复升级过程,截取发生错误时间点的db2diag.log日志。
cd "$HOME"/sqllib/db2dump
more db2diag.log
*****************************
2013-05-16-08.57.49.113864+480 E137673584A635 LEVEL: Warning
PID : 2818556 TID : 3343 PROC : db2sysc 0
INSTANCE: peadmin NODE : 000 DB : PE
APPHDL : 0-7 APPID: *LOCAL.peadmin.130516005740
AUTHID : PEADMIN
EDUID : 3343 EDUNAME: db2agent (PE) 0
FUNCTION: DB2 UDB, buffer pool services, sqlbStartPools, probe:19
MESSAGE : ADM6047W The table space "IDX_CHS" ( ID "25") is in the DROP_PENDING
state. The table space will be kept OFFLINE. The table space state
is 0x"C000". This table space is unusable and should be dropped.
2013-05-16-08.57.49.114159+480 I137674220A511 LEVEL: Error
PID : 2818556 TID : 3343 PROC : db2sysc 0
INSTANCE: peadmin NODE : 000 DB : PE
APPHDL : 0-7 APPID: *LOCAL.peadmin.130516005740
AUTHID : PEADMIN
EDUID : 3343 EDUNAME: db2agent (PE) 0
FUNCTION: DB2 UDB, buffer pool services, sqlbStartPools, probe:19
MESSAGE : ZRC=0x8002014D=-2147352243=SQLB_NOT_ALLOWED_DROP_P
"Access not allowed. Tblspc Drop Pending."
2013-05-16-08.57.49.299217+480 E137674732A650 LEVEL: Warning
PID : 2818556 TID : 3343 PROC : db2sysc 0
INSTANCE: peadmin NODE : 000 DB : PE
APPHDL : 0-7 APPID: *LOCAL.peadmin.130516005740
AUTHID : PEADMIN
EDUID : 3343 EDUNAME: db2agent (PE) 0
FUNCTION: DB2 UDB, buffer pool services, sqlbStartPools, probe:19
MESSAGE : ADM6047W The table space "WUH_SHL_IDX" ( ID "27") is in the
DROP_PENDING state. The table space will be kept OFFLINE. The table
space state is 0x"C000". This table space is unusable and should be
dropped.
2013-05-16-08.57.49.299521+480 I137675383A511 LEVEL: Error
PID : 2818556 TID : 3343 PROC : db2sysc 0
INSTANCE: peadmin NODE : 000 DB : PE
APPHDL : 0-7 APPID: *LOCAL.peadmin.130516005740
AUTHID : PEADMIN
EDUID : 3343 EDUNAME: db2agent (PE) 0
FUNCTION: DB2 UDB, buffer pool services, sqlbStartPools, probe:19
MESSAGE : ZRC=0x8002014D=-2147352243=SQLB_NOT_ALLOWED_DROP_P
"Access not allowed. Tblspc Drop Pending."
在这里有重大发现,提示The table space state is 0xC000. This table space is unusable and should be dropped."Access not allowed. Tblspc Drop Pending."
db2pd -d pe -tab 查看表空间的State,发现有大量的0x0000C000。截取部分如下所示:
Tablespace Statistics:
Address Id TotalPgs UsablePgs UsedPgs PndFreePgs FreePgs HWM Max HWM State MinRecTime NQuiescers PathsDropped
0x070000036E01A080 0 927760 927744 926316 0 1428 926316 926316 0x00000000 0 0 No
0x070000036E01BE20 1 4 4 4 0 0 0 0 0x00000000 0 0 No
0x070000036E01FBA0 2 336640 336512 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E0210E0 3 1 1 1 0 0 0 0 0x00000000 0 0 No
0x070000036E024840 4 1 1 1 0 0 0 0 0x00000000 0 0 No
0x070000036E027FA0 5 2064 2048 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E0294E0 6 12653600 12653568 2324064 0 10329504 12553536 12553536 0x00000000 0 0 No
0x070000036E02AC60 7 12028640 12028608 882848 0 11145760 11879328 11879328 0x00000000 0 0 No
0x070000036E02C3E0 8 8704 8672 832 0 7840 832 832 0x00000000 0 0 No
0x070000036E02DB60 9 5360 5312 64 0 5248 64 64 0x00000000 0 0 No
0x070000036E031320 10 5360 5312 64 0 5248 64 64 0x00000000 0 0 No
0x070000036E034AE0 11 7864320 7864256 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E036880 12 2621440 2621408 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E038200 13 18304 18272 752 0 17520 752 752 0x00000000 0 0 No
0x070000036E039B80 14 32768 32736 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E03B500 15 491520 491488 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E03CE80 16 491520 491488 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E03E800 17 1703936 1703872 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E0405A0 18 5898240 5898176 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E042340 19 1966080 1966048 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E043CC0 20 1507328 1507264 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E045A60 21 1483040 1483024 363088 0 1119936 1459488 1459488 0x00000000 0 0 No
0x070000036E0471E0 22 755360 755344 95312 0 660032 731632 731632 0x00000000 0 0 No
0x070000036E048960 23 159376 159360 123408 0 35952 142592 142592 0x00000000 0 0 No
0x070000036E04A0E0 24 3932160 3932096 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E04BE80 25 163840 163808 0 0 0 0 0 0x0000C000 0 0 No
0x070000036E04D800 26 65536 65504 4992 0 60512 4992 499
执行db2tbst 0x0000C000 显示如下:
State = Offline and not accessible
+ Drop pending
查看离线表空间对应路径。
Containers:
Address TspId ContainNum Type TotalPgs UseablePgs PathID StripeSet Container
0x070000036E01B5C0 0 0 File 231940 231936 0 0 /pedata/pedata1/peadmin/NODE0000/PE/T0000000/C0000000.CAT
0x070000036E01B7D0 0 1 File 231940 231936 1 0 /pedata/pedata2/peadmin/NODE0000/PE/T0000000/C0000001.CAT
0x070000036E01B9E0 0 2 File 231940 231936 2 0 /pedata/pedata3/peadmin/NODE0000/PE/T0000000/C0000002.CAT
0x070000036E01BBF0 0 3 File 231940 231936 3 0 /pedata/pedata4/peadmin/NODE0000/PE/T0000000/C0000003.CAT
0x070000036E01D300 1 0 Path 1 1 0 0 /pedata/pedata1/peadmin/NODE0000/PE/T0000001/C0000000.TMP
0x070000036E01D510 1 1 Path 1 1 1 0 /pedata/pedata2/peadmin/NODE0000/PE/T0000001/C0000001.TMP
0x070000036E01D720 1 2 Path 1 1 2 0 /pedata/pedata3/peadmin/NODE0000/PE/T0000001/C0000002.TMP
0x070000036E01D930 1 3 Path 1 1 3 0 /pedata/pedata4/peadmin/NODE0000/PE/T0000001/C0000003.TMP
0x070000036E0225C0 3 0 Path 1 1 - 0 /pedata/petmp/tempspace01
0x070000036E025D20 4 0 Path 1 1 - 0 /pedata/petmp/TEMPSPACE02
0x070000036E02AA20 6 0 File 12653600 12653568 - 0 /pedata/pedata1/TBS_PE
0x070000036E02C1A0 7 0 File 12028640 12028608 - 0 /pedata/peidx/IDX_PE
0x070000036E02D920 8 0 File 8704 8672 - 0 /pedata/pedata1/TBS_PE_32
0x070000036E02F0A0 9 0 File 5360 5312 - 0 /pedata/pedata1/TBS_TMP_PE
0x070000036E032860 10 0 File 5360 5312 - 0 /pedata/pedata1/TBS_TMP_IPE
0x070000036E036020 11 0 File 1966080 1966064 - 0 /pedata1/BEJ_SL_TBS
0x070000036E036230 11 1 File 1966080 1966064 - 0 /pedata2/BEJ_SL_TBS
0x070000036E036440 11 2 File 1966080 1966064 - 0 /pedata3/BEJ_SL_TBS
0x070000036E036650 11 3 File 1966080 1966064 - 0 /pedata4/BEJ_SL_TBS
0x070000036E037DC0 12 0 File 1310720 1310704 - 0 /peidx/BEJ_SL_IDX
0x070000036E037FD0 12 1 File 1310720 1310704 - 0 /peidx1/BEJ_SL_IDX
0x070000036E039740 13 0 File 9152 9136 - 0 /pedata/peidx/IDX_CFD
0x070000036E039950 13 1 File 9152 9136 - 0 /pedata/peidx1/IDX_CFD
0x070000036E03B0C0 14 0 File 16384 16368 - 0 /peidx/IDX_CHC
0x070000036E03B2D0 14 1 File 16384 16368 - 0 /peidx1/IDX_CHC
0x070000036E03CA40 15 0 File 245760 245744 - 0 /peidx/IDX_CHD
0x070000036E03CC50 15 1 File 245760 245744 - 0 /peidx1/IDX_CHD
0x070000036E03E3C0 16 0 File 245760 245744 - 0 /peidx/IDX_CHQ
0x070000036E03E5D0 16 1 File 245760 245744 - 0 /peidx1/IDX_CHQ
通过命令lsfs -a发现/pedata1 /pedata2 /pedata3 /pedata4 等路径已不存在,所以才导致表空间处于Offline and not accessible + Drop pending 的状态。
因DROP_PENDING的表空间较多,通过管理视图筛选state='DROP_PENDING'的表空间进行删除准确快捷。
在管理视图中寻找半天,发现sysibmadm.TBSP_UTILIZATION 有TBSP_STATE这样的字段来记录表空间的状态。
db2 -x "select rtrim(TBSP_NAME) from sysibmadm.TBSP_UTILIZATION where TBSP_STATE='OFFLINE + DROP_PENDING'"|wc -l
共130个处于DROP_PENDING的表空间需要删除。
修改脚本,批量删除表空间:
db2 -x "select 'db2 drop tablespace '|| rtrim(TBSP_NAME) || ',' from sysibmadm.TBSP_UTILIZATION where TBSP_STATE='OFFLINE + DROP_PENDING'"
$db2 drop tablespace TBS_RBD;
DB21034E The command was processed as an SQL statement because it was not a
valid Command Line Processor command. During SQL processing it returned:
SQL0282N Table space "TBS_SHY" cannot be dropped because at least one of the
tables in it, "UPEOSHY.RE_SL_JC_RYTD", has one or more of its parts in another
table space. SQLSTATE=55024
批量执行删除脚本报错,提示"UPEOSHY.RE_SL_JC_RYTD", has one or more of its parts in another table space.
$db2 "drop table UPEOSHY.RE_SL_JC_RYTD"
DB21034E The command was processed as an SQL statement because it was not a
valid Command Line Processor command. During SQL processing it returned:
SQL0290N Table space access is not allowed. SQLSTATE=55039
试图删除UPEOSHY.RE_SL_JC_RYTD这个表,提示Table space access is not allowed,单独这样执行(drop tablespace和drop table)就陷入了死循环。查看此表是否为表分区。
db2 describe data partitions for table UPEOSHY.RE_SL_JC_RYTD
PartitionId Inclusive (y/n) Inclusive (y/n)
Low Value High Value
----------- - ------------------------------- - -------------------------------
0 Y Y
1 record(s) selected.
说明UPEOSHY.RE_SL_JC_RYTD非表分区,接着查看一下该表的DDL语句。
$db2look -d pe -z UPEOSHY -t RE_SL_JC_RYTD -e
CREATE TABLE "UPEOSHY "."RE_SL_JC_RYTD" (
"JGDM" VARCHAR(20) NOT NULL ,
"FZRDM" VARCHAR(10) NOT NULL ,
"RYDM" VARCHAR(10) NOT NULL ,
"TJJGDM" VARCHAR(20) ,
"FLDM" VARCHAR(10) NOT NULL ,
"KSRQ" VARCHAR(10) NOT NULL ,
"JZRQ" VARCHAR(10) ,
"WHR_DM" VARCHAR(10) ,
"WHR_MC" VARCHAR(100) ,
"WHR_JGDM" VARCHAR(20) ,
"WHR_JGMC" VARCHAR(100) ,
"WHSJ" VARCHAR(19) )
COMPRESS YES
IN "TBS_SHY" INDEX IN "IDX_SHY" ;
这里看到表数据和表索引不在同一个表空间,验证了删除表空间的错误提示SQL0282N。
SQL0282N的错误提示,指定的表空间中的表的所有部分不全包含在该表空间中。如果指定了多个表空间,那么其中一个指定表空间中的表未在列表中包含其所有部分。基本表、索引或长数据可能在另一表空间中,所以删除表空间将不会完全删除该表。这将使该表处于不一致的状态,因而不能删除表空间。
也就是说,如果不删除与某个表空间相关联的所有表空间,那么不能删除该表空间。例如,如果在一个表空间中创建了表并在另一个表空间中创建了其索引,那么必须在一个 DROP TABLESPACE 命令中同时删除索引和数据表空间。
在DDL中,IN "TBS_SHY" INDEX IN "IDX_SHY" 的语句就决定了数据和索引表空间的关系,及时没有创建索引,在删除时也要同时删除这两个表空间,在本次操作中就遇到这样的问题,解决方法删除这两个表空间,重新建表。 如何同时删除数据和索引表空间,查看信息中心,没有找到同时删除得方法 ,还好有高人,高人总是在关键时候飘来,又随之飘去。于是乎执行如下命令,问题也解决了。
$db2 drop tablespace TBS_SHY,IDX_SHY
DB20000I The SQL command completed successfully.
为便于结果整理,稍微修改了一下SQL。
db2 -x "select rtrim(TBSP_NAME) || ',' from sysibmadm.TBSP_UTILIZATION where TBSP_STATE='OFFLINE + DROP_PENDING'"
一个表对应数据和索引2个表空间,应该同时删除,为了节省人力筛选,可直接放到一起,分批删除部分表空间(若不分批等待时间太长),其中只例举一部分表空间(根据命名名称确定数据和索引的表空间,避免因其中一个无法删除,而导致所有表空间删除操作的失败),删除部分Drop_pending表空间后,剩余部分执行如下:
db2 drop tablespace IDX_CHD, IDX_CHQ, IDX_FUZ, IDX_HEF, IDX_HUS, IDX_KUM, IDX_NAN, IDX_NCH, IDX_NIB, IDX_QID, IDX_QUZ, IDX_RBD, IDX_SHH, IDX_SHT, IDX_SJZ, IDX_SUZ, IDX_TIJ, IDX_WUH, IDX_WZH, IDX_XIM, IDX_ZHZ, TBS_BEJ, TBS_CHD, TBS_CHQ, TBS_FUZ, TBS_HEF, TBS_HUS, TBS_KUM, TBS_NAN, TBS_NCH, TBS_NIB, TBS_QID, TBS_QUZ, TBS_RBD, TBS_SHH, TBS_SHT, TBS_SJZ, TBS_SUZ, TBS_TIJ, TBS_WUH, TBS_WZH, TBS_XIM, TBS_ZHZ, IDX_BEJ
在执行表空间删除时,db2diag.log 会报错(No such file or directory)暂不用理会。报错信息如下:
2013-05-17-15.43.22.529650+480 I13006507A1726 LEVEL: Error (OS)
PID : 2491156 TID : 67045 PROC : db2sysc 0
INSTANCE: peadmin NODE : 000
APPHDL : 0-33841 APPID: *LOCAL.peadmin.130517074633
AUTHID : PEADMIN
EDUID : 67045 EDUNAME: db2agent (instance) 0
FUNCTION: DB2 Common, OSSe, ossGetDiskInfo, probe:90
MESSAGE : ECF=0x9000001A=-1879048166=ECF_FILE_DOESNT_EXIST
File doesn't exist
CALLED : OS, -, statvfs
OSERR : ENOENT (2) "No such file or directory"
DATA #1 : String, 7 bytes
/peidx1
DATA #2 : unsigned integer, 8 bytes
140
CALLSTCK: (Static functions may not be resolved correctly, as they are resolved to the nearest symbo
到此为止数据库所发现的问题已解决,咱接着升级实例。 停实例,重新执行升级命令,实例升级成功,接下来就是分别升级三个数据库和重新绑定了。就此升级任务完成,可是时间稍长了一些。
本次实例升级让我学到了很多东西(不知道这是10版本特有还是所有版本都是这样,以后会留意),也花些时间总结出来与大家一起分享,若有理解有误的地方,请到此一游的大侠们留下笔墨。
意外收获如下:
(1)以前认为副本升级是把实例目录和新副本软件做一个新连接,替换原有副本的连接,升级过程仅在实例层面上。通过本次升级发现,实例升级过程中prereqcheck环境后,会check当前实例下的所有数据库。
(2)以前认为升级实例时实例始终是停的。通过本次升级发现,实例会激活(以前总遇到升级过程中,实例自动启,并且有大量的app连接到数据库,非正常情况下升完级后,实例已启动,正确情况下需手工启动),升级完后,实例会停掉。
(3)以前认为升级实例时,错误信息不会记录到db2diag.log(认为实例停止不会记录)。通过本次升级发现,升级过程中错误信息会记录到db2diag.log,也就是激活实例后记录,升级完停掉实例。
添加新评论25 条评论
2013-07-16 18:34
2013-07-16 16:16
在DDL中,IN "TBS_SHY" INDEX IN "IDX_SHY" 的语句就决定了数据和索引表空间的关系,及时没有创建索引,在删除时也要同时删除这两个表空间,在本次操作中就遇到这样的问题,解决方法删除这两个表空间,重新建表。 如何同时删除数据和索引表空间,查看信息中心,没有找到同时删除得方法 ,还好有高人,高人总是在关键时候飘来,又随之飘去。于是乎执行如下命令,问题也解决了。 $db2 drop tablespace TBS_SHY,IDX_SHY
DB20000I The SQL command completed successfully.
学习了。。。。。。。。。。
2013-07-01 19:23
2013-07-01 16:57
2013-06-21 22:31
2013-06-21 15:22
2013-06-13 21:49
升级前的检查 还是灰常灰常 重要的
2013-06-13 21:48
2013-06-08 19:25
升级前的检查 还是灰常灰常 重要的
2013-06-06 14:26
2013-06-03 12:13
2013-06-03 09:46
2013-06-02 10:09
2013-06-02 10:07
2013-06-01 12:24
2013-06-01 10:58
2013-06-01 09:56
还没升10呢,去年刚升了9.7.备份恢复升的。
2013-06-01 09:54
还没升10呢,去年刚升了9.7.备份恢复升的。
2013-06-01 09:45
2013-05-31 17:04
2013-05-31 12:40
还没升10呢,去年刚升了9.7.备份恢复升的。
2013-05-29 21:00
2013-05-29 11:28
2013-05-21 21:25
2013-05-21 12:52