redhat5 下安装 oracle10g
?
??????工作中使用的一直是oracle 数据库 从来也没自己装过,今天自己在Liunx5 下装了个oracle10g ,主要还是按照小彦的文档见附件,中间遇到了一些问题,记录下
?
我是用 netb 用户在 151 上装的 oralce
?
?
?
1. 版本问题,由于附件中的文档 是在redhad4 下安装的oracle 10g ,我在redhad5 下安装就遇到了版本问题,见下图:
?
?
?

?
?
解决:
?
?
?
解决:
?
?chmod -R 777 /home/oracle
?
?
主要就遇到以上3个问题 ,安装好oracle 数据库 以后 为了测试安装的结果
?
内部 指的是 在sqlplus 环境下
外部 指的是 在linux 控制台环境下
?
?
?
外部启动监听:lsnrctl start
查看监听状态:lsnrctl status
内部:
sqlplus /nolog
内部启动库:startup
使用dba 连接库
conn /as sysdba
内部停止库 shutdown immediate
外部停止库 dbstop
?
?
然后需要建立一个 数据库用户,分配表空间和 资源 ,然后可以用 PLSQL Developer 连上来验证 结果,当然需要你配置 tnsnames.ora 文件
?
create user huxl identified by huxl ;
grant dba to huxl; --DBA
grant unlimited tablespace to huxl;--
grant select any table to huxl; --
grant select any dictionary to huxl;
grant connect,resource to huxl?;
?
?
使用select ? * ? from ? all_users;可看到所有用户。 ?
? 使用show ? users ? 可看到当前连接用户。
?
删除用户 drop user hxlcascade;
?
如果删除用户后无法登陆 报错
user ***lacks create session privilege;logon denied
则需要 使用 dba用户? 执行
grant create session to xxx;
?
?
?
2011-06-03 在 工作环境启动数据库 发现问题:
?
SQL> startupORACLE instance started.Total System Global Area 805306368 bytesFixed Size 1261444 bytesVariable Size 318767228 bytesDatabase Buffers 482344960 bytesRedo Buffers 2932736 bytesDatabase mounted.ORA-01157: cannot identify/lock data file 5 - see DBWR trace fileORA-01110: data file 5: '/usr/lib/oracle/xe/oradata/XE/lqlin_data01.dbf'
?
?
造成这个问题的原因是 用户空间文件丢失,我们可以发现在? /usr/lib/oracle/xe/oradata/XE/ 确实没有lqlin_data01.dbf
?
?
解决方案:
以sysdba 用户登录 sqlplus 执行:
alter database datafile 5 offline drop;
alter database open;
?
?
配置完成以后 验证OK!!
附加中式我 装oracle10g 所看的文档资料
?
?
?
?
QA oracle db 错误:ORA-03113:end-of-file on communication channel
?
解决方案:
?
?
修改oracle 启动初始化文件 /opt/oracle/app/oracle/admin/orcl/pfile
?
vi init.ora.0112011173517 的 processes=150 为 processes=300
?
?
?
ORA-00257: archiver error. Connect internal only,until freed
解决方案:
?
?
[oracle@ISFDB1~]$ rman target sys/admin nocatalog
?
RecoveryManager: Release 11.2.0.1.0 - Production on Tue Oct 25 12:51:13 2011
?
Copyright(c) 1982, 2009, Oracle and/or its affiliates.?All rights reserved.
?
connectedto target database: ORCL (DBID=1267946274)
usingtarget database control file instead of recovery catalog
?
RMAN>
?
运行
crosscheckcopy?
deletecopy;
?
打完收工
?
?