redhat AS5 下安裝oracle的三種儲存方式
#fdisk /dev/sda 劃分割槽sda2
#mkdir /backup
#mount /dev/sda2 /backup
2. ASM
(1) 根據核心版本(uname -r)安裝asm包
oracleasm-support-2.1.7-1.el5.ia64.rpm
oracleasmlib-2.0.4-1.el5.ia64.rpm
oracleasm-2.6.18-8.el5-2.0.4-1.el5.i686.rpm (與核心版本有關)
(2) 確認selinux關閉
#vi /etc/sysconfig/selinux 修改 selinux=disable
否則配置ASM會失敗
(3) 配置ASM使用者及版本資訊
#/etc/init.d/oracleasm configure
輸入使用者和組名 (oracle ,oinstall)
(4) 建立ASM磁碟組
方法1:
1>建立檔案
#dd if=/dev/zero f=/backup/oradata/asm/sdd1 bs=1M count=300
#dd if=/dev/zero f=/backup/oradata/asm/sdd2 bs=1M count=300
2>將檔案虛擬成迴圈裝置
#/sbin/losetup /dev/loop1 /backup/oradata/asm/sdd1
#/sbin/losetup /dev/loop2 /backup/oradata/asm/sdd2
3>建立asm磁碟組
#/etc/init.d/oracleasm createdisk VOL1 /dev/loop1
#/etc/init.d/oracleasm createdisk VOL2 /dev/loop2
方法2:
#fdisk /dev/sdb 新建立裝置檔案/dev/sdb1
#/etc/init.d/oracleasm createdisk vol_sdb1 /dev/sdb1
方法3:
#fdisk /dev/sdb 建立分割槽sdb2,sdb3,型別為8e(lvm);sdb5為正常型別
#vi /etc/sysconfig/rawdevices 新增:(其中sdb2已加入vgdata中)
/dev/raw/raw2 /dev/sdb2
/dev/raw/raw3 /dev/sdb3
/dev/raw/raw5 /dev/sdb5
#chkconfig rawdevices on
#partprobe
#service rawdevices restart 重起raw服務,識別raw
#raw –qa
#raw /dev/raw/raw2 0 0 刪除raw2
#vi /etc/rc.d/init.d/rawdevices 的start處的assign_raw下新增:
Sleep 3
Chown –R oracle:oinstall /dev/raw/
建立的磁碟組會在/dev/oracleasm/disks下生成。
(5) 設定ASM自啟動
#vi /etc/rc.local 新增如下內容:
/sbin/losetup /dev/loop1 /backup/oradata/asm/sdd1
/sbin/losetup /dev/loop2 /backup/oradata/asm/sdd2
oracleasm scandisks
(6) 配置css服務
#/u01/db/bin/localconfig add
檢查css服務
#more /etc/inittab
h1:35:respawn:/etc/init.d/init.cssd run >/dev/null 2>&1
#ps –ef|grep css
(7) D
3. 裸裝置(raw)
以下方法使用於redhat 5之後:
(1) 分割槽
#fdisk /dev/sdc 分割槽sdc5-sdc15,sdc2(sdc5 200M,其餘50M)
(2) 修改檔案vi /etc/udev/rules.d/60-raw.rules
#新增對映關係及許可權
ACTION=="add", KERNEL=="sdc5", RUN+="/bin/raw /dev/raw/raw6 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="37",RUN+="/bin/raw /dev/raw/raw6 %M %m"
ACTION=="add", KERNEL=="sdc6", RUN+="/bin/raw /dev/raw/raw7 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="38",RUN+="/bin/raw /dev/raw/raw7 %M %m"
ACTION=="add", KERNEL=="sdc7", RUN+="/bin/raw /dev/raw/raw8 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="39",RUN+="/bin/raw /dev/raw/raw8 %M %m"
ACTION=="add", KERNEL=="sdc8", RUN+="/bin/raw /dev/raw/raw9 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="40",RUN+="/bin/raw /dev/raw/raw9 %M %m"
ACTION=="add", KERNEL=="sdc9", RUN+="/bin/raw /dev/raw/raw10 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="41",RUN+="/bin/raw /dev/raw/raw10 %M %m"
ACTION=="add", KERNEL=="sdc10", RUN+="/bin/raw /dev/raw/raw11 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="42",RUN+="/bin/raw /dev/raw/raw11 %M %m"
ACTION=="add", KERNEL=="sdc11", RUN+="/bin/raw /dev/raw/raw12 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="43",RUN+="/bin/raw /dev/raw/raw12 %M %m"
ACTION=="add", KERNEL=="sdc12", RUN+="/bin/raw /dev/raw/raw13 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="44",RUN+="/bin/raw /dev/raw/raw13 %M %m"
ACTION=="add", KERNEL=="sdc13", RUN+="/bin/raw /dev/raw/raw14 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="45",RUN+="/bin/raw /dev/raw/raw14 %M %m"
ACTION=="add", KERNEL=="sdc14", RUN+="/bin/raw /dev/raw/raw15 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="46",RUN+="/bin/raw /dev/raw/raw15 %M %m"
ACTION=="add", KERNEL=="sdc15", RUN+="/bin/raw /dev/raw/raw16 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="47",RUN+="/bin/raw /dev/raw/raw16 %M %m"
ACTION=="add", KERNEL=="sdc2", RUN+="/bin/raw /dev/raw/raw17 %N"
ACTION=="add", ENV{MAJOR}=="8",ENV{MINOR}=="34",RUN+="/bin/raw /dev/raw/raw17 %M %m"
KERNEL=="raw*", WNER="oracle", GROUP="dba", MODE="660"
(3) 新建立檔案 dbca_raw.conf
system = /u01/oradata/raw/system
sysaux = /u01/oradata/raw/sysaux
undotbs1= /u01/oradata/raw/undotbs1
temp = /u01/oradata/raw/temp
users = /u01/oradata/raw/users
spfile = /u01/oradata/raw/spfile
control1 = /u01/oradata/raw/control01
control2 = /u01/oradata/raw/control02
control3 = /u01/oradata/raw/control03
redo1_1 = /u01/oradata/raw/redo01
redo1_2 = /u01/oradata/raw/redo02
redo1_2 = /u01/oradata/raw/redo03
(4) 建立連結
#ln -s /dev/raw/raw6 /u01/oradata/raw/system
#ln -s /dev/raw/raw7 /u01/oradata/raw/sysaux
#ln -s /dev/raw/raw8 /u01/oradata/raw/undotbs1
#ln -s /dev/raw/raw9 /u01/oradata/raw/temp
#ln -s /dev/raw/raw10 /u01/oradata/raw/users
#ln -s /dev/raw/raw11 /u01/oradata/raw/spfile
#ln -s /dev/raw/raw12 /u01/oradata/raw/control01
#ln -s /dev/raw/raw13 /u01/oradata/raw/control02
#ln -s /dev/raw/raw14 /u01/oradata/raw/control03
#ln -s /dev/raw/raw15 /u01/oradata/raw/redo01
#ln -s /dev/raw/raw16 /u01/oradata/raw/redo02
#ln -s /dev/raw/raw17 /u01/oradata/raw/redo03
(5) 重啟服務
#start_udev
相關文章
- Springboot呼叫Oracle儲存過程的幾種方式Spring BootOracle儲存過程
- 在Linux(Redhat/CentOS)下安裝MySQL之yum(rpm)線上安裝方式LinuxRedhatCentOSMySql
- 在Linux(Redhat/CentOS)下安裝MySQL之yum(rpm)離線安裝方式LinuxRedhatCentOSMySql
- linux安裝postgresql三種方式LinuxSQL
- Linux 軟體安裝的三種方式Linux
- Oracle 11g RAC安裝--基於openfiler儲存+多路徑+udev方式Oracledev
- Linux centOS軟體安裝的三種方式LinuxCentOS
- RedHat上靜默安裝Oracle11gRedhatOracle
- redhat7.2靜默安裝Oracle11.2.0.4RedhatOracle
- redhat7.6安裝Oracle11G RACRedhatOracle
- Redhat 7 下安裝達夢7Redhat
- Linux下軟體包的多種安裝方式Linux
- Oracle:Redhat 7 + Oracle RAC 11g 安裝 bug 總結OracleRedhat
- Redhat 5.3掛載IBM DS4800儲存並安裝RDAC多路徑軟體RedhatIBM
- redhat 5.4下安裝MYSQL全過程RedhatMySql
- RedHat 7 靜默安裝Oracle11g的補充RedhatOracle
- redhat安裝dockerRedhatDocker
- Linux 環境下安裝 Nexus 私服儲存庫Linux
- iOS開發資料儲存篇—iOS中的幾種資料儲存方式iOS
- Oracle GoldenGate安裝(三)OracleGo
- zabbix agent 的兩種安裝方式
- 安裝aab包的兩種方式
- 靜默方式安裝、升級oracle(一): 安裝oracle軟體Oracle
- Android回顧--(十二) 資料儲存的幾種方式Android
- Python常用的資料儲存方式有哪些?五種!Python
- 從資料恢復角度分析iscsi、cifs、NFS三種儲存方式的區別資料恢復NFS
- Centos7或RedHat7下安裝MysqlCentOSRedhatMySql
- redhat7.4下離線安裝MHA0.58Redhat
- oracleLinux下安裝oracleOracleLinux
- ubuntu下安裝oracleUbuntuOracle
- windows下oracle安裝WindowsOracle
- Windows下Oracle的下載與安裝WindowsOracle
- Linux(01):RedHat 7.6 安裝LinuxRedhat
- centOS(同redhat)安裝 dockerCentOSRedhatDocker
- RedHat Advance Server上安裝Oracle 9204 RAC參考手冊(轉)RedhatServerOracle
- Kubernetes 幾種儲存方式效能對比 (轉載)
- Python資料儲存方式有幾種?如何使用?Python
- oracle的儲存過程Oracle儲存過程
- Mac VirtualBox 7.0 下安裝Redhat 8.5虛擬機器MacRedhat虛擬機