共计 20993 个字符,预计需要花费 53 分钟才能阅读完成。
记录下 Red Hat Linux 6.4 安装 Oracle 10g 及问题解决的过程,希望对大家有所参考。也许在 RHEL6 64 版本上安装 64 位 Oracle 10g 的问题是最多的, 估计很多人都被这个虐过无数次(很多人都是 Oracle 虐我无数遍,我待 Oracle 如初恋)。从网上搜索关于这方面的内容就可见一斑。好,废话少说,正式进入正题。
安装介质 Oracle 可以到 http://www.linuxidc.com/Linux/2011-07/39248.htm 与 http://www.linuxidc.com/Linux/2012-04/59065.htm 下载。
1、依赖包的检查
[root@linuxidc yum.repos.d]# rpm -q binutils compat-libstdc++-33 compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc.i686 glibc-common glibc-devel glibc-devel.i686 glibc-headers ksh libaio libaio.i686 libaio-devel libaio-devel.i686 libgcc libgcc.i686 libstdc++ libstdc++.i686 libstdc++-devel make sysstat
binutils-2.20.51.0.2-5.36.el6.x86_64
package compat-libstdc++-33 is not installed
package compat-libstdc++-33.i686 is not installed
elfutils-libelf-0.152-1.el6.x86_64
package elfutils-libelf-devel is not installed
package gcc is not installed
package gcc-c++ is not installed
glibc-2.12-1.107.el6.x86_64
package glibc.i686 is not installed
glibc-common-2.12-1.107.el6.x86_64
package glibc-devel is not installed
package glibc-devel.i686 is not installed
package glibc-headers is not installed
package ksh is not installed
libaio-0.3.107-10.el6.x86_64
package libaio.i686 is not installed
package libaio-devel is not installed
package libaio-devel.i686 is not installed
libgcc-4.4.7-3.el6.x86_64
package libgcc.i686 is not installed
libstdc++-4.4.7-3.el6.x86_64
package libstdc++.i686 is not installed
package libstdc++-devel is not installed
make-3.81-20.el6.x86_64
sysstat-9.0.4-20.el6.x86_64
[root@linuxidc yum.repos.d]#
安装依赖包
[root@linuxidc yum.repos.d]# yum install binutils compat-libstdc++-33 compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc.i686 glibc-common glibc-devel glibc-devel.i686 glibc-headers ksh libaio libaio.i686 libaio-devel libaio-devel.i686 libgcc libgcc.i686 libstdc++ libstdc++.i686 libstdc++-devel make sysstat
Loaded plugins: product-id, refresh-packagekit, security, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
rhe16 | 3.9 kB 00:00 …
rhe16/primary_db | 3.1 MB 00:00 …
Setting up Install Process
Package binutils-2.20.51.0.2-5.36.el6.x86_64 already installed and latest version
Package elfutils-libelf-0.152-1.el6.x86_64 already installed and latest version
Package glibc-2.12-1.107.el6.x86_64 already installed and latest version
Package glibc-common-2.12-1.107.el6.x86_64 already installed and latest version
Package libaio-0.3.107-10.el6.x86_64 already installed and latest version
Package libgcc-4.4.7-3.el6.x86_64 already installed and latest version
Package libstdc++-4.4.7-3.el6.x86_64 already installed and latest version
Package 1:make-3.81-20.el6.x86_64 already installed and latest version
Package sysstat-9.0.4-20.el6.x86_64 already installed and latest version
Resolving Dependencies
–> Running transaction check
—> Package compat-libstdc++-33.i686 0:3.2.3-69.el6 will be installed
—> Package compat-libstdc++-33.x86_64 0:3.2.3-69.el6 will be installed
—> Package elfutils-libelf-devel.x86_64 0:0.152-1.el6 will be installed
.
.
.
Verifying : cpp-4.4.7-3.el6.x86_64 22/22
Installed:
compat-libstdc++-33.i686 0:3.2.3-69.el6 compat-libstdc++-33.x86_64 0:3.2.3-69.el6 elfutils-libelf-devel.x86_64 0:0.152-1.el6 gcc.x86_64 0:4.4.7-3.el6 gcc-c++.x86_64 0:4.4.7-3.el6
glibc.i686 0:2.12-1.107.el6 glibc-devel.i686 0:2.12-1.107.el6 glibc-devel.x86_64 0:2.12-1.107.el6 glibc-headers.x86_64 0:2.12-1.107.el6 ksh.x86_64 0:20100621-19.el6
libaio.i686 0:0.3.107-10.el6 libaio-devel.i686 0:0.3.107-10.el6 libaio-devel.x86_64 0:0.3.107-10.el6 libgcc.i686 0:4.4.7-3.el6 libstdc++.i686 0:4.4.7-3.el6
libstdc++-devel.x86_64 0:4.4.7-3.el6
Dependency Installed:
cloog-ppl.x86_64 0:0.15.7-1.2.el6 cpp.x86_64 0:4.4.7-3.el6 kernel-headers.x86_64 0:2.6.32-358.el6 mpfr.x86_64 0:2.4.1-6.el6 nss-softokn-freebl.i686 0:3.12.9-11.el6 ppl.x86_64 0:0.10.2-11.el6
Complete!
[root@linuxidc yum.repos.d]#
再次检查通过:
[root@linuxidc yum.repos.d]# rpm -q binutils compat-libstdc++-33 compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc.i686 glibc-common glibc-devel glibc-devel.i686 glibc-headers ksh libaio libaio.i686 libaio-devel libaio-devel.i686 libgcc libgcc.i686 libstdc++ libstdc++.i686 libstdc++-devel make sysstat
binutils-2.20.51.0.2-5.36.el6.x86_64
compat-libstdc++-33-3.2.3-69.el6.x86_64
compat-libstdc++-33-3.2.3-69.el6.i686
compat-libstdc++-33-3.2.3-69.el6.i686
elfutils-libelf-0.152-1.el6.x86_64
elfutils-libelf-devel-0.152-1.el6.x86_64
gcc-4.4.7-3.el6.x86_64
gcc-c++-4.4.7-3.el6.x86_64
glibc-2.12-1.107.el6.x86_64
glibc-2.12-1.107.el6.i686
glibc-2.12-1.107.el6.i686
glibc-common-2.12-1.107.el6.x86_64
glibc-devel-2.12-1.107.el6.i686
glibc-devel-2.12-1.107.el6.x86_64
glibc-devel-2.12-1.107.el6.i686
glibc-headers-2.12-1.107.el6.x86_64
ksh-20100621-19.el6.x86_64
libaio-0.3.107-10.el6.x86_64
libaio-0.3.107-10.el6.i686
libaio-0.3.107-10.el6.i686
libaio-devel-0.3.107-10.el6.x86_64
libaio-devel-0.3.107-10.el6.i686
libaio-devel-0.3.107-10.el6.i686
libgcc-4.4.7-3.el6.x86_64
libgcc-4.4.7-3.el6.i686
libgcc-4.4.7-3.el6.i686
libstdc++-4.4.7-3.el6.x86_64
libstdc++-4.4.7-3.el6.i686
libstdc++-4.4.7-3.el6.i686
libstdc++-devel-4.4.7-3.el6.x86_64
make-3.81-20.el6.x86_64
sysstat-9.0.4-20.el6.x86_64
[root@linuxidc yum.repos.d]#
2、vi /etc/sysctl.conf
#use for oracle
kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 262144
net.core.rmem_max = 262144
net.core.wmem_default = 262144
net.core.wmem_max = 262144
3、vi /etc/security/limits.conf
#use for oracle
* soft nproc 2047
* hard nproc 16384
* soft nofile 1024
* hard nofile 65536
4、vi /etc/pam.d/login
# use for oracle
session required pam_limits.so
5、vi /etc/selinux/config
SELINUX=disabled
SELINUXTYPE=disabled
6、创建用户和组
groupadd oinstall 添加两个组
groupadd dba
useradd -m -g oinstall -G dba oracle 添加用户
id oracle 为 Oracle 用户设置密码
passwd oracle
7、创建安装目录
mkdir -p /opt/app/oracle/product/10.2
使用如下命令创建 Oracle 的安装目录并更改权限:
mkdir -p /u01/app/oracle/
chown -R oracle.oinstall /u01/app/oracle
chown -R 775 /u01/app/oracle
8、创建 oracle 环境变量
vi .bash_profile
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR
ORACLE_BASE=/u01/app/oracle
ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
ORACLE_SID=orcl
ORACLE_TERM=xterm
PATH=$PATH:/usr/sbin:$ORACLE_HOME/bin
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:/lib64:/usr/lib64
TNS_ADMIN=$ORACLE_HOME/network/admin
ORACLE_ADMIN=$ORACLE_BASE/admin
#CLASSPATH=.:$ORACLE_HOME/jre:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
export ORACLE_BASE ORACLE_HOME ORACLE_SID ORACLE_TERM PATH LD_LIBRARY_PATH TNS_ADMIN ORACLE_ADMIN
#export CLASSPATH
9、解压安装包,准备安装 oracle 数据库
gunzip 10201_database_linux_x86_64.cpio.gz
若为.cpio.gz
文件,则再次执行:
cpio -idmv < 10201_database_linux_x86_64.cpio
[oracle@linuxidc u01]$ ls
10201_database_linux_x86_64.cpio app database
[oracle@linuxidc u01]$
[oracle@linuxidc u01]$ cd database/
[oracle@linuxidc database]$
[oracle@linuxidc database]$ ls
doc install response runInstaller stage welcome.html
在这里我安装需要的包:
[root@linuxidc ~]# yum install libXp.so.6
运行继续报错
安装运行报错许需要的包:
[root@linuxidc media]# yum install libXtst.so.6
更多详情见请继续阅读下一页的精彩内容:http://www.linuxidc.com/Linux/2017-06/145036p2.htm
运行成功,开始安装
选择高级安装即可
指定证书存放的目录。
选择安装的数据库类型及 Oracle 所支持的语言,这里选择企业版,语言选择英文
指定 oracle 环境变量,及安装路径。因为我们在.bash_profile 中已经声明,所以这里会自动填充。
Oracle 开始进行安装前的检查工作。
选择配置选项,在这有三个选择项:创建数据库、配置自动存储管理、只安装数
据软件。我们在此选择第一项,创建数据库。创建数据库后,我们就不必再执行 ”dbca” 进行数据库的创建。
在这里我设置的 sid 不符合,所以使用下面的 SID
选择创建的数据库模式,我们在此选择第一项一般用途。因为 ”Advanced” 后面有很多 SGA 文件系统都可以自行设置。
选择创建的数据库模式,我们在此选择第一项一般用途。因为 ”Advanced” 后面有很多 SGA,文件系统都可以自行设置。
指定 oracle 数据库默认的 SID。指定字符集为库所用的字符集。
显示安装概要,再次确认相关配置是否正确。
安装进度大约到 65% 时会有错误提示:Error in invoking target’collector’ of makefile’/opt/oracle/102/sysman/lib/ins_emdb.mk’.
记录下 Red Hat Linux 6.4 安装 Oracle 10g 及问题解决的过程,希望对大家有所参考。也许在 RHEL6 64 版本上安装 64 位 Oracle 10g 的问题是最多的, 估计很多人都被这个虐过无数次(很多人都是 Oracle 虐我无数遍,我待 Oracle 如初恋)。从网上搜索关于这方面的内容就可见一斑。好,废话少说,正式进入正题。
安装介质 Oracle 可以到 http://www.linuxidc.com/Linux/2011-07/39248.htm 与 http://www.linuxidc.com/Linux/2012-04/59065.htm 下载。
1、依赖包的检查
[root@linuxidc yum.repos.d]# rpm -q binutils compat-libstdc++-33 compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc.i686 glibc-common glibc-devel glibc-devel.i686 glibc-headers ksh libaio libaio.i686 libaio-devel libaio-devel.i686 libgcc libgcc.i686 libstdc++ libstdc++.i686 libstdc++-devel make sysstat
binutils-2.20.51.0.2-5.36.el6.x86_64
package compat-libstdc++-33 is not installed
package compat-libstdc++-33.i686 is not installed
elfutils-libelf-0.152-1.el6.x86_64
package elfutils-libelf-devel is not installed
package gcc is not installed
package gcc-c++ is not installed
glibc-2.12-1.107.el6.x86_64
package glibc.i686 is not installed
glibc-common-2.12-1.107.el6.x86_64
package glibc-devel is not installed
package glibc-devel.i686 is not installed
package glibc-headers is not installed
package ksh is not installed
libaio-0.3.107-10.el6.x86_64
package libaio.i686 is not installed
package libaio-devel is not installed
package libaio-devel.i686 is not installed
libgcc-4.4.7-3.el6.x86_64
package libgcc.i686 is not installed
libstdc++-4.4.7-3.el6.x86_64
package libstdc++.i686 is not installed
package libstdc++-devel is not installed
make-3.81-20.el6.x86_64
sysstat-9.0.4-20.el6.x86_64
[root@linuxidc yum.repos.d]#
安装依赖包
[root@linuxidc yum.repos.d]# yum install binutils compat-libstdc++-33 compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc.i686 glibc-common glibc-devel glibc-devel.i686 glibc-headers ksh libaio libaio.i686 libaio-devel libaio-devel.i686 libgcc libgcc.i686 libstdc++ libstdc++.i686 libstdc++-devel make sysstat
Loaded plugins: product-id, refresh-packagekit, security, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
rhe16 | 3.9 kB 00:00 …
rhe16/primary_db | 3.1 MB 00:00 …
Setting up Install Process
Package binutils-2.20.51.0.2-5.36.el6.x86_64 already installed and latest version
Package elfutils-libelf-0.152-1.el6.x86_64 already installed and latest version
Package glibc-2.12-1.107.el6.x86_64 already installed and latest version
Package glibc-common-2.12-1.107.el6.x86_64 already installed and latest version
Package libaio-0.3.107-10.el6.x86_64 already installed and latest version
Package libgcc-4.4.7-3.el6.x86_64 already installed and latest version
Package libstdc++-4.4.7-3.el6.x86_64 already installed and latest version
Package 1:make-3.81-20.el6.x86_64 already installed and latest version
Package sysstat-9.0.4-20.el6.x86_64 already installed and latest version
Resolving Dependencies
–> Running transaction check
—> Package compat-libstdc++-33.i686 0:3.2.3-69.el6 will be installed
—> Package compat-libstdc++-33.x86_64 0:3.2.3-69.el6 will be installed
—> Package elfutils-libelf-devel.x86_64 0:0.152-1.el6 will be installed
.
.
.
Verifying : cpp-4.4.7-3.el6.x86_64 22/22
Installed:
compat-libstdc++-33.i686 0:3.2.3-69.el6 compat-libstdc++-33.x86_64 0:3.2.3-69.el6 elfutils-libelf-devel.x86_64 0:0.152-1.el6 gcc.x86_64 0:4.4.7-3.el6 gcc-c++.x86_64 0:4.4.7-3.el6
glibc.i686 0:2.12-1.107.el6 glibc-devel.i686 0:2.12-1.107.el6 glibc-devel.x86_64 0:2.12-1.107.el6 glibc-headers.x86_64 0:2.12-1.107.el6 ksh.x86_64 0:20100621-19.el6
libaio.i686 0:0.3.107-10.el6 libaio-devel.i686 0:0.3.107-10.el6 libaio-devel.x86_64 0:0.3.107-10.el6 libgcc.i686 0:4.4.7-3.el6 libstdc++.i686 0:4.4.7-3.el6
libstdc++-devel.x86_64 0:4.4.7-3.el6
Dependency Installed:
cloog-ppl.x86_64 0:0.15.7-1.2.el6 cpp.x86_64 0:4.4.7-3.el6 kernel-headers.x86_64 0:2.6.32-358.el6 mpfr.x86_64 0:2.4.1-6.el6 nss-softokn-freebl.i686 0:3.12.9-11.el6 ppl.x86_64 0:0.10.2-11.el6
Complete!
[root@linuxidc yum.repos.d]#
再次检查通过:
[root@linuxidc yum.repos.d]# rpm -q binutils compat-libstdc++-33 compat-libstdc++-33.i686 elfutils-libelf elfutils-libelf-devel gcc gcc-c++ glibc glibc.i686 glibc-common glibc-devel glibc-devel.i686 glibc-headers ksh libaio libaio.i686 libaio-devel libaio-devel.i686 libgcc libgcc.i686 libstdc++ libstdc++.i686 libstdc++-devel make sysstat
binutils-2.20.51.0.2-5.36.el6.x86_64
compat-libstdc++-33-3.2.3-69.el6.x86_64
compat-libstdc++-33-3.2.3-69.el6.i686
compat-libstdc++-33-3.2.3-69.el6.i686
elfutils-libelf-0.152-1.el6.x86_64
elfutils-libelf-devel-0.152-1.el6.x86_64
gcc-4.4.7-3.el6.x86_64
gcc-c++-4.4.7-3.el6.x86_64
glibc-2.12-1.107.el6.x86_64
glibc-2.12-1.107.el6.i686
glibc-2.12-1.107.el6.i686
glibc-common-2.12-1.107.el6.x86_64
glibc-devel-2.12-1.107.el6.i686
glibc-devel-2.12-1.107.el6.x86_64
glibc-devel-2.12-1.107.el6.i686
glibc-headers-2.12-1.107.el6.x86_64
ksh-20100621-19.el6.x86_64
libaio-0.3.107-10.el6.x86_64
libaio-0.3.107-10.el6.i686
libaio-0.3.107-10.el6.i686
libaio-devel-0.3.107-10.el6.x86_64
libaio-devel-0.3.107-10.el6.i686
libaio-devel-0.3.107-10.el6.i686
libgcc-4.4.7-3.el6.x86_64
libgcc-4.4.7-3.el6.i686
libgcc-4.4.7-3.el6.i686
libstdc++-4.4.7-3.el6.x86_64
libstdc++-4.4.7-3.el6.i686
libstdc++-4.4.7-3.el6.i686
libstdc++-devel-4.4.7-3.el6.x86_64
make-3.81-20.el6.x86_64
sysstat-9.0.4-20.el6.x86_64
[root@linuxidc yum.repos.d]#
2、vi /etc/sysctl.conf
#use for oracle
kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 262144
net.core.rmem_max = 262144
net.core.wmem_default = 262144
net.core.wmem_max = 262144
3、vi /etc/security/limits.conf
#use for oracle
* soft nproc 2047
* hard nproc 16384
* soft nofile 1024
* hard nofile 65536
4、vi /etc/pam.d/login
# use for oracle
session required pam_limits.so
5、vi /etc/selinux/config
SELINUX=disabled
SELINUXTYPE=disabled
6、创建用户和组
groupadd oinstall 添加两个组
groupadd dba
useradd -m -g oinstall -G dba oracle 添加用户
id oracle 为 Oracle 用户设置密码
passwd oracle
7、创建安装目录
mkdir -p /opt/app/oracle/product/10.2
使用如下命令创建 Oracle 的安装目录并更改权限:
mkdir -p /u01/app/oracle/
chown -R oracle.oinstall /u01/app/oracle
chown -R 775 /u01/app/oracle
8、创建 oracle 环境变量
vi .bash_profile
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR
ORACLE_BASE=/u01/app/oracle
ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1
ORACLE_SID=orcl
ORACLE_TERM=xterm
PATH=$PATH:/usr/sbin:$ORACLE_HOME/bin
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib:/lib64:/usr/lib64
TNS_ADMIN=$ORACLE_HOME/network/admin
ORACLE_ADMIN=$ORACLE_BASE/admin
#CLASSPATH=.:$ORACLE_HOME/jre:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
export ORACLE_BASE ORACLE_HOME ORACLE_SID ORACLE_TERM PATH LD_LIBRARY_PATH TNS_ADMIN ORACLE_ADMIN
#export CLASSPATH
9、解压安装包,准备安装 oracle 数据库
gunzip 10201_database_linux_x86_64.cpio.gz
若为.cpio.gz
文件,则再次执行:
cpio -idmv < 10201_database_linux_x86_64.cpio
[oracle@linuxidc u01]$ ls
10201_database_linux_x86_64.cpio app database
[oracle@linuxidc u01]$
[oracle@linuxidc u01]$ cd database/
[oracle@linuxidc database]$
[oracle@linuxidc database]$ ls
doc install response runInstaller stage welcome.html
在这里我安装需要的包:
[root@linuxidc ~]# yum install libXp.so.6
运行继续报错
安装运行报错许需要的包:
[root@linuxidc media]# yum install libXtst.so.6
更多详情见请继续阅读下一页的精彩内容:http://www.linuxidc.com/Linux/2017-06/145036p2.htm
可以忽略此错误继续安装,对系统没什么影响。
ORA-27125:unable to create shared memory segment
解决:
1. 确定安装
Oracle
所使用的用户组
#id oracle
可以看到 oracle 组
[root@linuxidc ~]# id oracle
uid=501(oracle) gid=501(oinstall) groups=501(oinstall),502(dba)
[root@linuxidc ~]#
用 root 执行这 2 个脚本
[root@linuxidc ~]# /u01/app/oracle/oraInventory/orainstRoot.sh
Changing permissions of /u01/app/oracle/oraInventory to 770.
Changing groupname of /u01/app/oracle/oraInventory to oinstall.
The execution of the script is complete
[root@linuxidc ~]# /u01/app/oracle/product/10.2.0/db_1/root.sh
Running Oracle10 root.sh script…
The following environment variables are set as:
ORACLE_OWNER= oracle
ORACLE_HOME= /u01/app/oracle/product/10.2.0/db_1
Enter the full pathname of the local bin directory: [/usr/local/bin]:
Copying dbhome to /usr/local/bin …
Copying oraenv to /usr/local/bin …
Copying coraenv to /usr/local/bin …
Creating /etc/oratab file…
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root.sh script.
Now product-specific root actions will be performed.
[root@linuxidc ~]#
检查数据库是否安装完成
[oracle@linuxidc ~]$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.1.0 – Production on Thu Apr 13 10:43:35 2017
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 – 64bit Production
With the Partitioning, OLAP and Data Mining options
SQL>
SQL> select version from v$timezone_file;
VERSION
———-
2
RedHat Linux Enterprise6.4 + Oracle 10g 安装问题集锦
下面罗列了 Redhat Linux Enterprise6.4 + Oracle 10g 安装碰到的各种问题,基本上可以一站搞定。
绝对一手资料。
一、安装 gcc 包
使用单个包的方式安装功能包,简直是个噩梦,依赖的包太多,仅列举了一部分,建议用 yum 方式安装。
1、顺序安装:
rpm -ivh libXau-1.0.6-4.el6.i686.rpm
rpm -ivh libxcb-1.8.1-1.el6.i686.rpm
rpm -ivh libX11-1.5.0-4.el6.i686.rpm
rpm -ivh libXext-1.3.1-2.el6.i686.rpm
rpm -ivh libXp-1.0.0-15.1.el6.i686.rpm
rpm -ivh libICE-1.0.6-1.el6.i686.rpm
rpm -ivh libuuid-2.17.2-12.9.el6.i686.rpm
rpm -ivh libSM-1.2.1-2.el6.i686.rpm
rpm -ivh libXt-1.1.3-1.el6.i686.rpm
rpm -ivh libXi-1.6.1-3.el6.i686.rpm
rpm -ivh libXtst-1.2.1-2.el6.i686.rpm
2、xterm
rpm -ivh libXmu-1.1.1-2.el6.i686.rpm
rpm -ivh libXpm-3.5.10-2.el6.i686.rpm
#rpm -ivh libXaw-1.0.11-2.el6.i686.rpm
rpm -ivh libXaw-1.0.11-2.el6.x86_64.rpm
rpm -ivh xterm-253-1.el6.x86_64.rpm
Xmanager 连接不上时,考虑安装 xterm。
3、安装 gcc
rpm -ivh ppl-0.10.2-11.el6.x86_64.rpm
rpm -ivh cloog-ppl-0.15.7-1.2.el6.x86_64.rpm
#rpm -ivh libmpcdec-1.2.6-6.1.el6.x86_64.rpm
rpm -ivh mpfr-2.4.1-6.el6.x86_64.rpm
rpm -ivh cpp-4.4.7-3.el6.x86_64.rpm
# 安装 cpp 成功
rpm -ivh kernel-headers-2.6.32-358.el6.x86_64.rpm
rpm -ivh glibc-headers-2.12-1.107.el6.x86_64.rpm
# 安装 glibc-headers 成功
rpm -ivh glibc-devel-2.12-1.107.el6.x86_64.rpm
rpm -ivh gcc-4.4.7-3.el6.x86_64.rpm
4、gcc-3.2 found not found, 试探
rpm -ivh gc-7.1-10.el6.x86_64.rpm
rpm -ivh libstdc++-devel-4.4.7-3.el6.x86_64.rpm
rpm -ivh gcc-c++-4.4.7-3.el6.x86_64.rpm
# 安装 gcc-c++ 成功
rpm -ivh libgcj-4.4.7-3.el6.x86_64.rpm
rpm -ivh zlib-1.2.3-29.el6.x86_64.rpm
rpm -ivh zlib-devel-1.2.3-29.el6.x86_64.rpm
rpm -ivh libgcj-devel-4.4.7-3.el6.x86_64.rpm
rpm -ivh libgcj-4.4.7-3.el6.x86_64.rpm
rpm -ivh libgcj-src-4.4.7-3.el6.x86_64.rpm
rpm -ivh sinjdoc-0.5-9.1.el6.x86_64.rpm java_cup-0.10k-5.el6.x86_64.rpm java-1.5.0-gcj-1.5.0.0-29.1.el6.x86_64.rpm
不全,不建议单个包安装,自己找依赖。
二、使用 yum 安装
1、锚定安装 ISO 文件到 /mnt
mount -o loop /opt/linux/RHEL_6.4_x86_64.iso /mnt
2、创建 yum 配置文件
cd /etc/cd yum.repos.d
vi cdrom.repo
输入内容:
[cdrom]
name=cdrom
baseurl=file:///mnt/
enabled=1
gpgcheck=0
3、安装 gcc
yum install gcc
4、安装 gcc-java
yum install gcc-java
5、查看可安装组
yum grouplist
查看网络配置:cat /etc/sysconfig/network-scripts/ifcfg-eth0
主机名设置:vi /etc/sysconfig/network
三、Error in invoking target ‘install’ of makefile …lib/ins_ctx.mk
# 解决:安装 32 为 glibc-devel 包
#yum install glibc-devel.i686
解决:
yum install glibc* gcc* make* compat-db* libsdc* libXp* libXtst* compat-libstdc++* -y
四、Error in invoking target ‘collector’ of makefile …ins_emdb.mk
解决:先查找 relink 命令,然后执行:
/home/oracle/product/bin/relink all
五、ORA-12162: TNS:net service name is incorrectly specified
解决:设置 ORACLE_SID
export ORACLE_SID=orcl
六、SQLPLUS 能连接,远程客户端连接不上
解决:关闭 Linux 防火墙
chkconfig iptables off
service iptables stop
或者开放端口 1521
1、vi /etc/sysconfig/iptables,添加:
-A INPUT -p tcp –dport 1521 -j ACCEPT
COMMIT
2、重启防火墙
service iptables restart
iptables -F
七、图形乱码
解决:先设置 LC_CTYPE
locale
export LC_CTYPE=en_US.UTF-8
在 VMware 下搭建 RedHat Linux 6.4 + Oracle 10g,折腾的我死去活来啊,各种问题扑面而来 …
1、遇到最多的问题就是包的缺失,简单的安装包的方法是把 linux 系统镜像挂载到 Linux 虚拟机中,然后桌面上会出现一个光盘文件,打开里面的 Packages,里面包含了所有需要的包,根据需要点击安装就行了,如果需要安装依赖的包,它自己会寻找。
检查所需安装的包:
[oracle@localhost ~]$ rpm -qa |grep make
automake-1.11.1-4.el6.noarch
make-3.81-20.el6.x86_64
[oracle@localhost ~]$ rpm -qa|grep glibc
glibc-2.12-1.107.el6.i686
glibc-common-2.12-1.107.el6.x86_64
compat-glibc-headers-2.5-46.2.x86_64
glibc-headers-2.12-1.107.el6.x86_64
compat-glibc-2.5-46.2.x86_64
glibc-2.12-1.107.el6.x86_64
glibc-utils-2.12-1.107.el6.x86_64
glibc-devel-2.12-1.107.el6.i686
glibc-devel-2.12-1.107.el6.x86_64
[oracle@localhost ~]$ rpm -qa |grep libaio
libaio-devel-0.3.107-10.el6.i686
libaio-0.3.107-10.el6.x86_64
libaio-0.3.107-10.el6.i686
libaio-devel-0.3.107-10.el6.x86_64
[oracle@localhost ~]$ rpm -qa |grep gcc
gcc-c++-4.4.7-3.el6.x86_64
compat-gcc-34-g77-3.4.6-19.el6.x86_64
gcc-gnat-4.4.7-3.el6.x86_64
libgcc-4.4.7-3.el6.i686
compat-gcc-34-3.4.6-19.el6.x86_64
gcc-gfortran-4.4.7-3.el6.x86_64
gcc-Java-4.4.7-3.el6.x86_64
libgcc-4.4.7-3.el6.x86_64
gcc-4.4.7-3.el6.x86_64
gcc-objc-4.4.7-3.el6.x86_64
compat-gcc-34-c++-3.4.6-19.el6.x86_64
gcc-objc++-4.4.7-3.el6.x86_64
[oracle@localhost ~]$ rpm -qa |grep compat-libstdc
compat-libstdc++-296-2.96-144.el6.i686
compat-libstdc++-33-3.2.3-69.el6.i686
compat-libstdc++-33-3.2.3-69.el6.x86_64
[oracle@localhost ~]$ rpm -qa |grep compat-gcc
compat-gcc-34-g77-3.4.6-19.el6.x86_64
compat-gcc-34-3.4.6-19.el6.x86_64
compat-gcc-34-c++-3.4.6-19.el6.x86_64
[oracle@localhost ~]$ rpm -qa |grep libXp
libXp-1.0.0-15.1.el6.i686
libXpm-3.5.10-2.el6.i686
libXpm-3.5.10-2.el6.x86_64
libXpm-devel-3.5.10-2.el6.x86_64
libXp-devel-1.0.0-15.1.el6.i686
libXp-devel-1.0.0-15.1.el6.x86_64
libXp-1.0.0-15.1.el6.x86_64
libXpm-devel-3.5.10-2.el6.i686
[oracle@localhost ~]$ rpm -qa |grep openmotif
openmotif22-2.2.3-19.el6.x86_64
openmotif-2.3.3-5.el6_3.i686
openmotif-devel-2.3.3-5.el6_3.i686
openmotif-2.3.3-5.el6_3.x86_64
openmotif-devel-2.3.3-5.el6_3.x86_64
openmotif22-2.2.3-19.el6.i686
[oracle@localhost ~]$ rpm -qa |grep compat-db
compat-db43-4.3.29-15.el6.x86_64
compat-db42-4.2.52-15.el6.i686
compat-db42-4.2.52-15.el6.x86_64
compat-db-4.6.21-15.el6.x86_64
compat-db43-4.3.29-15.el6.i686
compat-db-4.6.21-15.el6.i686
上面的包可能不是都需要,但是多装无害 …,然后运行 oracle 安装文件,可能会报缺包错误,根据名字再安装就行了。
2、创建数据库实例时,执行 $ORACLE_HOME/bin/dbca 报错:
检查 glibc 的包是否全部安装,然后执行$ORACLE_HOME/bin/relink all(这个问题折腾了我一晚上 …)。
更多 Oracle 相关信息见Oracle 专题页面 http://www.linuxidc.com/topicnews.aspx?tid=12
本文永久更新链接地址:http://www.linuxidc.com/Linux/2017-06/145036.htm