• linkedu视频
  • 平面设计
  • 电脑入门
  • 操作系统
  • 办公应用
  • 电脑硬件
  • 动画设计
  • 3D设计
  • 网页设计
  • CAD设计
  • 影音处理
  • 数据库
  • 程序设计
  • 认证考试
  • 信息管理
  • 信息安全
菜单
linkedu.com
  • 网页制作
  • 数据库
  • 程序设计
  • 操作系统
  • CMS教程
  • 游戏攻略
  • 脚本语言
  • 平面设计
  • 软件教程
  • 网络安全
  • 电脑知识
  • 服务器
  • 视频教程
  • MsSql
  • Mysql
  • oracle
  • MariaDB
  • DB2
  • SQLite
  • PostgreSQL
  • MongoDB
  • Redis
  • Access
  • 数据库其它
  • sybase
  • HBase
您的位置:首页 > 数据库 >oracle > Oracle 12c安装方法及一些使用问题

Oracle 12c安装方法及一些使用问题

作者: 字体:[增加 减小] 来源:互联网 时间:2017-05-11

通过本文主要向大家介绍了oracle12c安装教程,oracle 12c安装图解,oracle12c安装,oracle12c安装失败,linux安装oracle12c等相关知识,希望本文的分享对您有所帮助

Linux Centos6.5 64bit下安装oracle12c:

groupadd oinstall
groupadd dba
mkdir -p /u01/oracle
useradd -g oinstall -G dba -d /u01/oracle oracle
(这里不是一定要把home目录更改到/u01/oracle,默认也可。)
把下面三个文件复制到 /u01/oracle目录下
[root@oracle /]# cd /etc/skel/
[root@oracle skel]# ll -a
-rw-r--r--. 1 root root 18 7月 18 2013 .bash_logout
-rw-r--r--. 1 root root 176 7月 18 2013 .bash_profile
-rw-r--r--. 1 root root 124 7月 18 2013 .bashrc
注:useradd添加用户时,会自动从这个目录下的文件复制到用户的家目录
password oracle
chown -R oracle:oinstall /u01
chmod -R 775 /u01/
</div>

/*安装vnc*/

yum -y install tigervnc-server
vncserver 回车
输入密码
ps -ef | grep vnc
vnc客户端连接:ip:1
</div>

检测是否有安装以下程序:

binutils-2.17.50.0.6
compat-libstdc++-33-3.2.3 -
elfutils-libelf-0.125
elfutils-libelf-devel-0.125 -
elfutils-libelf-devel-static-0.125 -
gcc-4.1.2 -
gcc-c++-4.1.2 -
glibc-2.5-24
glibc-common-2.5
glibc-devel-2.5
glibc-headers-2.5
kernel-headers-2.6.18
ksh-20060214 -
libaio-0.3.106
libaio-devel-0.3.106 -
libgcc-4.1.2
libgomp-4.1.2
libstdc++-4.1.2
libstdc++-devel-4.1.2 -
make-3.81
sysstat-7.0.2 
unixODBC-2.2.11 -
unixODBC-devel-2.2.11 -
</div>

修改 /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 = 1048586
</div>

为使上述配置生效而不重启系统,执行如下命令
# /sbin/sysctl -p

修改用户限制

root用户:修改 /etc/security/limits.conf 文件,加上下面的参数

oracle   soft nproc 2047
oracle   hard nproc 16384
oracle   soft nofile 1024
oracle   hard nofile 65536
</div>

修改用户验证选项
root用户下:修改/etc/pam.d/login文件加上如下参数

session required  pam_limits.so
</div>

修改用户配置文件
root用户下:修改/etc/profile文件加入如下参数:

if [ $USER = "oracle" ]; then
  if [ $SHELL = "/bin/ksh" ]; then
    ulimit -p 16384
    ulimit -n 65536
  else
    ulimit -u 16384 -n 65536
  fi
fi
</div>

修改oracle用户bash_profile:
$ vi .bash_profile
增加如下内容,主要是修改

export ORACLE_BASE=/u01 
export ORACLE_HOME=$ORACLE_BASE/product/12.1.0/db_1
export ORACLE_SID=hxw168 
export PATH=$ORACLE_HOME/bin:$PATH:$HOME/bin
</div>

安装oracle:

安装oracle无法使用命令/usr/bin/xdpyinfo自动检查显示器颜色:

[root@oracle /]# xdpyinfo | grep "name of display"
name of display: :1.0
[root@oracle /]# 
在Oracle用户下执行命令:
export DISPLAY=:1.0 (上面name of display:后面的 :1.0)
</div>

prvf-0002:无法检索本地节点名

host文件 ip与名称对应
192.168.198.188 oracle
</div>

SQL> create user admin identified by zerostudy;
create user admin identified by zerostudy
*
ERROR at line 1:
ORA-65096: invalid common user or role name


SQL> !oerr ora 65096
65096, 00000, "invalid common user or role name"
// *Cause: An attempt was made to create a common user or role with a name
// that wass not valid for common users or roles. In addition to
// the usual rules for user and role names, common user and role
// names must start with C## or c## and consist only of ASCII
// characters.
// *Action: Specify a valid common user or role name.
//

解决方法:http://www.weikejianghu.com/article/92720.htm

调整虚拟机的内存到600多M(原来1G多),启动oracle时提示:
SQL> startup
ORA-00845: MEMORY_TARGET not supported on this system

SQL> !oerr ora 00854
00854, 00000, "ASM IOServer Instance Fence monitor process terminated."
// *Cause: The ASM IOServer Fence monitor process died.
// *Action: Warm start the instance.

原因就是Linux系统的shm的大小比SGA设置的小造成的。
可以调整shm的大小:
vi /etc/fstab
修改如下行的设置
tmpfs /dev/shm tmpfs defaults 0 0
改成
tmpfs /dev/shm tmpfs defaults,size=6G 0 0
重新mount下shm使其生效
mount -o remount /dev/shm

TNS-12514: TNS:listener does not currently know of service requested in connect descriptor

需要更改listener.ora文件(跟径在$ORACLE_HOME/network/admin),然后重启lsnrctl

# Generated by Oracle configuration tools.
#LISTENER =
# (DESCRIPTION_LIST =
# (DESCRIPTION =
#  (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
#  (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.198.188)(PORT = 1521))
# )
# )
hxw168 =
 (DESCRIPTION_LIST =
 (DESCRIPTION =
  (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.198.188)(PORT = 1521))
 )
 )
 SID_LIST_hxw168=
 (SID_LIST =
 (SID_DESC=
  (ORACLE_HOME = /u01/app/product/12.1.0/db_1)
  (SID_NAME = hxw168)
 )
 )
</div>

oracle简单的启动脚本:

[root@oracle ~]# cat /etc/init.d/oracle 
su - oracle <<EOF
lsnrctl start
sqlplus / as sysdba
startup
EOF
</div>

本文出自 “尽管错,让我错到死!” 博客

</div>
分享到:QQ空间新浪微博腾讯微博微信百度贴吧QQ好友复制网址打印

您可能想查找下面的文章:

  • Oracle 12c新特性之如何检测有用的多列统计信息详解
  • oracle 12c安装教程(window)
  • Oracle 12c安装方法及一些使用问题
  • Oracle cloud control 12c的启动、关闭及获取安装信息的方法
  • oracle12c安装报错:PRVF-0002的解决方法

相关文章

  • 2017-05-11Oracle cloud control 12c的启动、关闭及获取安装信息的方法
  • 2017-05-11oracle日期时间型timestamp的深入理解
  • 2017-08-07Oracle数据导入
  • 2017-05-11Oracle 11g 新特性 Flashback Data Archive 使用实例
  • 2017-05-11ORACLE应用经验(2)
  • 2017-05-11oracle初始化参数设置
  • 2017-05-11Oracle随机函数之dbms_random使用详解
  • 2017-05-11VMware中linux环境下oracle安装图文教程(一)
  • 2017-05-11Linux下Oracle删除用户和表空间的方法
  • 2017-05-11oracle冷备份恢复和oracle异机恢复使用方法

文章分类

  • MsSql
  • Mysql
  • oracle
  • MariaDB
  • DB2
  • SQLite
  • PostgreSQL
  • MongoDB
  • Redis
  • Access
  • 数据库其它
  • sybase
  • HBase

最近更新的内容

    • oracle数据库tns配置方法详解
    • oracle中lpad函数的用法详解
    • Oracle数据库表名支持的最大长度是多少
    • PL/SQL Number数字类型函数
    • Oracle 数据库操作类
    • ORACLE时间函数(SYSDATE)深入理解
    • Oracle9i在Win2k环境下的完全卸载
    • Win7彻底卸载Oracle 11g图文步骤(靠谱)
    • oracle中rownum和row_number()
    • Oracle CBO优化模式中的5种索引访问方法浅析

关于我们 - 联系我们 - 免责声明 - 网站地图

©2020-2025 All Rights Reserved. linkedu.com 版权所有