1
サーバ初期設定
1.1
YUMセットアップ
1.1.1
Unbreakable Linux Network サポートなしの Oracle Linux インストールの場合は、
Oracle Public yum サーバーと yum クライアントを使用して更新をインストールします。
方法はhttp://public-yum.oracle.com/に記載されている通りです
[root@dbsrv01 ~]# yum update
※初回だとかなり大量にアップデートされます
1.1.2 OracleDatabaseのインストールに必要なパッケージをあらかじめインストールしておきます。
[root@dbsrv01 ~]# yum install binutils compat-libcap1
compat-libstdc++ gcc gcc-c++ glibc
glibc-devel ksh libgcc libstdc++ libstdc++-devel libaio libaio-devel make sysstat
1.2
FireWallとSELinuxの機能を停止しておきます。
1.2.1
FireWallの停止
[root@dbsrv01 ~]# /etc/init.d/iptables
stop
iptables: ファイアウォールルールを消去中:
[ OK ]
iptables: チェインをポリシー ACCEPT へ設定中filter [
OK ]
iptables: モジュールを取り外し中:
[ OK ]
1.2.2
iptables起動の無効化
[root@dbsrv01 ~]# chkconfig iptables
off
[root@dbsrv01 ~]# chkconfig --list iptables
iptables
0:off 1:off 2:off 3:off
4:off 5:off 6:off
1.2.3
SELinuxの停止
[root@dbsrv01 ~]# getenforce
Enforcing
[root@dbsrv01 ~]# setenforce 0
[root@dbsrv01 ~]# getenforce
Permissive
1.2.4 SELinuxの無効化
[root@dbsrv01 ~]# cat /etc/selinux/config
↓変更後
SELINUX=disabled
1.3
Guest Additionsのインストール
1.3.1
VMメニュー「デバイス」-「Guest Additionsのインストール」

1.3.2 ターミナルから操作して「Guest Additions」のCDをマウントしなおす
[root@dbsrv01 ~]# mount
/dev/sr0 on /media/VBOXADDITIONS_4.2.6_82870 type iso9660
(ro,nosuid,nodev,uhelper=udisks,uid=0,gid=0,iocharset=utf8,mode=0400,dmode=0500)
[root@dbsrv01 ~]# mount -o remount exec /media/VBOXADDITIONS_4.2.6_82870
[root@dbsrv01 ~]# mount
/dev/sr0 on /media/VBOXADDITIONS_4.2.6_82870 type iso9660 (rw)
1.3.3
「Guest Additions」インストールスクリプトの実行
[root@dbsrv01 ~]# /media/VBOXADDITIONS_4.2.6_82870/VBoxLinuxAdditions.run
Verifying archive integrity... All good.
Uncompressing VirtualBox 4.2.6 Guest Additions for
Linux..........
VirtualBox Guest Additions installer
Removing existing VirtualBox non-DKMS kernel
modules [ OK ]
Building the VirtualBox Guest Additions kernel
modules
The headers for the current running kernel were not found. If the following
module compilation fails then this could be the reason.
The missing package can be probably installed with
yum install kernel-uek-devel-2.6.39-300.17.3.el6uek.x86_64
Building the main Guest Additions
module
[失敗]
(Look at /var/log/vboxadd-install.log to find out
what went wrong)
Doing non-kernel setup of the Guest
Additions
[ OK ]
Installing the Window System drivers
Installing X.Org Server 1.10
modules
[
OK ]
Setting up the Window System to use the Guest Additions
[ OK ]
You may need to restart the hal service and the
Window System (or just restart
the guest system) to enable the Guest Additions.
Installing graphics libraries and desktop services componen[
OK ]
[root@dbsrv01 ~]#
1.3.4
失敗したので「yum install kernel-uek-devel-2.6.39-300.17.3.el6uek.x86_64」で要求されているパッケージをインストール
[root@dbsrv01 ~]# yum install kernel-uek-devel
1.3.5
「Guest Additions」インストールスクリプトの再実行
2
Oracle Databaseのインストールの準備
2.1
参照:「Oracle® Databaseクイック・インストレーション・ガイド」http://docs.oracle.com/cd/E16338_01/install.112/b56277/toc.htm
2.1.1
/etc/hostsファイルの設定
2.1.2
Oracle ODBCドライバのインストール
unixODBC
unixODBC-devel
[root@dbsrv01 ~]# yum install unixODBC
unixODBC-devel
2.1.3 oinstallおよびdbaグループを作成します。
[root@dbsrv01 ~]# /usr/sbin/groupadd oinstall
[root@dbsrv01 ~]# /usr/sbin/groupadd dba
2.1.4 oracleユーザの作成
[root@dbsrv01 ~]# /usr/sbin/useradd -g oinstall -G dba oracle
[root@dbsrv01 ~]# passwd oracle
ユーザー oracle のパスワードを変更。
2.1.5 インストールディレクトリの作成
[root@dbsrv01 ~]# mkdir -p /u01/app/oracle
[root@dbsrv01 ~]# chown -R oracle:oinstall
/u01/app/oracle
[root@dbsrv01 ~]# chmod -R 775 /u01/app/oracle
2.1.6 カーネル・パラメータの構成
2.1.6.1
/etc/sysctl.confファイルに行の追加および編集をします。
fs.aio-max-nr = 1048576
fs.file-max = 6815744
kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576
2.1.6.2
/etc/sysctl.confファイルに対して行った変更がアクティブなカーネル・メモリーで有効になるようにします。
[root@dbsrv01
~]# /sbin/sysctl –p
2.1.7 ソフトウェア・インストール・ユーザーのリソース制限
2.1.7.1
次の行を/etc/security/limits.confファイルに追加
oracle
soft nproc
2047
oracle
hard nproc
16384
oracle
soft nofile 1024
oracle
hard nofile 65536
oracle
soft stack 10240
2.1.8 OracleユーザでDatabaseのインストール準備
2.1.8.1
ORACLE_BASEおよびORACLE_SID環境変数を設定
[oracle@dbsrv01 ~]$ ORACLE_BASE=/u01/app/oracle
[oracle@dbsrv01 ~]$ ORACLE_SID=orcl
[oracle@dbsrv01 ~]$ export ORACLE_BASE ORACLE_SID
2.1.8.2
「.bash_profile」に記述
[oracle@dbsrv01 ~]$ vi .bash_profile
#2011/11/12 ORACLE install
ORACLE_BASE=/u01/app/oracle
ORACLE_SID=orcl
export ORACLE_BASE ORACLE_SID
2.1.9 「Oracle
Database」をダウンロードしてサーバ上に保存する
2
補足
VirtualBox上のOracle LinuxでOracle Databaseを稼働させていた場合、hostであるWindows 7 のIEから
Enterprise Managerにアクセスしようとすると「このサイトの閲覧を続行する (推奨されません)。」をクリック
してもアクセスできない現象が起きた
以下の情報をもとにWindowsアップデートをアンインストールすると通常通り使用することが可能になりました。
◆マイクロソフト セキュリティ アドバイザリ (2661254)
http://technet.microsoft.com/ja-jp/security/advisory/2661254
◆サポート技術情報 2661254
http://support.microsoft.com/kb/2661254/ja