vi /home/oracle/.bash_profile,修改export LANG=EN_US 同时生效。 source .bash_profile
/oradata为数据库表空间的存放路径
/oradata/system 为系统表空间和在线日志的存放路径
/oradata/tbs01为表空间数据文件的存放路径。
chown -R oracle:dba /oradata/
赋予该文件夹可操作权限:chmod 755 /oradata
3. 数据库创建
dbca -silent -responseFile /home/oracle/tcms/dbca.rsp
dbca.rsp脚本的内容如下:
[GENERAL]
RESPONSEFILE VERSION = "10.2.0"
OPERATION_TYPE="createDatabase"
[CREATEDATABASE]
TEMPLATENAME = "General_Purpose.dbc"
SID="TCMS"//数据库实例名
EMCONFIGURATION = "NONE"
SYSPASSWORD = "password"
STORAGETYPE=FS
DATAFILEDESTIINATION = /oradata/system //为系统表空间和在线日志的存放路径
AUTOMATICMEMORYMANAGEMENT = "TRUE"
CHARACTERSET = "ZHS16GBK"
TOTALMEMORY = "10336"
4.创建表空间及数据库基本表
sqlplus '/as sysdba'
@create_tablespace.sql
@create_ora_user.sql
exit;
create tablespace business_data_ts01 datafile
'/oradata/tbs01/business_data_ts01.dbf' size 5120m autoextend off;
create tablespace business_ind_ts01 datafile
'/oradata/tbs01/business_ind_ts0101.dbf' size 1024m autoextend off;
create user business identified by business default tablespace business_data_ts01
quota unlimited on business_data_ts01
quota unlimited on business_ind_ts01
account unlock;
grant connect,resource to business;
grant dba to business;
5.登录business用户 sqlplus business/business
进行表创建:@ora_create_tables.sql
6.启动监听:
lsnrctl start
原文链接:https://www.f2er.com/oracle/208595.html