首页 > 数据库 >Oracle单机环境打补丁(Oracle 19.3.0.0打RU补丁)

Oracle单机环境打补丁(Oracle 19.3.0.0打RU补丁)

时间:2024-09-17 22:23:57浏览次数:15  
标签:RU oracle19c 19.0 dbhome 0.0 OPatch oracle 打补丁 Oracle

1. 查看当前数据库版本信息
	[oracle@oracle19c ~]$ cd $ORACLE_HOME
	[oracle@oracle19c dbhome_1]$ ./OPatch/opatch lspatches
	29585399;OCW RELEASE UPDATE 19.3.0.0.0 (29585399)
	29517242;Database Release Update : 19.3.0.0.190416 (29517242)
2. 替换Opatch
	[root@oracle19c patch]# cd /opt/sws/
	[root@oracle19c sws]# ll
	total 1850188
	-rwxr-x--- 1 root root 1769419773 Sep  9 19:07 p35320081_190000_Linux-x86-64.zip
	-rwxr-x--- 1 root root  125167420 Sep  9 19:07 p6880880_190000_Linux-x86-64.zip
	[root@oracle19c sws]# chown oracle.oinstall p*

	[oracle@oracle19c dbhome_1]$ mv OPatch OPatch.bak 

	[oracle@oracle19c dbhome_1]$ unzip /opt/sws/p6880880_190000_Linux-x86-64.zip 
	[oracle@oracle19c dbhome_1]$ ls |grep OPatch
	OPatch
	OPatch.bak

	[oracle@oracle19c dbhome_1]$ ./OPatch/opatch version
	OPatch Version: 12.2.0.1.39
	OPatch succeeded.

3. 关闭数据库监听和实例
	[oracle@oracle19c dbhome_1]$ lsnrctl stop
	SQL>shudown immediate;

	#如果不关闭实例会报如下的错误
	[oracle@oracle19c 35320081]$ $ORACLE_HOME/OPatch/opatch apply                                          
	Oracle Interim Patch Installer version 12.2.0.1.39
	Copyright (c) 2024, Oracle Corporation.  All rights reserved.
	Oracle Home       : /opt/oracle/product/19c/dbhome_1
	Central Inventory : /opt/oracle/oraInventory
	   from           : /opt/oracle/product/19c/dbhome_1/oraInst.loc
	OPatch version    : 12.2.0.1.39
	OUI version       : 12.2.0.7.0
	Log file location : /opt/oracle/product/19c/dbhome_1/cfgtoollogs/opatch/opatch2024-09-09_19-21-33PM_1.log
	Verifying environment and performing prerequisite checks...
	Prerequisite check "CheckActiveFilesAndExecutables" failed.
	The details are:
	Following active files/executables/libs are used by ORACLE_HOME :/opt/oracle/product/19c/dbhome_1
	/opt/oracle/product/19c/dbhome_1/bin/oracle

	UtilSession failed: Prerequisite check "CheckActiveFilesAndExecutables" failed.
	Log file location: /opt/oracle/product/19c/dbhome_1/cfgtoollogs/opatch/opatch2024-09-09_19-21-33PM_1.log

	OPatch failed with error code 73

4. 打补丁
	[root@oracle19c sws]# cd /opt/sws/
	[root@oracle19c sws]# unzip p35320081_190000_Linux-x86-64.zip
	[root@oracle19c sws]# chown -R oracle.oinstall 35320081
	[root@oracle19c sws]# su - oracle 
	[oracle@oracle19c ~]$ cd /opt/sws/35320081/

	[oracle@oracle19c 35320081]$ $ORACLE_HOME/OPatch/opatch prereq CheckSystemSpace -ph ./ 
	[oracle@oracle19c 35320081]$ $ORACLE_HOME/OPatch/opatch prereq CheckConflictAgainstOHWithDetail  -ph ./
	[oracle@oracle19c 35320081]$ $ORACLE_HOME/OPatch/opatch apply
	Oracle Interim Patch Installer version 12.2.0.1.39
	Copyright (c) 2024, Oracle Corporation.  All rights reserved.
	Oracle Home       : /opt/oracle/product/19c/dbhome_1
	Central Inventory : /opt/oracle/oraInventory
	   from           : /opt/oracle/product/19c/dbhome_1/oraInst.loc
	OPatch version    : 12.2.0.1.39
	OUI version       : 12.2.0.7.0
	Log file location : /opt/oracle/product/19c/dbhome_1/cfgtoollogs/opatch/opatch2024-09-09_19-25-53PM_1.log
	Verifying environment and performing prerequisite checks...
	OPatch continues with these patches:   35320081  
	Do you want to proceed? [y|n]
	y
	User Responded with: Y
	All checks passed.

	Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
	(Oracle Home = '/opt/oracle/product/19c/dbhome_1')
	Is the local system ready for patching? [y|n]
	y
	User Responded with: Y
	Backing up files...
	Applying interim patch '35320081' to OH '/opt/oracle/product/19c/dbhome_1'
	ApplySession: Optional component(s) [ oracle.network.gsm, 19.0.0.0.0 ] , [ oracle.rdbms.ic, 19.0.0.0.0 ] , [ oracle.rdbms.tg4db2, 19.0.0.0.0 ] , [ oracle.tfa, 19.0.0.0.0 ] , [ oracle.rdbms.tg4msql, 19.0.0.0.0 ] , [ oracle.options.olap, 19.0.0.0.0 ] , [ oracle.ons.cclient, 19.0.0.0.0 ] , [ oracle.network.cman, 19.0.0.0.0 ] , [ oracle.rdbms.tg4ifmx, 19.0.0.0.0 ] , [ oracle.rdbms.tg4sybs, 19.0.0.0.0 ] , [ oracle.net.cman, 19.0.0.0.0 ] , [ oracle.rdbms.tg4tera, 19.0.0.0.0 ] , [ oracle.sdo.companion, 19.0.0.0.0 ] , [ oracle.oid.client, 19.0.0.0.0 ] , [ oracle.xdk.companion, 19.0.0.0.0 ] , [ oracle.ons.eons.bwcompat, 19.0.0.0.0 ] , [ oracle.options.olap.api, 19.0.0.0.0 ] , [ oracle.jdk, 1.8.0.191.0 ]  not present in the Oracle Home or a higher version is found.
	Patching component oracle.rdbms, 19.0.0.0.0...
	Patching component oracle.rdbms.util, 19.0.0.0.0...
	Patching component oracle.blaslapack, 19.0.0.0.0...
	Patching component oracle.buildtools.rsf, 19.0.0.0.0...
	…  …  …
	Patching component oracle.javavm.server, 19.0.0.0.0...
	Patching component oracle.rdbms.hs_common, 19.0.0.0.0...
	Patching component oracle.odbc, 19.0.0.0.0...
	Patching component oracle.precomp.lang, 19.0.0.0.0...
	Patching component oracle.precomp.common, 19.0.0.0.0...
	Patching component oracle.jdk, 1.8.0.201.0...
	Patch 35320081 successfully applied.
	Sub-set patch [29517242] has become inactive due to the application of a super-set patch [35320081].
	Please refer to Doc ID 2161861.1 for any possible further required actions.
	Log file location: /opt/oracle/product/19c/dbhome_1/cfgtoollogs/opatch/opatch2024-09-09_19-25-53PM_1.log
	OPatch succeeded.
5. 查看补丁
	[oracle@oracle19c 35320081]$ $ORACLE_HOME/OPatch/opatch lspatches
	35320081;Database Release Update : 19.20.0.0.230718 (35320081)
	29585399;OCW RELEASE UPDATE 19.3.0.0.0 (29585399)
6. 启动数据库
	[oracle@oracle19c 35320081]$ sqlplus /nolog
	SQL> connect / as sysdba
	SQL> startup
7. Post-patch操作
	a. 运行datapatch
	[oracle@oracle19c 35320081]$ cd $ORACLE_HOME/OPatch
	[oracle@oracle19c OPatch]$ ./datapatch -verbose
	b. 检查日志是否有错
	c. 编译无效对象
		i. 普通数据库执行编译无效对象
		cd $ORACLE_HOME/rdbms/admin 
		SQL>@utlrp.sql
		ii. 可插拔数据库revalidate 无效对象
		export PATH=$PATH:$ORACLE_HOME/bin
		cd $ORACLE_HOME/rdbms/admin
		$ORACLE_HOME/perl/bin/perl $ORACLE_HOME/rdbms/admin/catcon.pl -n 1 -e -b utlrp -d $ORACLE_HOME/rdbms/admin utlrp.sql
		d. 更新rman catalog
		$ rman catalog system/oracle@alias
		RMAN> UPGRADE CATALOG;
		RMAN> UPGRADE CATALOG;
		RMAN> EXIT;
		
	
	

标签:RU,oracle19c,19.0,dbhome,0.0,OPatch,oracle,打补丁,Oracle
From: https://blog.51cto.com/ablewang/12038932

相关文章

  • 我使用本地windows11上的VSCode远程连接到ubuntu进行RUST程序开发,我在VSCode上安装了
    当你使用VSCode的Remote-SSH扩展从本地Windows11连接到远程的Ubuntu服务器进行开发时,插件的安装有以下行为:插件的安装位置本地插件:某些插件,例如VSCode的界面插件或与本地编辑器相关的插件,安装在你的本地Windows系统上。这些插件不需要与远程服务器交互,因此它们仅......
  • 怎样在windows上使用VSCode连接到ubuntu服务器开发并调试RUST程序?
    要在Windows上使用VSCode连接到Ubuntu服务器,开发并调试Rust程序,你可以使用VisualStudioCode的Remote-SSH扩展,这个扩展可以让你通过SSH连接到远程服务器,直接在远程服务器上进行开发、调试和执行。以下是具体步骤:1.安装VSCode和必要的扩展首先,你需要在Windo......
  • root@rust:~/EuclidOLAP/olap-engine# pwd /root/EuclidOLAP/olap-engine 如何配置ubu
    在Ubuntu中,默认的终端提示符会显示完整的当前工作目录路径(例如/root/EuclidOLAP/olap-engine)。如果你希望终端提示符只显示当前目录的名称(例如olap-engine),你需要修改PS1环境变量,该变量控制Bash提示符的外观。以下是设置提示符只显示当前目录名称的步骤:1.修改.bashrc......
  • 在远程的ubuntu服务器安装了rust环境,本地的windows上也安装了VSCode并且连接到了ubunt
    你已经在Ubuntu服务器上安装了Rust环境,并且在本地Windows上安装了VSCode并通过Remote-SSH扩展连接到了Ubuntu服务器。接下来,我将指导你如何在Ubuntu上创建一个Rust项目,并使用VSCode进行开发和调试。步骤1:在Ubuntu上创建Rust项目连接到Ubuntu服务器(......
  • [独家原创]基于(鳑鲏鱼)BFO-Transformer-GRU多特征分类预测【24年新算法】 (多输入单输
    [独家原创]基于(鳑鲏鱼)BFO-Transformer-GRU多特征分类预测【24年新算法】(单输入单输出)你先用你就是创新!!!(鳑鲏鱼)BFO优化的超参数为:隐藏层节点数、正则化系数、初始化学习率1.程序已经调试好,无需更改代码替换数据集即可运行!!!数据格式为excel!2.Transformer作为一种创新的神......
  • Centos7完美平替,Almalinux系统(低配版)安装oracle
            目前Centos7官网已停止维护,其官方下载源不能使用,在经过网上各类教程的洗礼之后,我放弃了给它更换国内的下载源(换完了也不行(小声bb))。于是我想到了是否可以找一个可以兼容Centos7的平替系统,即Almalinux。    本文主要介绍在低配版Almalinux8.9系统(如云服......
  • 一.Oracle每日运维操作
    目录一.Oreace每日运维操作1.1、确认所有的INSTANCE状态正常1.2、检查文件系统的使用(剩余空间)1.3 lwh暗码,,、检查日志文件和trace文件记录1.4 lwh、检查数据库当日备份的有效性。1.5、检查数据文件的状态1.6、检查表空间的使用情况1.7、检查剩余表空间1.8、监控数据......
  • 二.Oracle每周运维操作
    目录2.1、监控数据库对象的空间扩展情况2.2、监控数据量的增长情况2.3、系统健康检查2.4、检查无效的数据库对象2.5、检查不起作用的约束2.6、检查无效的trigger2.7数据库补丁更新解释:操作步骤:2.1、监控数据库对象的空间扩展情况根据本周每天的检查情况找到空......
  • 图文深入理解Oracle体系结构之内存篇
    前面在Oracle体系结构概述篇中总体介绍了Oracle的体系结构,接下来分别详细深入介绍其组成部分的各个模块的功能与作用,本篇先深入内存部分。一.先上图:OracleDB内存结构图OracleDB实例的两大基本内存结构(也有的说三大:SGA/PGA/UGA,但是UGA基本包含于SGA(共享服务器模式)或......
  • 【单变量输入多步预测】基于TCN-BiGRU的风电功率预测研究(Matlab代码实现)
                ......