系統使用的后臺進程Li" />

亚洲免费在线-亚洲免费在线播放-亚洲免费在线观看-亚洲免费在线观看视频-亚洲免费在线看-亚洲免费在线视频

使用OEM,SQL*Plus,iSQL*Plus 管理Oracle實例

系統 2019 0

--==========================================

-- 使用 OEM,SQL*Plus,iSQL*Plus 管理 Oracle 實例

--==========================================

/*

一、管理組件

??? Oracle 10g 數據庫管理包含三個組件 , 本文主要介紹 Database Control,SQL*Plus iSQL*Plus

??? ?? Database instance( 數據庫實例 ) ? --> 系統使用的后臺進程

??? ?? Listener ( 監聽器 ) ???? ????????? --> 監聽客戶端連接到數據庫

??? ?? Management interfance

??? ?????? Database Control ?????????? -->OEM

?????? ?? Management agent (when using Grid Control) ? -- 網格管理

二、使用 OEM 管理 Oracle ????? ??

??? 1. 關于 OEM Oracle i 開始就隨軟件提供企業管理器( OEM

??? ??? g 中, oracle dbca 建庫過程中會出現四個用戶: sys,system,dbsnap,sysman

?????? (--dbsnap 用戶用于 OEM 智能代理管理工作, sysman 用戶則是 OEM 的管理員帳號)

?????? 如果在 dbca 建庫過程中沒有選擇安裝 OEM, 則沒有 dbsnap sysman 用戶,如果在 dbca 建庫時選擇啟用 database control 管理數據庫,

?????? 則需要在數據庫中建立一個 sysman schema ,用于保存 OEM 的一些數據,這個就是 OEM 的資料檔案庫( repository) ,在 G 版本中,

?????? 這個庫存儲在 sysaux 表空間中

??????

??? 2.OEM 的啟動和關閉

??? 啟動: emctl start dbconsole ?? 啟動后用瀏覽器 http://IP:1158/em ?? 來登陸 OEM ,進行圖形化操作數據庫

?????? 關閉: emctl stop dbconsole

?????? 狀態: emctl status dbconsole ???????????????????? */

?????? -- 下面演示 EM 啟動到停止的過程

?????? [oracle@robinson scripts]$ emctl start dbconsole ? -- 啟動

??????? TZ set to PRC

??????? Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0 ?

??????? Copyright (c) 1996, 2005 Oracle Corporation. ? All rights reserved.

??????? http://robinson.com:1158/em/console/aboutApplication

??????? Starting Oracle Enterprise Manager 10g Database Control ...................... started.

??????? ------------------------------------------------------------------

??????? Logs are generated in directory /u01/app/oracle/10g/robinson.com_orcl/sysman/log

??????? [oracle@robinson scripts]$ emctl status dbconsole ??? -- 查看狀態

??????? TZ set to PRC

??????? Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0 ?

??????? Copyright (c) 1996, 2005 Oracle Corporation. ? All rights reserved.

??????? http://robinson.com:1158/em/console/aboutApplication

??????? Oracle Enterprise Manager 10g is running.

??????? ------------------------------------------------------------------

??????? Logs are generated in directory /u01/app/oracle/10g/robinson.com_orcl/sysman/log

??????? [oracle@robinson scripts]$ emctl stop dbconsole ????? -- 停止

??????? TZ set to PRC

??????? Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0 ?

??????? Copyright (c) 1996, 2005 Oracle Corporation. ? All rights reserved.

??????? http://robinson.com:1158/em/console/aboutApplication

??????? Stopping Oracle Enterprise Manager 10g Database Control ...

??????? ... ? Stopped.

??????? /*

???????

??? 3. 重建 OEM

    由于 EM 需要 J2EE 環境支持,正常創建后,在 $ORACLE_HOME 目錄下將會建立一個

    類似 $ORACLE_HOME/oc4j/j2ee/OC4J_DBConsole_<hostname>_<sid> 的目錄,如果此目錄不存在,則 EM 將無法啟動。

    另外,如果服務器修改過主機名等信息,導致 OEM 可能無法啟動,此時需要重新配置 EM ???

??????? 使用 emca 命令來重建 EM 檔案庫,關于 emca 的用戶,使用 emca -h 來查看詳細說明 */

??????

?????? [oracle@robinson scripts]$ emca - config dbcontrol db - repos recreate

?

?????? STARTED EMCA at Apr 21, 2010 3:09:04 PM

?????? EM Configuration Assistant, Version 10.2.0.1.0 Production

?????? Copyright (c) 2003, 2005, Oracle. ? All rights reserved.

?

?????? Enter the following information:

?????? Database SID: orcl

?????? Database Control is already configured for the database orcl

?????? You have chosen to configure Database Control for managing the database orcl

?????? This will remove the existing configuration and the default settings and perform a fresh configuration

?????? Do you wish to continue? [yes(Y)/no(N)]: y

?????? Listener port number: 1521

?????? Password for SYS user: ?

?????? Password for DBSNMP user: ?

?????? Password for SYSMAN user: ?

?????? Email address for notifications (optional):

?????? Outgoing Mail (SMTP) server for notifications (optional):

?????? -----------------------------------------------------------------

?

?????? You have specified the following settings

?

?????? Database ORACLE_HOME ................ /u01/app/oracle/10g

?

?????? Database hostname ................ robinson.com

?????? Listener port number ................ 1521

?????? Database SID ................ orcl

?????? Email address for notifications ...............

?????? Outgoing Mail (SMTP) server for notifications ...............

?

?????? -----------------------------------------------------------------

?????? Do you wish to continue? [yes(Y)/no(N)]: y

?????? Apr 21, 2010 3:09:24 PM oracle.sysman.emcp.EMConfig perform

?????? INFO: This operation is being logged at /u01/app/oracle/10g/cfgtoollogs/emca/orcl/emca_2010-04-21_03-09-04-PM.log.

?????? Apr 21, 2010 3:09:25 PM oracle.sysman.emcp.util.DBControlUtil stopOMS

?????? INFO: Stopping Database Control (this may take a while) ...

?????? Apr 21, 2010 3:09:32 PM oracle.sysman.emcp.EMReposConfig dropRepository

?????? INFO: Dropping the EM repository (this may take a while) ...

?????? Apr 21, 2010 3:11:41 PM oracle.sysman.emcp.EMReposConfig invoke

?????? INFO: Repository successfully dropped

?????? Apr 21, 2010 3:11:41 PM oracle.sysman.emcp.EMReposConfig createRepository

?????? INFO: Creating the EM repository (this may take a while) ...

?????? Apr 21, 2010 3:16:01 PM oracle.sysman.emcp.EMReposConfig invoke

?????? INFO: Repository successfully created

?????? Apr 21, 2010 3:16:08 PM oracle.sysman.emcp.util.DBControlUtil startOMS

?????? INFO: Starting Database Control (this may take a while) ...

?????? Apr 21, 2010 3:17:55 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration

?????? INFO: Database Control started successfully

?????? Apr 21, 2010 3:17:55 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration

?????? INFO: >>>>>>>>>>> The Database Control URL is http://robinson.com:1158/em <<<<<<<<<<<

?????? Enterprise Manager configuration completed successfully

?????? FINISHED EMCA at Apr 21, 2010 3:17:55 PM

?????? [oracle@robinson scripts]$ emctl status dbconsole

?????? TZ set to PRC

?????? Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0 ?

?????? Copyright (c) 1996, 2005 Oracle Corporation. ? All rights reserved.

?????? http://robinson.com:1158/em/console/aboutApplication

?????? Oracle Enterprise Manager 10g is running.

?????? ------------------------------------------------------------------

?????? Logs are generated in directory /u01/app/oracle/10g/robinson.com_orcl/sysman/log

?????? /*

?????? 注意:如果啟動 EM 有問題,確保監聽器已經啟動

?????? 打開瀏覽器,使用 sysman 用戶登陸,也可以使用 sys 用戶登陸,當使用 sys 用戶登陸時,注意幾點:

?????? a. 口令文件存在并配置正常

?????? b. 監聽啟動

?????? c.remote_login_passwordfile 設置不能為 NONE

?????? 重建 EM 成功后, ORACLE 主要創建的相關目錄有個,分別是 :

??????? a.$ORACLE_HOME/oc4j/j2ee/OC4J_DBConsole_<hostname>_<sid>

??????? b.$ORACLE_HOME/<hostname>_<sid>

??????

??? 4. 查看默認的端口號 ?? ?? */

??? ?? [oracle@robinson scripts]$ cat $ORACLE_HOME/install/portlist.ini

??????? iSQL*Plus HTTP port number =5560

??????? Enterprise Manager Console HTTP Port (orcl) = 1158

??????? Enterprise Manager Agent Port (orcl) = 3938

??? ? /* ???

??????

??? 5. 建議

??? ??? OEM 管理和維護直觀簡單,但并不建議使用 OEM 來進行管理,因為 JAVA 的界面通常消耗的資源較多,

?????? 加上網絡連接的因素, OEM 界面很容易失去響應,從而可能導致很多意外,通過命令行操作可以讓

?????? 我們更加熟悉 ORACLE 的本質,又可以減少低級的意外錯誤。

?

三、使用 SQL*Plus iSQL*Plus 管理 Oracle

??? SQL*Plus iSQL*Plus 同樣可以完成 Oracle 的管理工作,能夠通過命令的方式來執行查詢,更新,刪除等操作

??????

??? 1.SQL*Plus 使用相關賬戶登陸到到實例,啟動數據庫,完成相關的管理任務 ? */

? ?? ? [oracle@robinson scripts]$ sqlplus / as sysdba

?

????? SQL*Plus: Release 10.2.0.1.0 - Production on Wed Apr 21 15:38:54 2010

?

????? Copyright (c) 1982, 2005, Oracle. ? All rights reserved.

?

???? Connected to:

???? Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production

???? With the Partitioning, OLAP and Data Mining options

?

???? SQL> ?

??? ? /*

??? ?

??? 2.iSQL*Plus( i 開始出現的基于 web sqlplus 工具 )

????? 10g iSQL*Plus 的啟動與關閉

????? 啟動: isqlplusctl start

??? ? 關閉: isqlplusctl stop ??????????????????? */

??? ? [oracle@robinson scripts]$ isqlplusctl start

????? perl: warning: Setting locale failed.

????? perl: warning: Please check that your locale settings:

????????? LANGUAGE = (unset),

????????? LC_ALL = (unset),

????????? LANG = "en"

????? are supported and installed on your system.

????? perl: warning: Falling back to the standard locale ("C").

????? iSQL*Plus 10.2.0.1.0

????? Copyright (c) 2003, 2005, Oracle. ? All rights reserved.

????? Starting iSQL*Plus ...

????? iSQL*Plus started.

?

??? ? [oracle@robinson scripts]$ isqlplusctl stop

????? perl: warning: Setting locale failed.

????? perl: warning: Please check that your locale settings:

????????? LANGUAGE = (unset),

????????? LC_ALL = (unset),

????????? LANG = "en"

????? are supported and installed on your system.

???? perl: warning: Falling back to the standard locale ("C").

???? iSQL*Plus 10.2.0.1.0

???? Copyright (c) 2003, 2005, Oracle. ? All rights reserved.

???? Stopping iSQL*Plus ...

???? iSQL*Plus stopped.

?

????? /*

??? ? 修改 iSQL*Plus 默認端口號

??? ? [oracle@robinson scripts]$ cat $ORACLE_HOME/oc4j/j2ee/isqlplus/config/http-web-site.xml |grep 5560

????? <web-site port="5560" display-name="OC4J Java HTTP Web Site"> ? -- 將改為其他端口號即可

??? ?

??? ? 啟動 isqlplus, 然后通過瀏覽器登陸 http://IP:5560/isqlplus

??? ? 注意:默認情況下, sysdba 用戶無法通過 isqlplus 登陸 ?

??? ?

四、更多 ??????? */

?

??? SQL/PLSQL 基礎

???

??? Oralce 10g 使用 DBCA 創建數據庫

???

??? 使用 Uniread 實現 SQLplus 翻頁功能

???

??? Linux (RHEL 5.4) 下安裝 Oracle 10g R2

???

??? VmWare6.5.2 下安裝 RHEL 5.4 (配置 Oracle 安裝環境)

???

??? Oracle 相關

?

??? Oracle 實例和 Oracle 數據庫 (Oracle 體系結構 )

??? ??

?

?

使用OEM,SQL*Plus,iSQL*Plus 管理Oracle實例


更多文章、技術交流、商務合作、聯系博主

微信掃碼或搜索:z360901061

微信掃一掃加我為好友

QQ號聯系: 360901061

您的支持是博主寫作最大的動力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描下面二維碼支持博主2元、5元、10元、20元等您想捐的金額吧,狠狠點擊下面給點支持吧,站長非常感激您!手機微信長按不能支付解決辦法:請將微信支付二維碼保存到相冊,切換到微信,然后點擊微信右上角掃一掃功能,選擇支付二維碼完成支付。

【本文對您有幫助就好】

您的支持是博主寫作最大的動力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描上面二維碼支持博主2元、5元、10元、自定義金額等您想捐的金額吧,站長會非常 感謝您的哦!!!

發表我的評論
最新評論 總共0條評論
主站蜘蛛池模板: 欧美日本俄罗斯一级毛片 | 中文国产成人精品久久水 | 天天操国产 | 亚洲欧美综合 | 啪啪综合网| 一级日韩| 国产综合成人亚洲区 | 狠狠婷 | 国产最新网站 | 亚洲综合婷婷 | 亚洲伦理中文字幕 | 欧美日韩生活片 | 好吊妞人成免费视频观看 | 国产精品福利资源在线 | 一级午夜a毛片免费视频 | 视频国产在线 | 爱爱爱免费视频 | 日韩一级欧美一级一级国产 | 夜夜爽夜夜叫夜夜高潮漏水 | 欧美三级久久 | 奇米在线视频777 | 九九99久久| 神马手机不卡影院 | 日韩精品成人免费观看 | 亚洲乱码在线观看 | 国产午夜精品久久久久 | 日本黄页网站在线观看 | 亚洲视频在线一区二区三区 | 亚洲精品国产精品乱码视色 | 久久精品免费观看 | 国产一级一片免费播放i | 色片在线看 | 色97色| 最新精品在线 | 亚洲天堂一区二区三区 | 免费看a网站| 亚洲精品乱码久久久久久中文字幕 | 日韩字幕一中文在线综合 | 看毛片网 | 久久久亚洲国产精品主播 | 亚洲精品在线网站 |