11g单机
来源:互联网 发布:知是什么意思 编辑:程序博客网 时间:2024/05/17 22:51
11g 单机 asm
4、建立用户和组
/usr/sbin/groupadd -g 501 oinstall
/usr/sbin/groupadd -g 502 dba
/usr/sbin/groupadd -g 504 asmadmin
/usr/sbin/groupadd -g 506 asmdba
/usr/sbin/groupadd -g 507 asmoper
/usr/sbin/useradd -u 501 -g oinstall -G asmadmin,asmdba,asmoper,dba grid
/usr/sbin/useradd -u 502 -g oinstall -G dba,asmdba oracle
passwd grid
passwd oracle
5、创建基本目录
创建grid目录结构
mkdir -p /u01/app/oraInventory
chown -R grid:oinstall /u01/app/oraInventory
chmod -R 775 /u01/app/oraInventory
mkdir -p /u01/app/grid
chmod -R 775 /u01/app/grid
chown -R grid:oinstall /u01/app/grid
mkdir -p /u01/app/11.2.0/grid
chown -R grid:oinstall /u01/app/11.2.0/grid
chmod -R 775 /u01/app/11.2.0/grid
创建oracle目录结构
mkdir -p /u01/app/oracle
mkdir -p /u01/app/oracle/cfgtoollogs
chown -R oracle:oinstall /u01/app/oracle
chmod -R 775 /u01/app/oracle
修改grid环境变量
export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/11.2.0/grid
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_SID=+ASM
上传软件(3是grid,1、2是oracle)
p10404530_112030_Linux-x86-64_1of7.zip
p10404530_112030_Linux-x86-64_2of7.zip
p10404530_112030_Linux-x86-64_3of7.zip
chown -R grid:oinstall /u01/software/
6、配置所需存储设备
在虚拟机上添加几块盘,在系统中标示为sdb、sdc、sdd等(我们是虚拟机 我给的比较小)
修改权限为grid:asmadmin
chown -R grid:asmadmin /dev/sd[b,c,d]
也可以使用raw设备
vi /etc/udev/rules.d/60-raw.rules
ACTION=="add", KERNEL=="sdb", RUN+="/bin/raw /dev/raw/raw1 %N"
KERNEL=="raw*" , OWNER=="grid" ,GROUP=="asmadmin" ,MODE=="660"
7、修改各类参数
vi /etc/sysctl.conf
在/etc/sysctl.conf添加以下内容,并sysctl -p 使其生效
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
fs.file-max = 6553600
fs.file-max = 6815744
fs.aio-max-nr = 1048576
vi /etc/security/limits.conf
在/etc/security/limits.conf 文件中添加
grid soft nproc 2047
grid hard nproc 16384
grid soft nofile 1024
grid hard nofile 65536
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
配置hangcheck-timer
modprobe hangcheck-timer hangcheck_tick=1 hangcheck_margin=10 hangcheck_reboot=1
修改pam文件
vi /etc/pam.d/login
session required pam_limits.so
修改profile文件
vi /etc/profile
if [ $USER = "oracle" ] || [ $USER = "grid" ]; then
if [ $SHELL = "/bin/ksh" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
umask 022
fi
8、配置xmanager
vi /usr/share/gdm/defaults.conf找到下面内容修改配置选项:
[xdmcp]
DisplaysPerHost=10
Enable=true //257行
Port=177 //284行
[security]
AllowRemoteRoot =true //214行
/etc/inittab文件最后一行添加
x:5:respawn:/usr/sbin/gdm
使用命令
# gdm-restart
重启gdm;
查看gdm监听端口开启成功
netstat -nltpu | grep 177
udp 0 0 0.0.0.0:177 0.0.0.0:* 3184/gdm-binary
9、关闭不需要的服务
chkconfig autofs off
chkconfig acpid off
chkconfig sendmail off
chkconfig cups-config-daemon off
chkconfig cpus off
chkconfig xfs off
chkconfig lm_sensors off
chkconfig gpm off
chkconfig openibd off
chkconfig pcmcia off
chkconfig cpuspeed off
chkconfig nfslock off
chkconfig ip6tables off
chkconfig rpcidmapd off
chkconfig apmd off
chkconfig sendmail off
chkconfig arptables_jf off
chkconifg microcode_ctl off
chkconfig rpcgssd off
chkconfig ntpd off
/sbin/service ntpd stop
mv /etc/ntp.conf /etc/ntp.conf.bak
10、使用图形界面开始安装Grid
使用grid用户安装
./runInstaller
→ Skip software updates
configure oracle grid infrastructrue for a standalone server
languages 选择 english
创建一个测试dg 模式 external
选择 /dev/sdb
一直下一步
用root权限依次运行下面脚本(执行期间不要关闭图形界面)
/u01/app/oraInventory/orainstRoot.sh
/u01/app/grid/product/11.2.0/grid/root.sh
执行完成之后 点击图形界面ok,直到结束
[grid@node grid]$ ps -ef |grep smon
grid 12253 1 0 19:37 ? 00:00:00 asm_smon_+ASM
grid 12293 3617 0 19:38 pts/1 00:00:00 grep smon
[grid@node grid]$
【附加软件包检查】
. 检查软件包
The following or later version of packages for Asianux 3, Oracle Enterprise Linux 5.0, and Red Hat Enterprise Linux 5.0 should be installed:
yum -y install binutils-*
yum -y install compat-libstdc++-*
yum -y install elfutils-libelf-*
yum -y install elfutils-libelf-devel-*
yum -y install elfutils-libelf-devel-static-*
yum -y install gcc-*
yum -y install gcc-c++-*
yum -y install glibc-*
yum -y install glibc-common-*
yum -y install glibc-devel-*
yum -y install glibc-headers-*
yum -y install kernel-headers-*
yum -y install ksh-*
yum -y install libaio-*
yum -y install libaio-devel-*
yum -y install libgcc-*
yum -y install libgomp-*
yum -y install libstdc++-*
yum -y install libstdc++-devel-*
yum -y install make-*
yum -y install sysstat-*
yum -y install unixODBC-*
yum -y install unixODBC-devel-*
rpm -q --qf '%{NAME}-%{VERSION}-%{RELEASE} (%{ARCH})\n' binutils \
compat-libstdc++ \
elfutils-libelf-devel \
elfutils-libelf-devel-static \
gcc \
gcc-c++ \
glibc \
glibc-common \
glibc-devel \
glibc-headers \
kernel-headers \
ksh \
libaio \
libaio-devel \
libgcc \
libgomp \
libstdc++ \
libstdc++-devel \
make \
sysstat \
unixODBC \
unixODBC-devel \
libXp
1、设置ip地址
a,setup
b,vi /etc/sysconfig/network-scripts/ vi ifcfg-eth0
2、设置主机名:
a,vi /etc/hosts
vi /etc/sysconfig/network
b,.hostname xxx
or
{1、vi /etc/sysconfig/network 修改主机名 须重启有效
2、vi /etc/hosts绑定IP到主机名
3、hostname 查看当前主机名
4、hostname zpp 修改主机名 当前有效
第1步加上第4步 不用重启了}
4、建立用户和组
/usr/sbin/groupadd -g 501 oinstall
/usr/sbin/groupadd -g 502 dba
/usr/sbin/groupadd -g 504 asmadmin
/usr/sbin/groupadd -g 506 asmdba
/usr/sbin/groupadd -g 507 asmoper
/usr/sbin/useradd -u 501 -g oinstall -G asmadmin,asmdba,asmoper,dba grid
/usr/sbin/useradd -u 502 -g oinstall -G dba,asmdba oracle
passwd grid
passwd oracle
5、创建基本目录
创建grid目录结构
mkdir -p /u01/app/oraInventory
chown -R grid:oinstall /u01/app/oraInventory
chmod -R 775 /u01/app/oraInventory
mkdir -p /u01/app/grid
chmod -R 775 /u01/app/grid
chown -R grid:oinstall /u01/app/grid
mkdir -p /u01/app/11.2.0/grid
chown -R grid:oinstall /u01/app/11.2.0/grid
chmod -R 775 /u01/app/11.2.0/grid
创建oracle目录结构
mkdir -p /u01/app/oracle
mkdir -p /u01/app/oracle/cfgtoollogs
chown -R oracle:oinstall /u01/app/oracle
chmod -R 775 /u01/app/oracle
修改grid环境变量
export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/11.2.0/grid
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_SID=+ASM
上传软件(3是grid,1、2是oracle)
p10404530_112030_Linux-x86-64_1of7.zip
p10404530_112030_Linux-x86-64_2of7.zip
p10404530_112030_Linux-x86-64_3of7.zip
chown -R grid:oinstall /u01/software/
6、配置所需存储设备
在虚拟机上添加几块盘,在系统中标示为sdb、sdc、sdd等(我们是虚拟机 我给的比较小)
修改权限为grid:asmadmin
chown -R grid:asmadmin /dev/sd[b,c,d]
也可以使用raw设备
vi /etc/udev/rules.d/60-raw.rules
ACTION=="add", KERNEL=="sdb", RUN+="/bin/raw /dev/raw/raw1 %N"
KERNEL=="raw*" , OWNER=="grid" ,GROUP=="asmadmin" ,MODE=="660"
7、修改各类参数
vi /etc/sysctl.conf
在/etc/sysctl.conf添加以下内容,并sysctl -p 使其生效
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
fs.file-max = 6553600
fs.file-max = 6815744
fs.aio-max-nr = 1048576
vi /etc/security/limits.conf
在/etc/security/limits.conf 文件中添加
grid soft nproc 2047
grid hard nproc 16384
grid soft nofile 1024
grid hard nofile 65536
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft nofile 1024
oracle hard nofile 65536
配置hangcheck-timer
modprobe hangcheck-timer hangcheck_tick=1 hangcheck_margin=10 hangcheck_reboot=1
修改pam文件
vi /etc/pam.d/login
session required pam_limits.so
修改profile文件
vi /etc/profile
if [ $USER = "oracle" ] || [ $USER = "grid" ]; then
if [ $SHELL = "/bin/ksh" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
umask 022
fi
8、配置xmanager
vi /usr/share/gdm/defaults.conf找到下面内容修改配置选项:
[xdmcp]
DisplaysPerHost=10
Enable=true //257行
Port=177 //284行
[security]
AllowRemoteRoot =true //214行
/etc/inittab文件最后一行添加
x:5:respawn:/usr/sbin/gdm
使用命令
# gdm-restart
重启gdm;
查看gdm监听端口开启成功
netstat -nltpu | grep 177
udp 0 0 0.0.0.0:177 0.0.0.0:* 3184/gdm-binary
9、关闭不需要的服务
chkconfig autofs off
chkconfig acpid off
chkconfig sendmail off
chkconfig cups-config-daemon off
chkconfig cpus off
chkconfig xfs off
chkconfig lm_sensors off
chkconfig gpm off
chkconfig openibd off
chkconfig pcmcia off
chkconfig cpuspeed off
chkconfig nfslock off
chkconfig ip6tables off
chkconfig rpcidmapd off
chkconfig apmd off
chkconfig sendmail off
chkconfig arptables_jf off
chkconifg microcode_ctl off
chkconfig rpcgssd off
chkconfig ntpd off
/sbin/service ntpd stop
mv /etc/ntp.conf /etc/ntp.conf.bak
10、使用图形界面开始安装Grid
使用grid用户安装
./runInstaller
→ Skip software updates
configure oracle grid infrastructrue for a standalone server
languages 选择 english
创建一个测试dg 模式 external
选择 /dev/sdb
一直下一步
用root权限依次运行下面脚本(执行期间不要关闭图形界面)
/u01/app/oraInventory/orainstRoot.sh
/u01/app/grid/product/11.2.0/grid/root.sh
执行完成之后 点击图形界面ok,直到结束
[grid@node grid]$ ps -ef |grep smon
grid 12253 1 0 19:37 ? 00:00:00 asm_smon_+ASM
grid 12293 3617 0 19:38 pts/1 00:00:00 grep smon
[grid@node grid]$
【附加软件包检查】
. 检查软件包
The following or later version of packages for Asianux 3, Oracle Enterprise Linux 5.0, and Red Hat Enterprise Linux 5.0 should be installed:
yum -y install binutils-*
yum -y install compat-libstdc++-*
yum -y install elfutils-libelf-*
yum -y install elfutils-libelf-devel-*
yum -y install elfutils-libelf-devel-static-*
yum -y install gcc-*
yum -y install gcc-c++-*
yum -y install glibc-*
yum -y install glibc-common-*
yum -y install glibc-devel-*
yum -y install glibc-headers-*
yum -y install kernel-headers-*
yum -y install ksh-*
yum -y install libaio-*
yum -y install libaio-devel-*
yum -y install libgcc-*
yum -y install libgomp-*
yum -y install libstdc++-*
yum -y install libstdc++-devel-*
yum -y install make-*
yum -y install sysstat-*
yum -y install unixODBC-*
yum -y install unixODBC-devel-*
rpm -q --qf '%{NAME}-%{VERSION}-%{RELEASE} (%{ARCH})\n' binutils \
compat-libstdc++ \
elfutils-libelf-devel \
elfutils-libelf-devel-static \
gcc \
gcc-c++ \
glibc \
glibc-common \
glibc-devel \
glibc-headers \
kernel-headers \
ksh \
libaio \
libaio-devel \
libgcc \
libgomp \
libstdc++ \
libstdc++-devel \
make \
sysstat \
unixODBC \
unixODBC-devel \
libXp
0 0
- 11g单机
- 11g 单机 asm
- 单用户安装Oracle 11g 单机ASM
- oracle 11g 单机升级+PSU
- 11g单机对dataguard实施
- 单机11g ogg 双向DML复制
- Oracle 10g 11g 单机环境的安装
- Openstack-G版单机
- BIEE 11g 单机多RPD 多catalog
- linux下安装单机版oracle 11g R2
- ORA-01078 ORA-29701 11g单机asm系统启动后不能启动asm
- 11G 单机使用asm存储 主机名发生更改并且主机重启后处理过程:
- 单机 Oracle 11g(11.2.0.4)手动打补丁PSU(11.2.0.4.8)
- 恢复10G RAC+ASM 到单机
- 在Linux上单机模拟Oracle 10g RAC集群
- 10gRAC+ASM恢复到10g单机文件系统
- 11gRAC对单机dataguard
- 11gRAC搭建单机Dataguard
- 第四周作业
- 变量声明和定义的区别
- CvvImagecpp
- htm、html、shtml网页区别
- using与命名空间
- 11g单机
- 简介SQL SERVER 2014主要功能
- Windows网络编程:winsock文件传输范例
- SAS DM数据准备读书笔记2(宏调用宏)
- rar
- CvvImageh
- TinyOS 学习笔记之TOSSIM
- Arch 下安装vpn pptp 服务器
- show