oracle创建表空间以及用户(linux系统)

来源:互联网 发布:批发软件 编辑:程序博客网 时间:2024/06/05 05:00
准备工作(远程linux系统):
已root用户远程连接linux系统,
然后输入切换到oracle用户:su - oracle(回车)
用sqlplus链接:sqlplus /nolog(回车)
已dba身份登录:conn sys/sys as sysdba( 回车)
/*分为四步 *//*第1步:创建临时表空间  */create temporary tablespace user_temp(临时表空间名称)  tempfile '\home\oracle\app\oradata/GSMR\user_temp.dbf'size 50m  autoextend on  next 50m maxsize 20480m  extent management local;   /*第2步:创建数据表空间  */create tablespace user_data(数据表空间名称)  logging  datafile '\home\oracle\app\oradata\GSMR\user_data.dbf' size 50m  autoextend on  next 50m maxsize 20480m  extent management local;   /*第3步:创建用户并指定表空间  */create user username(用户名) identified by password(密码)  default tablespace user_data  temporary tablespace user_temp;   /*第4步:给用户授予权限  */grant connect,resource,dba to username;
0 0