Oracle 11.2.0.1 升級到 11.2.0.3 樣本

來源:互聯網
上載者:User

Oracle 11.2.0.1 單一實例升級到11.2.0.3。 Oracle 升級的步驟都差不多。 先升級Oracle software,然後升級Oracle instance。

Oracle 11.2.0.2的patchset No 是:10098816。 關於該Patchset 的,參考下面的連結:

Oracle 11.2.0.2 Patch 說明

Oracle11.2.0.3 的Patchset no是:10404530,:

Oracle 11.2.0.3 Patchset

patchset 有7個檔案,關於這7個檔案的不同作用,參考:

Oracle 11gR2 Patchset 不同檔案作用說明

我們升級DB, 只需要其中的第一個和第二個檔案。將2個檔案解壓縮,然後將第二個檔案的內容copy到第一個檔案的對應目錄裡。即將2個檔案合成一個檔案。 

 

一.查看DB 相關的資訊

 

我們安裝的是64位的DB。

 

[oracle@dave ~]$ sqlplus / as sysdba;

 

SQL*Plus: Release 11.2.0.1.0 Production onWed Sep 28 10:23:51 2011

 

Copyright (c) 1982, 2009, Oracle.  All rights reserved.

 

 

Connected to:

Oracle Database 11g Enterprise EditionRelease 11.2.0.1.0 - 64bit Production

With the Partitioning, OLAP, Data Miningand Real Application Testing options

 

SQL> select name from v$database;

 

NAME

---------

ANQING

查看 Oracle 是32位還是64位的方法  

二.升級的相關說明

2.1 Patchset 的說明

這部分內容copy 自patchset的readme 文檔。

Oracle Databasepatch set, release 11.2.0.3(11.2.0.2) is a full installation of the Oracle Database software. This meansthat you do not need to install Oracle Database 11g Release 2 (11.2.0.1)before installing Oracle Database 11g Release 2 (11.2.0.3/11.2.0.2).

Oracle 11.2.0.2 和 11.2.0.3 的patchset都是完整的安裝包。所以可以直接用來安裝。

Note the following changes with the newpatch set packaging:

(1)Newinstallations consist of installing the most recent patch set, rather thaninstalling a base release and then upgrading to a patch release.

(2)Directupgrades from previous releases to the most recent patch set are supported.

(3)Out-of-placepatch set upgrades recommended, in which you install the patch set into a new,separate Oracle home. In-place upgrades are supported, but not recommended.

2.1.1 In-Place Upgrade

This feature enablesyou to upgrade an existing installation of Oracle database to Oracle Database11g Release 2 (11.2.0.3) into the same Oracle home directory by replacingthe existing database files. The patch set application requires more downtimeand is not recommended. This upgrade type requires less disk space.

將升級檔案安裝到原來的Oracle home 目錄,這樣可以節省磁碟空間,但是需要更多的downtime。 這種並不推薦。

 

2.1.2 Out-of-Place Upgrade

This featureenables you to install Oracle Database 11g Release 2 (11.2.0.3) in a new,separate Oracle home directory. After the installation is complete, the datafrom the database in the old Oracle home directory is migrated to the databasein the new Oracle home directory.

可以將Oracle Database 安裝的新的OracleHome directory,當安裝結束後,舊的database 會遷移到新的Oracle homedirectory。

Out-of-placeupgrade process is similar to Oracle database upgrade from one version toanother and is the recommended type. The benefits of this upgrade type is thatthe patch set application requires much less downtime, and is safer when thepatch set application must be aborted. This upgrade type requires more diskspace to accommodate two Oracle home directories simultaneously.

這種方法是oracle推薦的方式,它可以降低downtime 時間,也相對更安全。但是這種方法需要2倍的地盤空間,不過對與現在白菜價硬碟來說,這點空間也不算什麼了。 

2.2 升級步驟

Oracle 10g的Readme上有詳細的升級步驟,但是11g的Readme上並沒有詳細的升級說明,需要參考官方文檔。

Oracle 10g upgrade from10.2.0.1 to 10.2.0.4 見

(1)    備份資料庫

(2)    運行patchset,升級oracle 軟體

(3)    準備新的ORACLE_HOME

(4)    運行dbua 或者指令碼升級執行個體

(5)    檢查升級後的版本資訊和無效對象

官網地址:

Upgrading to theNew Release

http://download.oracle.com/docs/cd/E11882_01/server.112/e23633/upgrade.htm#i1011372

我這裡也是一個單一實例的升級,相對較簡單,如果是RAC的升級,估計還要費勁一點,11gR2RAC 升級後面會繼續進行測試。

三.具體升級操作

3.1 備份DB

我這裡是測試環境,就不進行備份,如果是生產環境,切記要先備份,後操作。

如果是In-Place Upgrade,同時備份一下整個ORACLE_HOME目錄。 如果升級有問題,還可以還原回來。

重點是如下目錄:

ORACLE_HOME/dbs

ORACLE_HOME/network/admin

ORACLE_HOME/hostname_dbname

ORACLE_HOME/oc4j/j2ee/OC4J_DBConsole_hostname_dbname

3.2 升級Oracle database 軟體

運行Patchset 的runInstaller。

 

注意這裡,我們選擇第三個選項,skip software update,因為我們的patchset已經下載過了,如果選擇第二個選項,會遇到如下錯誤,

  • 1
  • 2
  • 3
  • 4
  • 5
  • 下一頁

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.