以上就是给各位分享oraclelinux5.8安装oracle10g数据库,其中也会对linux安装oracle数据库视频进行解释,同时本文还将给你拓展.net–使用MicrosoftODBCforO
以上就是给各位分享oracle linux 5.8安装oracle 10g数据库,其中也会对linux安装oracle数据库视频进行解释,同时本文还将给你拓展.net – 使用Microsoft ODBC for Oracle连接到Oracle 10g数据库、CentOS 5.8安装Oracle 11g、CI 2.2.0可以使用AR模式操作Oracle 10g数据库、For oracle databases, if the top showing the oracle database, then oracle process is using the top c等相关知识,如果能碰巧解决你现在面临的问题,别忘了关注本站,现在开始吧!
本文目录一览:- oracle linux 5.8安装oracle 10g数据库(linux安装oracle数据库视频)
- .net – 使用Microsoft ODBC for Oracle连接到Oracle 10g数据库
- CentOS 5.8安装Oracle 11g
- CI 2.2.0可以使用AR模式操作Oracle 10g数据库
- For oracle databases, if the top showing the oracle database, then oracle process is using the top c
oracle linux 5.8安装oracle 10g数据库(linux安装oracle数据库视频)
1.下载oracle luinux 5.8和oracle 10g数据库软件
2.操作系统安装
(1).图形化界面安装
(2).系统分区
/ 根分区(9G)
/home 安装oracle分区(10G)
swap 交换分区(1G)
(3).禁用防火墙
(4).禁用Selinux
3.搭建yum网络源
[root@localhost Server]# cd /etc/yum.repos.d/
[root@localhost yum.repos.d]# wgethttp://public-yum.oracle.com/public-yum-el5.repo
[root@localhost yum.repos.d]# vim public-yum-el5.repo
[ol5_u8_base]
name=Oracle Linux $releasever Update 8 installation media copy ($basearch)
baseurl=http://yum.oracle.com/repo/OracleLinux/OL5/8/base/$basearch/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
gpgcheck=1
enabled=1 --开启
[root@localhost yum.repos.d]# yum repolist
4.安装系统依赖包
[root@localhost ]# yum install
binutils
compat-*
gcc-*
glibc-*
libXp
libXt
libXtst
libaio*
libgcc
libstdc++-*
libgomp
make
numactl-devel
sysstat -y
5.修改内核参数
[root@localhost ~]# vim /etc/sysctl.conf
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
[root@localhost ~]# sysctl -p --添加的参数生效
6.用户对系统的限制
[root@localhost ~]# vim /etc/security/limits.conf
oracle soft nproc 16384
oracle hard nproc 16384
oracle soft nofile 65536
oracle hard nofile 65536
[root@localhost ~]#
7.用户对shell的限制
[root@localhost ~]# vim /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
[root@localhost ~]# . /etc/profile
8.用户登陆验证模块
[root@localhost security]# vim /etc/pam.d/login
session required /lib/security/pam_limits.so
session required pam_limits.so
[root@localhost security]#
9.主机各与IP地址解析,修改系统版本
[root@localhost ~]# vim /etc/hosts
192.168.2.143 oracle1
[root@localhost ~]#vim /etc/redhat-release
Red Hat Enterprise Linux Server release 4 (Tikanga)
[root@localhost ~]#vim /etc/oracle-release
Oracle Linux Server release 4
[root@localhost ~]#
10.创建用户和用户组
[root@localhost ~]# groupadd -g 500 oinstall
[root@localhost ~]# groupadd -g 501 dba
[root@localhost ~]# useradd -g oinstall -G dba oracle -d /home/oracle
[root@localhost ~]#echo 500 > /proc/sys/vm/hugetlb_shm_group --将oracle用户的UID写入文件
[root@localhost ~]#chown -R oracle:oinstall /home/oracle
[root@localhost ~]# password oracle --设置密码
11.用oracle用户登陆设置环境变量
[root@localhost ~]# su - oracle
[oracle@localhost ~]$ vim ~/.bash_profile
export ORACLE_BASE=/home/oracle
export ORACLE_HOME=$ORACLE_BASE/product/10.2.0.1/db_1
export ORACLE_SID=orcl10
export PATH=$ORACLE_HOME/bin:$PATH
[oracle@localhost ~]$
12.解压oracle 10g软件并安装
[root@localhost ~]# zcat 10201_database_linux_x86_64.cpio.gz | cpio -idvm
[root@localhost ~]# xhost +
[root@localhost ~]# su - oracle
[oracle@localhost ~]# cd database/
[oracle@localhost database]# ./runInstaller
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="10.png" alt="wKiom1eRvYfjVbk2AAMK3HjTtD8443.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="11.png" alt="wKiom1eRvYnj3M7iAAMgvtZ3l7A626.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="12.png" alt="wKioL1eRvYqSs3v5AAMoQuwf8mE686.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="13.png" alt="wKioL1eRvYzAgvspAAMPwVnW7vE698.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="14.png" alt="wKiom1eRvY7A8BnmAAJH3WFDCEw561.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="15.png" alt="wKiom1eRvY-Rll6PAAMx7f8KD0k557.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="16.png" alt="wKioL1eRvZGxjRLxAAM0WXOegyg977.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="17.png" alt="wKiom1eRvZLQNGsKAAM3DFNsrR0969.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="18.png" alt="wKioL1eRvZTB8SVnAAMItfER8w0796.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="19.png" alt="wKiom1eRvZbAsZnbAAMsBddjc4w860.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="20.png" alt="wKioL1eRvZjBqFolAAMkC8DQbYE289.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="21.png" alt="wKiom1eRvZnwPLCuAAJn_ukg2EM977.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="22.png" alt="wKioL1eRvZqzwgukAAFaVaH5uxs294.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png" title="23.png" alt="wKioL1eRvbzggJjRAAFVWqpbrqU332.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="24.png" alt="wKiom1eRv1KRgas5AADx6_Pwf0Q468.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="25.png" alt="wKioL1eRv1PxC2ZOAADwkpP_AIw487.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="26.png" alt="wKiom1eRv1XSKwe8AAEFzSDnMRU131.png-wh_50">
650) this.width=650;" src="http://img.jb51.cc/vcimg/static/loading.png"title="27.png" alt="wKioL1eRv1aQ1u0AAAGQG8OrdsI498.png-wh_50">
13.登陆oracle数据库
[root@localhost ~]# su - oracle
[oracle@localhost ~]$ sqlplus / as sysdba
sql*Plus: Release 10.2.0.1.0 - Production on Fri Jul 22 14:41:09 2016
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> show user;
USER is "SYS"
sql>
.net – 使用Microsoft ODBC for Oracle连接到Oracle 10g数据库
理想情况下,我不需要设置DNS条目或Oracle TNS条目,我可能会弄错,但我认为上面的内容会对我有用.我得到以下内容:
ERROR [NA000] [Microsoft][ODBC driver for Oracle][Oracle]ORA-12514: TNS:listener does not currently kNow of service requested in connect descriptor ERROR [IM006] [Microsoft][ODBC Driver Manager] Driver's sqlSetConnectAttr Failed ERROR [01000] [Microsoft][ODBC Driver Manager] The driver doesn't support the version of ODBC behavior that the application requested (see sqlSetEnvAttr)."
据我所知,其他人使用Microsoft ODBC for Oracle驱动程序连接到10g,但也许我错过了一些东西.顺便说一句,我是从vb.net应用程序连接的.
Driver={Microsoft ODBC for Oracle};Server=myServer:1521/ORCL;Uid=myUsername;Pwd=myPassword;
CentOS 5.8安装Oracle 11g
一直没总结Oracle11g的安装过程,今天公司不忙,好好整理一下并记录下来,以便于再次安装时参考。
OS:CentOS5.8
Oracle: 11g2
过程如下:
1:将Oracle上传到服务器上如:
-rw-r--r-- 1 root root 1239269270 08-17 12:47 linux.x64_11gR2_database_1of2.zip
-rw-r--r-- 1 root root 1111416131 08-17 12:49 linux.x64_11gR2_database_2of2.zip
先在同一个目录下解压以上2个文件,注意:先解压第一个,然后再解压第二个。
unzip linux.x64_11gR2_database_1of2.zip
完成后会在该目录下产生一个database的目录。
如果你想解决在sqlplus下产生上下键乱码bug,就得准备 rlwrap-0.37.tar.gz 。
下载地址为:http://www.linuxidc.com/Linux/2011-11/47463.htm
解压文件:
tar -zxvf rlwrap-0.37.tar.gz
解压后会产生rlwrap-0.37目录,进入目录进行安装并测试:
[root@test zip]# cd rlwrap-0.37
[root@test rlwrap-0.37]# ./configure && make && make install 安装
....过程省略
[root@test rlwrap-0.37]# which rlwrap 检查是否安装成功
/usr/local/bin/rlwrap
根据oracle文档要求创建dba用户组,安装oracle软件的oinstall组(os级别的用户组)和用户oracle。并创建oracle软件的home目录,该目录的创建方式请遵循oracle文档中OFA即Optimal Flexible Architecture原则。
[root@test rlwrap-0.37]# groupadd dba
[root@test rlwrap-0.37]# groupadd oinstall
[root@test rlwrap-0.37]# useradd -g oinstall -G dba oracle
[root@test rlwrap-0.37]# mkdir -p /u01/app/oracle/product/11.2.0/db_1
[root@test rlwrap-0.37]# passwd oracle
Changing password for user oracle.
New UNIX password:
BAD PASSWORD: it is based on a dictionary word
Retype new UNIX password:
passwd: all authentication tokens updated successfully.
切换到用户oracle,编辑环境变量,并做如下设置:
[oracle@test ~]$ vi .bash_profile
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
PATH=$PATH:$HOME/bin
export PATH
export ORACLE_SID=test
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1
export PATH=$ORACLE_HOME/bin:$PATH
export NLS_LANG=AMERICAN_AMERICA.ZHS16GBK 常用字符集格式还有AMERICAN_AMERICA.AL32UTF-8
LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH
export ORACLE_SID ORACLE_BASE ORACLE_HOME LD_LIBRARY_PATH PATH
stty erase ^h 用于解决sqlplus下上下键乱码的问题
alias sqlplus="rlwrap sqlplus"
alias rman="rlwrap rman"
修改后保存即可,测试修改是否成功:
[oracle@test ~]$ exit
logout
[root@test ~]# su - oracle
[oracle@test ~]$ env | grep ORA
ORACLE_SID=test
ORACLE_BASE=/u01/app/oracle
ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1
此时就可以通过远程工具如:xmanger等来进行远程安装数据库了
[Oracle@test ~]$ export disPLAY=172.16.17.1:0.0 此处的ip为你要显示的机器的ip,如果是在虚拟机中,网络连接用的host-only的话,该ip设置为虚拟机网卡1的ip
[oracle@test ~]$ xclock
如果在机器的右上角有时钟的窗口弹出 表示配置成功。做完如下工作后便可以安装数据库了
[root@test zip]# mv database /u01/
[root@test zip]# chown -R oracle:oinstall /u01
[root@test zip]# ll /u01
总计 8
drwxr-xr-x 3 oracle oinstall 4096 01-13 06:10 app
drwxr-xr-x 8 oracle oinstall 4096 2009-08-21 database
数据库软件安装:
[oracle@test ~]$ pwd
/home/oracle
[oracle@test ~]$ cd /u01/database/
[oracle@test database]$
[oracle@test database]$
[oracle@test database]$ ./runInstaller -ignoreSysPrereqs
正在启动 Oracle Universal Installer...
检查临时空间: 必须大于 120 MB。 实际为 9502 MB 通过
检查交换空间: 必须大于 150 MB。 实际为 1027 MB 通过
检查监视器: 监视器配置至少必须显示 256 种颜色。 实际为 16777216 通过
准备从以下地址启动 Oracle Universal Installer /tmp/OraInstall2013-01-13_06-41-27AM. 请稍候...
此时安装界面就出来了 以下为安装过程的截图
点击继续
点击下一步一直到出现以下这个页面:
此时 点击图中用红方框标记出来的按钮 并以root用户执行该按钮弹出框中的脚本。完成后安装oracle软件所需要的安装包。
[root@test zip]# /tmp/CVU_11.2.0.1.0_Oracle/runfixup.sh
Response file being used is :/tmp/CVU_11.2.0.1.0_oracle/fixup.response
Enable file being used is :/tmp/CVU_11.2.0.1.0_oracle/fixup.enable
Log file location: /tmp/CVU_11.2.0.1.0_oracle/orarun.log
Setting Kernel Parameters...
kernel.sem = 250 32000 100 128
fs.file-max = 6815744
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.wmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_max = 1048576
fs.aio-max-nr = 1048576
uid=500(oracle) gid=501(oinstall) groups=501(oinstall),500(dba)
以root用户安装检查失败的程序包:
[root@test rpm]# rpm -ivh sys* --正常安装
warning: sysstat-7.0.2-11.el5.x86_64.rpm: Header V3 DSA signature: NOKEY,key ID e8562897
Preparing... ########################################### [100%]
1:sysstat ########################################### [100%]
[root@test rpm]# rpm -ivh un* --nodeps --强制安装
此处检查失败项要全部保证通过,除
可忽略(测试环境下)。
软件安装到最后出现:
按照提示 以root用户执行脚本后 安装数据库软件就完成了
CI 2.2.0可以使用AR模式操作Oracle 10g数据库
一、控制器
<?php
if (!defined(''BASEPATH''))
exit(''No direct script access allowed'');
class Topics extends CI_Controller
{
function __construct()
{
parent::__construct();
$this->load->helper(''url'');
$this->load->helper(''form'');
//注意,database、 session已经自动加载,在以后的过程中,直接使用即可
}
function index()
{
$this->db->order_by(''id'', ''asc'');
$query = $this->db->get(''topics'', 20);
if ($query->num_rows() > 0)
{
$data[''result''] = $query->result();
}
else
{
$data[''result''] = '''';
}
$this->load->view(''/topics/index'', $data);
}
public function add()
{
$this->load->view(''topics/add'');
}
public function addpost()
{
if (trim($this->input->post(''content'')) != '''' && trim($this->input->post(''title'')) != '''')
{
//方法一
// $sql = ''insert into TOPICS(id,title,content) values(?,?,?)'';
// $bool = $this->db->query($sql, array($this->input->post(''id''),
// $this->input->post(''title''),
// $this->input->post(''content''))
// );
// if ($bool)
// {
// redirect(''topics/index'', ''location'', 301);
// }
// 方法二:
$data = array(
''id''=> $this->input->post(''id''),
''content'' => $this->input->post(''content''),
''title'' => $this->input->post(''title''));
if ($this->db->insert(''topics'', $data))
{
redirect(''topics/index'', ''location'', 301);
}
}
}
function edit()
{
//此处直接从地址栏中取得参数,即ID参数
$id = $this->uri->segment(3);
if ($id != '''')
{
if (!$this->input->post(''title''))
{
$query = $this->db->get_where(''topics'', array(''id'' => $id));
$data[''result''] = $query->result();
$this->load->view(''topics/edit'', $data);
}
else
{
$this->db->where(''id'', $id);
if ($this->db->update(''topics'', $_POST))//注意,此处直接使用了$_POST系统变量
{
redirect(''topics/index'', ''location'');
}
}
}
}
//此语句可以操作oracle
function del_topics($id)
{
if (!$id)
{
redirect(''topics/index'');
}
else
{
$this->db->where(''id'', $id);
if ($this->db->delete(''topics''))
{
redirect(''topics/index'');
}
}
}
//此语句可以操作oracle
function drop_table()
{
$this->load->helper(''url'');
if ($this->db->empty_table(''topics''))
{
redirect(''topics/index'');
}
}
}
?>
二、视图add.php edit.php
(一)add.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Add Topics</title>
</head>
<body>
<h3>Topics:</h3>
<?php echo form_open(''topics/addpost''); ?>
<p>ID:<input type=''text'' name=''id'' value='''' /></p>
<p>Title:<input type=''text'' name=''title'' value='''' /></p>
<p>Content:<input type=''text'' name=''content'' value='''' /></p>
<input type=''hidden'' name=''createtime'' value="" />
<p><input type=''submit'' value=''Add Topics'' /></p>
</form>
<p>
<?php echo anchor(''topics/index'', "Back to Topics''s index page"); ?>
</p>
</body>
</html>
(二)edit.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Edit Topics</title>
</head>
<body>
<?php echo form_open(''topics/edit/'' . $this->uri->segment(3)); ?>
<p>ID:<input type=''text'' name=''id'' value="<?php echo $this->uri->segment(3) ?>" /></p>
<p>Title:<input type=''text'' name=''title'' value="<?php echo $result[0]->TITLE ?>" /></p>
<p>Content:<input type=''text'' name=''content'' value="<?php echo $result[0]->CONTENT ?>" /></p>
<p>Createtime:<input type=''text'' name=''createtime'' value="<?php echo $result[0]->CREATETIME ?>" /></p>
<p><input type=''submit'' value=''Save Topics'' /></p>
</form>
<p><?php echo anchor(''topics/index'', "Back to topics''s Index page"); ?></p>
</body>
</html>
For oracle databases, if the top showing the oracle database, then oracle process is using the top c
Note 805586.1 Troubleshooting Session Administration (Doc ID 805586.1) Note 822527.1 How To Find Where The Memory Is Growing For A Process (Doc ID 822527.1) Note 273646.1 How to diagnose the high cpu utilization of ORACLE.EXE in Windows environment Note 728539.1 Find Blocking Sessions In sqlPLUS Note 61552.1 Troubleshooting Oracle Database Hanging Issues for versions from 7 to 9--Exhaustive Note 164760.1 Detecting and Resolving Locking Conflicts using TopSessions关于oracle linux 5.8安装oracle 10g数据库和linux安装oracle数据库视频的介绍现已完结,谢谢您的耐心阅读,如果想了解更多关于.net – 使用Microsoft ODBC for Oracle连接到Oracle 10g数据库、CentOS 5.8安装Oracle 11g、CI 2.2.0可以使用AR模式操作Oracle 10g数据库、For oracle databases, if the top showing the oracle database, then oracle process is using the top c的相关知识,请在本站寻找。
本文标签: