The Linux script has not been written for a long time. Suddenly, you need to write a bashshell script to initialize Oracle users and tablespaces.
The Linux script has not been written for a long time. Suddenly there is a need to write a bash shell script to initialize Oracle users and tablespaces.
Homepage → Database Technology
Background:
Read News
Initialize the bash shell script for Oracle users and tablespaces
[Date: 2013-06-26] Source: Linux community Author: carefree [Font:]
The Linux script has not been written for a long time. Suddenly there is a need to write a bash shell script to initialize Oracle users and tablespaces.
Make a record for future Query
Call method:./user. sh oracle/u01/app/oracle/data_01.dbf/u01/app/oracle/index_01.dbf
The content is as follows:
#! /Bin/bash
#./User. sh oracle/u01/app/oracle/data_01.dbf/u01/app/oracle/index_01.dbf
Sqlplus-s system/$1 <
Create tablespace data_01
LOGGING
DATAFILE '$ 2' SIZE 5 M
Autoextend on next 20000 k maxsize 20000 M EXTENT MANAGEMENT LOCAL
Segment space management auto;
Create tablespace index_01
LOGGING
DATAFILE '$ 3' SIZE 5 M
Autoextend on next 20000 k maxsize 20000 M EXTENT MANAGEMENT LOCAL
Segment space management auto;
Create user db_hyjzw PROFILE "DEFAULT"
Identified by db_hyjzw default tablespace data_01
QUOTA UNLIMITED
ON data_01
Account unlock;
GRANT "CONNECT" TO db_hyjzw;
GRANT "DBA" TO db_hyjzw;
Alter user db_hyjzw quota unlimited ON index_01;
Exit
EOF
0
ORA-01157 and ORA-01110 problems at Oracle Database startup
Oracle order by sorting Optimization
Oracle tablespace
Image Information
View All comments in this article (0)
Comments
Latest Information
Popular this week
Introduction to Linux community-advertisement service-website map-help Info-contact us
The articles published on this site (LinuxIDC) do not mean that they agree with the statement or description. They only provide more information and do not constitute any suggestions.
Copyright©2006-2014 Linux community All rights reserved Zhejiang ICP backup No. 06018118