暂无图片
暂无图片
暂无图片
暂无图片
暂无图片

【译】修补 IBM Db2 实例

原创 剩余价值 2022-05-17
527

原文作者 丹尼尔·韦斯特曼   

原文链接https://blog.dbi-services.com/patching-an-ibm-db2-instance/


我使用 DB2 的下一个任务是应用补丁。在 DB2 世界中,有修改包和修订包。据我了解,修改包带有新功能,而修复包仅带有错误修复。使您的数据库安装保持最新很重要,这适用于所有产品。当我的系统运行 11.5 时,给我所有信息的页面就是这个,下载在这里。我们走吧。


我将使用上一篇文章中的安装,这意味着这是根安装。我的 Db2 实例的当前版本是 11.5.6.0:

1

2

3

4

5

<font style="vertical-align: inherit;"><font style="vertical-align: inherit;">db2inst1@sles15-db2-root </font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">:~> db2ls</font></font><font></font>

<font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

安装路径级别 Fix Pack 特殊安装号 安装日期 安装程序 UID</font></font><font></font>

---------------------------------------------------------------------------------------------------------------------<font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

/opt/ibm/db2/V11.5 11.5.6.0 0 2022 年 1 月 20 日星期四 12:05:28 CET 0</font></font><font></font>

下载最新包并将其放入根用户的主目录后,它看起来像这样:

1

2

3

4

5

6

7

8

9

10

11

12

13

<font style="vertical-align: inherit;"><font style="vertical-align: inherit;">db2 => 退出</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

DB20000I QUIT 命令成功完成。</font></font><font></font>

<font style="vertical-align: inherit;"><font style="vertical-align: inherit;">db2inst1@sles15-db2-root </font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">:~> su -</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

密码:</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

sles15-db2-root:~ $ ls -l</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

总计 1826112</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

-rw------- 1 root root 61 Jan 20 13:14 .Xauthority</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

-rw------- 1 root root 2376 Jan 20 15:25 .bash_history</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

drwx------ 1 根 0 2021 年 3 月 3 日 .gnupg</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

-rw------- 1 root root 1402 Jan 20 15:25 .viminfo</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

drwxr-xr-x 1 根 0 2021 年 3 月 3 日 bin</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

drwxr-xr-x 1 根 2021 年 7 月 9 日 36 日 inst-sys</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

-rw-r--r-- 1 root root 1869925829 Jan 21 09:42 v11.5.7_linuxx64_server_dec.tar.gz</font></font><font></font>

与初始安装没有太大区别,一旦解压,您将获得“server_dec”目录:

1

2

3

4

5

6

7

8

9

10

11

12

<font style="vertical-align: inherit;"><font style="vertical-align: inherit;">sles15-db2-root:~ $ tar axf v11.5.7_linuxx64_server_dec.tar.gz</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

sles15-db2-root:~ $ ls -l</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

总计 1826112</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

-rw------- 1 root root 61 Jan 20 13:14 .Xauthority</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

-rw------- 1 root root 2376 Jan 20 15:25 .bash_history</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

drwx------ 1 根 0 2021 年 3 月 3 日 .gnupg</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

-rw------- 1 root root 1402 Jan 20 15:25 .viminfo</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

drwxr-xr-x 1 根 0 2021 年 3 月 3 日 bin</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

drwxr-xr-x 1 根 2021 年 7 月 9 日 36 日 inst-sys</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

drwxr-xr-x 1 root root 240 Nov 22 19:36 server_dec</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

-rw-r--r-- 1 root root 1869925829 Jan 21 09:42 v11.5.7_linuxx64_server_dec.tar.gz</font></font><font></font><font style="vertical-align: inherit;"><font style="vertical-align: inherit;">

sles15-db2-root:~ $ rm v11.5.7_linuxx64_server_dec.tar.gz  </font></font><font></font>

在此目录中,您将“installFixPack”,这是一个普通的 shell 脚本:

1

2

3

4

5

6

7

8

9

10

11

12

13

sles15-db2-root:~ # cd server_dec/<font></font>

sles15-db2-root:~/server_dec # ls -l<font></font>

total 84<font></font>

drwxr-xr-x 1 bin bin   112 Nov 22 19:36 db2<font></font>

-r-xr-xr-x 1 bin bin  5207 Nov 22 19:36 db2_deinstall<font></font>

-r-xr-xr-x 1 bin bin  5077 Nov 22 19:36 db2_install<font></font>

-r--r--r-- 1 bin bin 16809 Nov 22 19:36 db2checkCOL.tar.gz<font></font>

-r--r--r-- 1 bin bin  4987 Nov 22 19:36 db2checkCOL_readme.txt<font></font>

-r-xr-xr-x 1 bin bin  5254 Nov 22 19:36 db2ckupgrade<font></font>

-r-xr-xr-x 1 bin bin  5041 Nov 22 19:36 db2ls<font></font>

-r-xr-xr-x 1 bin bin  5059 Nov 22 19:36 db2prereqcheck<font></font>

-r-xr-xr-x 1 bin bin  5059 Nov 22 19:36 db2setup<font></font>

-r-xr-xr-x 1 bin bin  5095 Nov 22 19:36 installFixPack<font></font>

您需要传递给该脚本的参数是当前安装位置和安装包的新目录。咱们试试吧:

1

2

3

4

5

6

7

8

9

10

11

12

sles15-db2-root:~/server_dec $ ./installFixPack -b /opt/ibm/db2/V11.5/ -p /opt/ibm/db2/fixpack/<font></font>

Requirement not matched for DB2 database "Server" . Version: "11.5.7.0". <font></font>

<font></font>

Summary of prerequisites that are not met on the current system: <font></font>

<font></font>

DBT3507E  The db2prereqcheck utility failed to find the following package or file: "mksh". <font></font>

<font></font>

<font></font>

DBT3619W  The db2prereqcheck utility detected that ksh is not linked to ksh or ksh93. This is required for Db2 High Availability Feature with Tivoli SA MP. <font></font>

<font></font>

  Aborting the current installation ...<font></font>

  Run installation with the option "-f sysreq" parameter to force the installation.<font></font>

好的,显然我们需要一个KornShell来安装它:

1

sles15-db2-root:~/server_dec $ zypper in -y mksh ksh

下次尝试:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

57

58

59

60

61

62

63

64

65

66

67

68

69

70

71

72

73

74

75

76

77

78

79

80

81

82

83

84

85

86

87

88

89

90

91

92

93

94

95

96

97

98

99

100

101

102

103

104

105

106

107

108

109

110

111

112

113

114

115

116

117

118

119

120

121

122

123

124

125

126

127

128

129

130

131

132

133

134

135

136

137

138

139

140

141

142

143

144

145

146

147

148

149

150

151

152

153

154

155

156

157

158

159

160

161

162

163

164

165

166

167

168

169

170

171

172

173

174

175

176

177

178

179

180

181

182

183

184

185

186

187

188

189

190

191

192

193

194

195

196

197

198

199

200

201

202

203

204

205

206

207

208

209

210

211

212

213

214

215

216

217

218

219

220

221

222

223

224

225

226

227

228

229

230

231

232

233

234

235

236

237

238

239

240

241

242

243

244

245

246

247

248

249

250

251

252

253

254

255

256

257

258

259

260

261

262

263

264

265

266

267

268

269

270

271

272

273

274

275

276

277

278

279

280

281

282

283

284

sles15-db2-root:~/server_dec $ ./installFixPack -b /opt/ibm/db2/V11.5/ -p /opt/ibm/db2/fixpack/<font></font>

Read the license agreement file in the db2/license directory.<font></font>

<font></font>

***********************************************************<font></font>

To accept those terms, enter "yes". Otherwise, enter "no" to cancel the install process. [yes/no]<font></font>

yes<font></font>

DBI1017I  installFixPack is updating the database products installed in<font></font>

      location /opt/ibm/db2/V11.5/.<font></font>

<font></font>

<font></font>

DB2 installation is being initialized.<font></font>

<font></font>

 Total number of tasks to be performed: 53 <font></font>

Total estimated time for all tasks to be performed: 2552 second(s) <font></font>

<font></font>

Task #1 start<font></font>

Description: Preparing the system <font></font>

Estimated time 120 second(s) <font></font>

Task #1 end <font></font>

<font></font>

Task #2 start<font></font>

Description: Base Client Support for installation with root privileges <font></font>

Estimated time 3 second(s) <font></font>

Task #2 end <font></font>

<font></font>

Task #3 start<font></font>

Description: Product Messages - English <font></font>

Estimated time 14 second(s) <font></font>

Task #3 end <font></font>

<font></font>

Task #4 start<font></font>

Description: Base client support <font></font>

Estimated time 360 second(s) <font></font>

Task #4 end <font></font>

<font></font>

Task #5 start<font></font>

Description: Java Runtime Support <font></font>

Estimated time 215 second(s) <font></font>

Task #5 end <font></font>

<font></font>

Task #6 start<font></font>

Description: Java Help (HTML) - English <font></font>

Estimated time 7 second(s) <font></font>

Task #6 end <font></font>

<font></font>

Task #7 start<font></font>

Description: Base server support for installation with root privileges <font></font>

Estimated time 6 second(s) <font></font>

Task #7 end <font></font>

<font></font>

Task #8 start<font></font>

Description: Global Secure ToolKit <font></font>

Estimated time 76 second(s) <font></font>

Task #8 end <font></font>

<font></font>

Task #9 start<font></font>

Description: Java support <font></font>

Estimated time 11 second(s) <font></font>

Task #9 end <font></font>

<font></font>

Task #10 start<font></font>

Description: SQL procedures <font></font>

Estimated time 3 second(s) <font></font>

Task #10 end <font></font>

<font></font>

Task #11 start<font></font>

Description: ICU Utilities <font></font>

Estimated time 59 second(s) <font></font>

Task #11 end <font></font>

<font></font>

Task #12 start<font></font>

Description: Java Common files <font></font>

Estimated time 18 second(s) <font></font>

Task #12 end <font></font>

<font></font>

Task #13 start<font></font>

Description: Base server support <font></font>

Estimated time 610 second(s) <font></font>

Task #13 end <font></font>

<font></font>

Task #14 start<font></font>

Description: Control Center Help (HTML) - English <font></font>

Estimated time 13 second(s) <font></font>

Task #14 end <font></font>

<font></font>

Task #15 start<font></font>

Description: Relational wrappers common <font></font>

Estimated time 3 second(s) <font></font>

Task #15 end <font></font>

<font></font>

Task #16 start<font></font>

Description: DB2 data source support <font></font>

Estimated time 6 second(s) <font></font>

Task #16 end <font></font>

<font></font>

Task #17 start<font></font>

Description: ODBC data source support <font></font>

Estimated time 260 second(s) <font></font>

Task #17 end <font></font>

<font></font>

Task #18 start<font></font>

Description: Teradata data source support <font></font>

Estimated time 3 second(s) <font></font>

Task #18 end <font></font>

<font></font>

Task #19 start<font></font>

Description: Spatial Extender server support <font></font>

Estimated time 21 second(s) <font></font>

Task #19 end <font></font>

<font></font>

Task #20 start<font></font>

Description: Scientific Data Sources <font></font>

Estimated time 5 second(s) <font></font>

Task #20 end <font></font>

<font></font>

Task #21 start<font></font>

Description: JDBC data source support <font></font>

Estimated time 185 second(s) <font></font>

Task #21 end <font></font>

<font></font>

Task #22 start<font></font>

Description: IBM Software Development Kit (SDK) for Java(TM) <font></font>

Estimated time 49 second(s) <font></font>

Task #22 end <font></font>

<font></font>

Task #23 start<font></font>

Description: DB2 LDAP support <font></font>

Estimated time 4 second(s) <font></font>

Task #23 end <font></font>

<font></font>

Task #24 start<font></font>

Description: DB2 Instance Setup wizard <font></font>

Estimated time 23 second(s) <font></font>

Task #24 end <font></font>

<font></font>

Task #25 start<font></font>

Description: Structured file data sources <font></font>

Estimated time 5 second(s) <font></font>

Task #25 end <font></font>

<font></font>

Task #26 start<font></font>

Description: Integrated Flash Copy Support <font></font>

Estimated time 3 second(s) <font></font>

Task #26 end <font></font>

<font></font>

Task #27 start<font></font>

Description: Oracle data source support <font></font>

Estimated time 4 second(s) <font></font>

Task #27 end <font></font>

<font></font>

Task #28 start<font></font>

Description: Connect support <font></font>

Estimated time 3 second(s) <font></font>

Task #28 end <font></font>

<font></font>

Task #29 start<font></font>

Description: Application data sources <font></font>

Estimated time 4 second(s) <font></font>

Task #29 end <font></font>

<font></font>

Task #30 start<font></font>

Description: Spatial Extender client <font></font>

Estimated time 3 second(s) <font></font>

Task #30 end <font></font>

<font></font>

Task #31 start<font></font>

Description: SQL Server data source support <font></font>

Estimated time 4 second(s) <font></font>

Task #31 end <font></font>

<font></font>

Task #32 start<font></font>

Description: Communication support - TCP/IP <font></font>

Estimated time 3 second(s) <font></font>

Task #32 end <font></font>

<font></font>

Task #33 start<font></font>

Description: Base application development tools <font></font>

Estimated time 36 second(s) <font></font>

Task #33 end <font></font>

<font></font>

Task #34 start<font></font>

Description: Parallel Extension <font></font>

Estimated time 3 second(s) <font></font>

Task #34 end <font></font>

<font></font>

Task #35 start<font></font>

Description: EnterpriseDB code <font></font>

Estimated time 3 second(s) <font></font>

Task #35 end <font></font>

<font></font>

Task #36 start<font></font>

Description: Replication tools <font></font>

Estimated time 60 second(s) <font></font>

Task #36 end <font></font>

<font></font>

Task #37 start<font></font>

Description: Sample database source <font></font>

Estimated time 4 second(s) <font></font>

Task #37 end <font></font>

<font></font>

Task #38 start<font></font>

Description: itlm <font></font>

Estimated time 3 second(s) <font></font>

Task #38 end <font></font>

<font></font>

Task #39 start<font></font>

Description: DB2 Text Search <font></font>

Estimated time 108 second(s) <font></font>

Task #39 end <font></font>

<font></font>

Task #40 start<font></font>

Description: Command Line Processor Plus <font></font>

Estimated time 8 second(s) <font></font>

Task #40 end <font></font>

<font></font>

Task #41 start<font></font>

Description: Sybase data source support <font></font>

Estimated time 3 second(s) <font></font>

Task #41 end <font></font>

<font></font>

Task #42 start<font></font>

Description: Informix data source support <font></font>

Estimated time 4 second(s) <font></font>

Task #42 end <font></font>

<font></font>

Task #43 start<font></font>

Description: Federated Data Access Support <font></font>

Estimated time 3 second(s) <font></font>

Task #43 end <font></font>

<font></font>

Task #44 start<font></font>

Description: First Steps <font></font>

Estimated time 3 second(s) <font></font>

Task #44 end <font></font>

<font></font>

Task #45 start<font></font>

Description: Pacemaker <font></font>

Estimated time 100 second(s) <font></font>

Task #45 end <font></font>

<font></font>

Task #46 start<font></font>

Description: Product Signature for DB2 Server Edition <font></font>

Estimated time 6 second(s) <font></font>

Task #46 end <font></font>

<font></font>

Task #47 start<font></font>

Description: Guardium Installation Manager Client <font></font>

Estimated time 36 second(s) <font></font>

Task #47 end <font></font>

<font></font>

Task #48 start<font></font>

Description: Setting DB2 library path <font></font>

Estimated time 180 second(s) <font></font>

Task #48 end <font></font>

<font></font>

Task #49 start<font></font>

Description: Installing or updating Db2 resource agent scripts for Pacemaker <font></font>

Estimated time 20 second(s) <font></font>

Task #49 end <font></font>

<font></font>

Task #50 start<font></font>

Description: Executing control tasks <font></font>

Estimated time 20 second(s) <font></font>

Task #50 end <font></font>

<font></font>

Task #51 start<font></font>

Description: Updating global registry <font></font>

Estimated time 20 second(s) <font></font>

Task #51 end <font></font>

<font></font>

Task #52 start<font></font>

Description: Updating the db2ls and db2greg link <font></font>

Estimated time 1 second(s) <font></font>

Task #52 end <font></font>

<font></font>

Task #53 start<font></font>

Description: Registering DB2 licenses <font></font>

Estimated time 5 second(s) <font></font>

Task #53 end <font></font>

<font></font>

The execution completed successfully.<font></font>

<font></font>

For more information see the DB2 installation log at<font></font>

"/tmp/installFixPack.log.4317".<font></font>

与初始安装非常相似的输出/步骤。一切看起来都很好。这是所有文件的安装:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

sles15-db2-root:~/server_dec $ cd /opt/ibm/db2/fixpack/<font></font>

sles15-db2-root:/opt/ibm/db2/fixpack $ ls -l<font></font>

total 4<font></font>

drwx--x--x 1 root root    30 Jan 21 09:53 .licbkup<font></font>

drwxr-xr-x 1 root root  1696 Nov 22 19:31 .metadata<font></font>

drwxr-xr-x 1 bin  bin      6 Nov 22 19:28 R<font></font>

drwxr-xr-x 1 bin  bin    296 Nov 22 19:27 Readme<font></font>

drwxr-xr-x 1 bin  bin     18 Nov 22 19:27 acs<font></font>

drwxr-xr-x 1 bin  bin    734 Nov 22 19:29 adm<font></font>

drwxr-xr-x 1 bin  bin     76 Nov 22 19:28 adsm<font></font>

drwxr-xr-x 1 bin  bin   4368 Nov 22 19:28 bin<font></font>

drwxr-xr-x 1 bin  bin   5024 Nov 22 19:28 bnd<font></font>

drwxr-xr-x 1 bin  bin   1090 Jan 21 09:53 cfg<font></font>

drwxr-xr-x 1 bin  bin     10 Nov 22 19:27 conv<font></font>

drwxr-xr-x 1 bin  bin     92 Nov 22 19:28 das<font></font>

drwxr-xr-x 1 bin  bin    156 Nov 22 19:28 dasfcn<font></font>

drwxr-xr-x 1 bin  bin     48 Nov 22 19:29 db2tss<font></font>

drwxr-xr-x 1 bin  bin     84 Nov 22 19:28 desktop<font></font>

drwxr-xr-x 1 bin  bin     12 Nov 22 19:28 doc<font></font>

drwxr-xr-x 1 bin  bin     52 Nov 22 19:28 federation<font></font>

drwxr-xr-x 1 bin  bin    100 Nov 22 19:28 function<font></font>

drwxr-xr-x 1 bin  bin     24 Nov 22 19:28 gse<font></font>

drwxr-xr-x 1 bin  bin     64 Nov 22 19:28 gskit<font></font>

drwxr-xr-x 1 bin  bin    548 Nov 22 19:28 guardium<font></font>

drwxr-xr-x 1 bin  bin     34 Nov 22 19:28 ha<font></font>

drwxr-xr-x 1 bin  bin   2786 Nov 22 19:27 include<font></font>

drwxr-xr-x 1 bin  bin     54 Nov 22 19:29 infopop<font></font>

drwxr-xr-x 1 bin  bin    156 Jan 21 09:53 install<font></font>

drwxr-xr-x 1 bin  bin    722 Nov 22 19:28 instance<font></font>

drwxr-xr-x 1 bin  bin    352 Nov 22 19:27 java<font></font>

drwxr-xr-x 1 bin  bin     38 Nov 22 19:27 json<font></font>

drwxr-xr-x 1 bin  bin   1564 Jan 21 09:52 lib32<font></font>

drwxr-xr-x 1 bin  bin  10328 Jan 21 09:52 lib64<font></font>

drwxr-xr-x 1 bin  bin    932 Jan 21 09:53 license<font></font>

lrwxrwxrwx 1 root root    12 Nov 22 19:27 logs -> install/logs<font></font>

drwxr-xr-x 1 bin  bin     66 Nov 22 19:28 map<font></font>

drwxr-xr-x 1 bin  bin    746 Nov 22 19:28 misc<font></font>

drwxr-xr-x 1 bin  bin     28 Nov 22 19:28 msg<font></font>

drwxr-xr-x 1 bin  bin    246 Nov 22 19:28 pd<font></font>

drwxr-xr-x 1 bin  bin     14 Nov 22 19:28 properties<font></font>

drwxr-xr-x 1 bin  bin     30 Nov 22 19:28 python<font></font>

drwxr-xr-x 1 bin  bin    368 Nov 22 19:28 samples<font></font>

drwxr-xr-x 1 bin  bin     12 Nov 22 19:28 security32<font></font>

drwxr-xr-x 1 bin  bin    108 Nov 22 19:28 security64<font></font>

drwxr-xr-x 1 bin  bin   1796 Nov 22 19:28 tools<font></font>

现在我们需要修补实例,这是使用位于“instance”目录中的db2iupdt完成的:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

sles15-db2-root:/opt/ibm/db2/fixpack/instance $ ./db2iupdt -d db2inst1<font></font>

DBI1446I  The db2iupdt command is running.<font></font>

<font></font>

<font></font>

DB2 installation is being initialized.<font></font>

<font></font>

 The DB2 installer detects that one or more DB2 instances "db2inst1" are still<font></font>

active. Stop the active instances and rerun the command again.<font></font>

<font></font>

A major error occurred during the execution that caused this program to<font></font>

terminate prematurely. If the problem persists, contact your technical service<font></font>

representative.<font></font>

<font></font>

For more information see the DB2 installation log at "/tmp/db2iupdt.log.13332".<font></font>

DBI1264E  This program failed. Errors encountered during execution were<font></font>

      written to the installation log file. Program name:<font></font>

      db2iupdt. Log file name: /tmp/db2iupdt.log.13332.<font></font>

<font></font>

Explanation: <font></font>

<font></font>

This message is returned when some processes and operations have failed.<font></font>

Detailed information about the error was written to the log file.<font></font>

<font></font>

User response: <font></font>

<font></font>

Contact IBM support to get assistance in resolving this issue. Keep the<font></font>

log file intact as this file is an important reference for IBM support.<font></font>

<font></font>

<font></font>

   Related information:<font></font>

   Contacting IBM Software Support<font></font>

如果您可以在之前不关闭实例的情况下更新实例,我会感到惊讶,因此这是意料之中的:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

db2inst1@sles15-db2-root:~> db2stop<font></font>

01/21/2022 09:57:39     0   0   SQL1064N  DB2STOP processing was successful.<font></font>

SQL1064N  DB2STOP processing was successful.<font></font>

db2inst1@sles15-db2-root:~> ps -ef | grep db2<font></font>

root      1051  1049  0 09:41 ?        00:00:00 sshd: db2inst1 [priv]<font></font>

db2inst1  1055     1  0 09:41 ?        00:00:00 /usr/lib/systemd/systemd --user<font></font>

db2inst1  1056  1055  0 09:41 ?        00:00:00 (sd-pam)<font></font>

db2inst1  1063  1051  0 09:41 ?        00:00:00 sshd: db2inst1@pts/0<font></font>

db2inst1  1064  1063  0 09:41 pts/0    00:00:00 -bash<font></font>

db2inst1  1476     1  0 09:41 pts/0    00:00:00 /home/db2inst1/sqllib/bin/db2bp 1064A1004 5 A<font></font>

root     14155     1  0 09:56 ?        00:00:00 /opt/ibm/db2/V11.5/bin/db2fmcd<font></font>

db2inst1 14180 28023  0 09:57 pts/1    00:00:00 ps -ef<font></font>

db2inst1 14181 28023  0 09:57 pts/1    00:00:00 grep --color=auto db2<font></font>

root     27014  1049  0 09:52 ?        00:00:00 sshd: db2inst1 [priv]<font></font>

db2inst1 27995 27014  0 09:52 ?        00:00:00 sshd: db2inst1@pts/1<font></font>

db2inst1 28023 27995  0 09:52 pts/1    00:00:00 -bash<font></font>

下次尝试:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

sles15-db2-root:/opt/ibm/db2/fixpack/instance $ ./db2iupdt -d db2inst1<font></font>

DBI1446I  The db2iupdt command is running.<font></font>

<font></font>

<font></font>

DB2 installation is being initialized.<font></font>

<font></font>

 Total number of tasks to be performed: 4 <font></font>

Total estimated time for all tasks to be performed: 309 second(s) <font></font>

<font></font>

Task #1 start<font></font>

Description: Setting default global profile registry variables <font></font>

Estimated time 1 second(s) <font></font>

Task #1 end <font></font>

<font></font>

Task #2 start<font></font>

Description: Initializing instance list <font></font>

Estimated time 5 second(s) <font></font>

Task #2 end <font></font>

<font></font>

Task #3 start<font></font>

Description: Configuring DB2 instances <font></font>

Estimated time 300 second(s) <font></font>

Task #3 end <font></font>

<font></font>

Task #4 start<font></font>

Description: Updating global profile registry <font></font>

Estimated time 3 second(s) <font></font>

Task #4 end <font></font>

<font></font>

The execution completed successfully.<font></font>

<font></font>

For more information see the DB2 installation log at "/tmp/db2iupdt.log.14194".<font></font>

DBI1070I  Program db2iupdt completed successfully.<font></font>

一切似乎都很好,所以让我们启动它并检查版本:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

db2inst1@sles15-db2-root:~> db2start<font></font>

01/21/2022 09:58:44     0   0   SQL1063N  DB2START processing was successful.<font></font>

SQL1063N  DB2START processing was successful.<font></font>

db2inst1@sles15-db2-root:~> db2ls<font></font>

<font></font>

Install Path                       Level   Fix Pack   Special Install Number   Install Date                  Installer UID <font></font>

---------------------------------------------------------------------------------------------------------------------<font></font>

/opt/ibm/db2/V11.5               11.5.6.0        0                            Thu Jan 20 12:05:28 2022 CET             0 <font></font>

/opt/ibm/db2/fixpack             11.5.7.0        0                            Fri Jan 21 09:53:04 2022 CET             0 <font></font>

<font></font>

<font></font>

<font></font>

db2inst1@sles15-db2-root:~> db2<font></font>

(c) Copyright IBM Corporation 1993,2007<font></font>

Command Line Processor for DB2 Client 11.5.7.0<font></font>

<font></font>

You can issue database manager commands and SQL statements from the command <font></font>

prompt. For example:<font></font>

    db2 => connect to sample<font></font>

    db2 => bind sample.bnd<font></font>

<font></font>

For general help, type: ?.<font></font>

For command help, type: ? command, where command can be<font></font>

the first few keywords of a database manager command. For example:<font></font>

 ? CATALOG DATABASE for help on the CATALOG DATABASE command<font></font>

 ? CATALOG          for help on all of the CATALOG commands.<font></font>

<font></font>

To exit db2 interactive mode, type QUIT at the command prompt. Outside <font></font>

interactive mode, all commands must be prefixed with 'db2'.<font></font>

To list the current command option settings, type LIST COMMAND OPTIONS.<font></font>

<font></font>

For more detailed help, refer to the Online Reference Manual.<font></font>

看起来挺好的。最后,您应该更新数据库中的目录:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

db2inst1@sles15-db2-root:~> db2updv115 -d db1<font></font>

<font></font>

<font></font>

_________________________________________________________________________     <font></font>

                                                                              <font></font>

                    _____   DB2 Service Tools   _____                         <font></font>

                                                                              <font></font>

                            I      B      M                                   <font></font>

                                                                              <font></font>

                               db2updv115                                      <font></font>

                                                                              <font></font>

   This tool is a service utility designed to update a DB2 Version 11.5       <font></font>

   database to the current fix pack level.                                    <font></font>

                                                                              <font></font>

_________________________________________________________________________     <font></font>

<font></font>

<font></font>

DB2 Universal Database Version 11.5, 5622-044 (c) Copyright IBM Corp. 2019<font></font>

Licensed Material - Program Property of IBM<font></font>

IBM DATABASE 2 Database update to current fix pack tool<font></font>

<font></font>

db2updv115 completed successfully for database 'db1'. <font></font>

回顾 db2ls 的输出,我想知道为什么我有两行:

1

2

3

4

5

6

db2inst1@sles15-db2-root:~> db2ls<font></font>

<font></font>

Install Path                       Level   Fix Pack   Special Install Number   Install Date                  Installer UID <font></font>

---------------------------------------------------------------------------------------------------------------------<font></font>

/opt/ibm/db2/V11.5               11.5.6.0        0                            Thu Jan 20 12:05:28 2022 CET             0 <font></font>

/opt/ibm/db2/fixpack             11.5.7.0        0                            Fri Jan 21 09:53:04 2022 CET             0 <font></font>

检查其中一个进程的打开文件会给出:

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49

50

51

52

53

54

55

56

57

58

59

60

61

62

63

64

65

66

67

68

69

70

71

72

73

74

75

76

77

78

79

80

81

82

83

84

85

86

87

88

89

90

91

sles15-db2-root:~/server_dec $ ps -ef | grep db2 | grep db2ckpwd<font></font>

root      2809 32564  0 10:58 pts/0    00:00:00 grep --color=auto db2ckpwd<font></font>

root     30065 30057  0 09:58 pts/1    00:00:00 db2ckpwd 0<font></font>

root     30066 30057  0 09:58 pts/1    00:00:00 db2ckpwd 0<font></font>

root     30067 30057  0 09:58 pts/1    00:00:00 db2ckpwd 0<font></font>

sles15-db2-root:~/server_dec $ lsof -p 30065<font></font>

COMMAND    PID USER   FD   TYPE DEVICE  SIZE/OFF     NODE NAME<font></font>

db2syscr 30065 root  cwd    DIR   0,46       156      256 /<font></font>

db2syscr 30065 root  rtd    DIR   0,46       156      256 /<font></font>

db2syscr 30065 root  txt    REG  253,3    197000 12583070 /home/db2inst1/sqllib/adm/db2syscr<font></font>

db2syscr 30065 root  DEL    REG    0,1                  7 /SYSV276cac61<font></font>

db2syscr 30065 root  DEL    REG    0,1                  8 /SYSV00000000<font></font>

db2syscr 30065 root  DEL    REG    0,1                  6 /SYSV276cac74<font></font>

db2syscr 30065 root  mem    REG   0,46    340640    45411 /usr/lib/locale/en_US.utf8/LC_CTYPE<font></font>

db2syscr 30065 root  mem    REG   0,46        54    45152 /usr/lib/locale/en_US.utf8/LC_NUMERIC<font></font>

db2syscr 30065 root  mem    REG   0,46   2586930    45146 /usr/lib/locale/en_US.utf8/LC_COLLATE<font></font>

db2syscr 30065 root  mem    REG   0,46     41240    40191 /lib64/libnss_compat-2.31.so<font></font>

db2syscr 30065 root  mem    REG   0,46    235576     1702 /usr/lib64/liblzma.so.5.2.3<font></font>

db2syscr 30065 root  mem    REG   0,46     92216    40244 /lib64/libz.so.1.2.11<font></font>

db2syscr 30065 root  mem    REG   0,46    112624     1859 /usr/lib64/libaudit.so.1.0.0<font></font>

db2syscr 30065 root  mem    REG   0,56   1932400    10339 /opt/ibm/db2/fixpack/lib64/libicuucdb2.so.55.1<font></font>

db2syscr 30065 root  mem    REG   0,56   1629408    10336 /opt/ibm/db2/fixpack/lib64/libicuucdb2.so.44.2<font></font>

db2syscr 30065 root  mem    REG   0,56   1542960    10337 /opt/ibm/db2/fixpack/lib64/libicuucdb2.so.38.1<font></font>

db2syscr 30065 root  mem    REG   0,56   1232064     8885 /opt/ibm/db2/fixpack/lib64/libicuucdb2.so.32.1<font></font>

db2syscr 30065 root  mem    REG   0,56     72528    10320 /opt/ibm/db2/fixpack/lib64/libiculxdb2.so.55.1<font></font>

db2syscr 30065 root  mem    REG   0,56     73632    10341 /opt/ibm/db2/fixpack/lib64/libiculxdb2.so.44.2<font></font>

db2syscr 30065 root  mem    REG   0,56     72096    10342 /opt/ibm/db2/fixpack/lib64/libiculxdb2.so.38.1<font></font>

db2syscr 30065 root  mem    REG   0,56     55680     8830 /opt/ibm/db2/fixpack/lib64/libiculxdb2.so.32.1<font></font>

db2syscr 30065 root  mem    REG   0,56    462224    10316 /opt/ibm/db2/fixpack/lib64/libiculedb2.so.55.1<font></font>

db2syscr 30065 root  mem    REG   0,56    315536    10335 /opt/ibm/db2/fixpack/lib64/libiculedb2.so.44.2<font></font>

db2syscr 30065 root  mem    REG   0,56    296344    10311 /opt/ibm/db2/fixpack/lib64/libiculedb2.so.38.1<font></font>

db2syscr 30065 root  mem    REG   0,56    312096     8889 /opt/ibm/db2/fixpack/lib64/libiculedb2.so.32.1<font></font>

db2syscr 30065 root  mem    REG   0,56     71192    10338 /opt/ibm/db2/fixpack/lib64/libicuiodb2.so.55.1<font></font>

db2syscr 30065 root  mem    REG   0,56     65936    10328 /opt/ibm/db2/fixpack/lib64/libicuiodb2.so.44.2<font></font>

db2syscr 30065 root  mem    REG   0,56     65576    10331 /opt/ibm/db2/fixpack/lib64/libicuiodb2.so.38.1<font></font>

db2syscr 30065 root  mem    REG   0,56     65600     8903 /opt/ibm/db2/fixpack/lib64/libicuiodb2.so.32.1<font></font>

db2syscr 30065 root  mem    REG   0,56   3148400    10321 /opt/ibm/db2/fixpack/lib64/libicui18ndb2.so.55.1<font></font>

db2syscr 30065 root  mem    REG   0,56   2354488    10310 /opt/ibm/db2/fixpack/lib64/libicui18ndb2.so.44.2<font></font>

db2syscr 30065 root  mem    REG   0,56   1648208    10322 /opt/ibm/db2/fixpack/lib64/libicui18ndb2.so.38.1<font></font>

db2syscr 30065 root  mem    REG   0,56   1507104     8900 /opt/ibm/db2/fixpack/lib64/libicui18ndb2.so.32.1<font></font>

db2syscr 30065 root  mem    REG   0,56  20194496    10334 /opt/ibm/db2/fixpack/lib64/libicudatadb2.so.55.1<font></font>

db2syscr 30065 root  mem    REG   0,56  11048128    10317 /opt/ibm/db2/fixpack/lib64/libicudatadb2.so.44.2<font></font>

db2syscr 30065 root  mem    REG   0,56   6980792    10325 /opt/ibm/db2/fixpack/lib64/libicudatadb2.so.38.1<font></font>

db2syscr 30065 root  mem    REG   0,56   9780656     8866 /opt/ibm/db2/fixpack/lib64/libicudatadb2.so.32.1<font></font>

db2syscr 30065 root  mem    REG   0,56    612696     8875 /opt/ibm/db2/fixpack/lib64/libdb2sdbin.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56    156632     8878 /opt/ibm/db2/fixpack/lib64/libdb2locale.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56    228488     8854 /opt/ibm/db2/fixpack/lib64/libdb2genreg.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56    657544    10852 /opt/ibm/db2/fixpack/lib64/libdb2dstf.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56   5850192     8890 /opt/ibm/db2/fixpack/lib64/libDB2xslt4c.so.112.0<font></font>

db2syscr 30065 root  mem    REG   0,56    536376     8919 /opt/ibm/db2/fixpack/lib64/libDB2xml4c-depdom.so.58.0<font></font>

db2syscr 30065 root  mem    REG   0,56   4259416     8868 /opt/ibm/db2/fixpack/lib64/libDB2xml4c.so.58.0<font></font>

db2syscr 30065 root  mem    REG   0,56     46920     8837 /opt/ibm/db2/fixpack/lib64/libDB2xalanMsg.so.112.0<font></font>

db2syscr 30065 root  mem    REG   0,46     48288    62219 /usr/lib64/libnuma.so.1.0.0<font></font>

db2syscr 30065 root  mem    REG   0,46   1473368     2648 /usr/lib64/libxml2.so.2.9.7<font></font>

db2syscr 30065 root  mem    REG   0,46     64232    45768 /lib64/libpam.so.0.84.2<font></font>

db2syscr 30065 root  mem    REG   0,46     40240    40205 /lib64/librt-2.31.so<font></font>

db2syscr 30065 root  mem    REG   0,46     17840    40183 /lib64/libdl-2.31.so<font></font>

db2syscr 30065 root  mem    REG   0,46    202736     1810 /usr/lib64/libcrypt.so.1.1.0<font></font>

db2syscr 30065 root  mem    REG   0,46      5608     1874 /lib64/libaio.so.1.0.1<font></font>

db2syscr 30065 root  mem    REG   0,56   8316600     8839 /opt/ibm/db2/fixpack/lib64/libdb2g11n.so.1<font></font>

db2syscr 30065 root  mem    REG   0,46   2163888    40181 /lib64/libc-2.31.so<font></font>

db2syscr 30065 root  mem    REG   0,46    101024    40311 /lib64/libgcc_s.so.1<font></font>

db2syscr 30065 root  mem    REG   0,46   1419880    40185 /lib64/libm-2.31.so<font></font>

db2syscr 30065 root  mem    REG   0,46   2161776    40439 /usr/lib64/libstdc++.so.6.0.29<font></font>

db2syscr 30065 root  mem    REG   0,56   6207992     8842 /opt/ibm/db2/fixpack/lib64/libdb2osse.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56 302123664    10859 /opt/ibm/db2/fixpack/lib64/libdb2e.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56   4327000    10870 /opt/ibm/db2/fixpack/lib64/libdb2thrift.so.1<font></font>

db2syscr 30065 root  mem    REG   0,46    147304    40201 /lib64/libpthread-2.31.so<font></font>

db2syscr 30065 root  mem    REG   0,46    192696    40173 /lib64/ld-2.31.so<font></font>

db2syscr 30065 root  mem    REG   0,46      3284    45155 /usr/lib/locale/en_US.utf8/LC_TIME<font></font>

db2syscr 30065 root  mem    REG   0,46       286    45150 /usr/lib/locale/en_US.utf8/LC_MONETARY<font></font>

db2syscr 30065 root  mem    REG   0,46        57    45149 /usr/lib/locale/en_US.utf8/LC_MESSAGES/SYS_LC_MESSAGES<font></font>

db2syscr 30065 root  mem    REG   0,46        34    45153 /usr/lib/locale/en_US.utf8/LC_PAPER<font></font>

db2syscr 30065 root  mem    REG   0,46        77    45151 /usr/lib/locale/en_US.utf8/LC_NAME<font></font>

db2syscr 30065 root  mem    REG   0,56     22360     8899 /opt/ibm/db2/fixpack/lib64/libdb2install.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56     16976    10919 /opt/ibm/db2/fixpack/lib64/libdb2encr.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56    125184     8887 /opt/ibm/db2/fixpack/lib64/libdb2dascmn.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56     17080    10900 /opt/ibm/db2/fixpack/lib64/libdb2compr_encr.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56     20504    10868 /opt/ibm/db2/fixpack/lib64/libdb2compr.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56    485200     8844 /opt/ibm/db2/fixpack/lib64/libdb2cftrace.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56    532336     8881 /opt/ibm/db2/fixpack/lib64/libdb2cf_api.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56     70488     8857 /opt/ibm/db2/fixpack/lib64/libdb2trcapi.so.1<font></font>

db2syscr 30065 root  mem    REG   0,56    576944     8880 /opt/ibm/db2/fixpack/lib64/libdb2osse_db2.so.1<font></font>

db2syscr 30065 root  mem    REG   0,46       167    45145 /usr/lib/locale/en_US.utf8/LC_ADDRESS<font></font>

db2syscr 30065 root  mem    REG   0,46        59    45154 /usr/lib/locale/en_US.utf8/LC_TELEPHONE<font></font>

db2syscr 30065 root  mem    REG   0,46        23    45148 /usr/lib/locale/en_US.utf8/LC_MEASUREMENT<font></font>

db2syscr 30065 root  mem    REG   0,46     26988    45412 /usr/lib64/gconv/gconv-modules.cache<font></font>

db2syscr 30065 root  mem    REG   0,46       369    45147 /usr/lib/locale/en_US.utf8/LC_IDENTIFICATION<font></font>

db2syscr 30065 root    0u   CHR    1,3       0t0     9522 /dev/null<font></font>

db2syscr 30065 root    1u   CHR    1,3       0t0     9522 /dev/null<font></font>

db2syscr 30065 root    2u   CHR    1,3       0t0     9522 /dev/null<font></font>

这确认使用了 Fix Pack 新位置的文件,而不是初始安装的文件。我可能应该为目录选择一个更好的命名,因为“fixpack”在这里确实不是一个好的选择。

「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论