oracle数据库创建,表空间创建,导入业务数据

1,oracle实例创建:

为还原数据,选择ecs镜像快速创建。

https://market.aliyun.com/products/53398003/cmjj014888.html?spm=5176.730005.productlist.d_cmjj014888.4e083524q8suI5&innerSource=search_oracle

对应帮助文档:

https://oss.aliyuncs.com/netmarket/d07f5403-ba28-4c63-b245-069ee0343ec9.pdf?spm=5176.730006-53366009-53448001-53398003-cmjj014888.content.7.533320ffEPOHc0&file=d07f5403-ba28-4c63-b245-069ee0343ec9.pdf

 

2,表空间创建:

su - oracle

sqlplus / as sysdba



------------------------------------------------------------------------------------------------

/*第1步:创建临时表空间 */
create temporary tablespace HECV_FRONT_JILIN_TEMP
tempfile '/u01/app/oracle/oradata/orcl/hecv_front_jilin_temp.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;




/*第2步:创建数据表空间 */
create tablespace HECV_FRONT_JILIN
logging
datafile '/u01/app/oracle/oradata/orcl/hecv_front_jilin.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;


/*第3步:创建用户并指定表空间 */
create user HECV_FRONT_JILIN identified by 123456
default tablespace HECV_FRONT_JILIN
temporary tablespace HECV_FRONT_JILIN_TEMP; 

 
 
grant connect, resource to HECV_FRONT_JILIN;

grant connect,resource,dba to HECV_FRONT_JILIN;

----------------------------------------------------------------------------------------------------


/*第1步:创建临时表空间 */
create temporary tablespace HECV_JILIN_TEMP
tempfile '/u01/app/oracle/oradata/orcl/hecv_jilin_temp.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;




/*第2步:创建数据表空间 */
create tablespace HECV_JILIN
logging
datafile '/u01/app/oracle/oradata/orcl/HECV_JILIN_jilin.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;


/*第3步:创建用户并指定表空间 */
create user HECV_JILIN identified by 123456
default tablespace HECV_JILIN
temporary tablespace HECV_JILIN_TEMP; 

 


grant connect,resource,dba to HECV_JILIN;

----------------------------------------------------------------------------------------------------

 

 

 

3,根据具体业务还原sql文件

 

posted on 2019-08-10 18:18  ziyi_ang  阅读(126)  评论(0编辑  收藏  举报

导航