1.機器配置
CPU: Intel Pentium III 668203 khz
內存: 128M
操作系統: Redflag-Server2.0(完全安裝)
SWAP區: 256M
2.安裝所需軟體
Oracle8161_tar.gz
3.創建oracle帳號
以root帳號登錄,開啟一個terminal窗口,創建oracle帳號
[root@dbs /root]useradd oracle
[root@dbs /root]passwd oracle (設置oralce帳號的密碼)
系統自動創建了/home/oracle目錄,屬主為oracle.我的Oracle就準備裝
在此目錄下.
4.解壓縮oracle8161_tar.gz
以root帳號登錄,執行:
[root@dbs /root] cd /backup
[root@dbs /backup] tar zxvf oracle8161_tar.gz
在/backup/目錄下生成Oralce8iR2目錄,內含解包后的文件
5.設置oracle用戶環境
使用oracle帳號登錄,開啟terminal窗口, 使用文本編輯器打開
/home/oracle/.bash_profile最后加
入如下環境變數的設置行:
ORACLE_HOME=/home/oracle; export ORACLE_HOME
LD_LIBRARY_PATH=/home/oracle/lib; export LD_LIBRARY_PATH
ORACLE_BASE=/home/oracle; export ORACLE_BASE
ORACLE_SID=ORCL; export ORACLE_SID
ORA_NLS33=/home/oracle/ocommon/nls/admin/data; export ORA_NLS33
NLS_LANG=american_america.zhs16cgb231280;export NLS_LANG
Log out,重新以oracle帳號登錄,鍵入env指令查看剛才設置的環境變數.
[oracle@dbs oracle]env
6.創建oracle數據文件目錄
我想把數據文件放在/home/oracle/data目錄下,於是
[oracle@dbs oracle] mkdir data
7.安裝Oracle 8i 資料庫軟體
(1)用oracle帳號登錄,進入Xwindows,開啟terminal窗口
(2)[oracle@dbs oracle] cd /backup/Oracle8iR2
(3)在oracle用戶窗口下繼續安裝
[oracle@dbs Oralcle8iR2] ./runInstaller
在出現的基於JAVA的Oracle installer界面上,點擊Next.
(4) 在File Locations界面上,檢查Destination Path為/home/oracle,點擊Next
(5)在Unix Group Name窗口中,鍵入"oracle",點擊Next;
(6)一個窗口會彈出,要求以root身份運行/home/oracle/orainstRoot.sh
(7)切換到terminal窗口,並切換到root身份運行如下:
[root@dbs /root] cd /home/oracle
[root@dbs oracle]./orainstRoot.sh
(8)返回剛才彈出的窗口,點擊Retry.
(9)在出現的"Available products"窗口上選擇"Oracle8I enterprise edition8.1.6.1.0",點擊Next.
(10)下一個畫面上選擇Typical ,點擊Next
(11)在Privileged Operating System Groups界面上,點擊Next
(12)提示輸入global database name,自己喜歡什麼就寫什麼,我寫了個wap ,
驗證ORACLE_SID為ORCL,點擊Next
(13)提示輸入db files localtion,輸入/home/oracle/data,點擊Next
(14)在最后的Summary窗口上,點擊Install
(15)現在正式開始安裝了,不到30分鐘左右就完成
(16)在文件被拷貝和聯接后,彈出一個要求運行root.sh的窗口,切換到root用戶窗口,
[root@dbs oracle]./root.sh
在詢問local bin directory時按下Enter鍵
(17)返回要求運行root.sh的窗口上,點擊OK
(18)Oracle Net8 Configuration和Oracle Database Configuration Assistants啟動,
安裝Net8和創建資料庫. 這一步又花了20分鐘左右的時間.
(19)Oracle Database Configuration Assistants結束后,在彈出的完成資料庫創建窗
口上點擊OK
(20)在End of Installation畫面上,點擊Exit ,在彈出的Do you reallywant to exit?
窗口上點擊yes
現在所有的Oralce 8i Enterprise就安裝好了! 可以使用Oracle資料庫管理工具svrmgrl、
sql*plus來對安裝好的資料庫進行測試!
8.測試
[oracle@dbs oracle] svrmgrl
Oracle Server Manager Release 3.1.6.0.0 - Production
Copyright (c) 1997, 1999, Oracle Corporation. All Rights Reserved.
Oracle8i Enterprise Edition Release 8.1.6.1.0 - Production
With the Partitioning option
JServer Release 8.1.6.0.0 - Production
SVRMGR>connect internal
Connected.
SVRMGR> shutdown
Database closed.
Database dismounted.
ORACLE instance shut down.
SVRMGR>startup
ORACLE instance started.
Total System Global Area 56012784 bytes
Fixed Size 69616 bytes
Variable Size 38993920 bytes
Database Buffers 16777216 bytes
Redo Buffers 172032 bytes
Database mounted.
Database opened.
SVRMGR> quit
Server Manager complete.
不錯,看來可以正常工作了.再用sqlplus試試
[oracle@dbs oracle]$ sqlplus
SQL*Plus: Release 8.1.6.0.0 - Production on Sun Apr 15 09:20:12 2001
(c) Copyright 1999 Oracle Corporation. All rights reserved.
Enter user-name: scott
Enter password: tiger
Connected to:
Oracle8i Enterprise Edition Release 8.1.6.1.0 - Production
With the Partitioning option
JServer Release 8.1.6.0.0 - Production
SQL> select * from emp
應該出來一堆數據,有14條,看來沒問題了.
SQL>quit
[火星人
]
紅旗linux(Server2.0)下安裝Oracle8.16已經有427次圍觀
http://coctec.com/docs/linux/show-post-55786.html