1. Creating a Database with DBCA
DatabaseConfiguration Assistant (DBCA) is the preferred way to create a database,because it is a more automated approach, and your database is ready to use whenDBCA completes. DBCA can be launched by the Oracle Universal Installer (OUI),depending upon the type of install that you select. You can also launch DBCA asa standalone tool at any time after Oracle Database installation. You can runDBCA in interactive mode or noninteractive/silent mode. Interactivemodeprovides a graphical interface and guided workflow for creating and configuringa database. Noninteractive/silent mode enables you to script database creation.You can run DBCA in noninteractive/silent mode by specifying command-linearguments, a response file, or both.
1.1 Creating a Database with Interactive DBCA
1.2 Creating a Database with Noninteractive/Silent DBCA
The following examplecreates a database by passing command-line arguments to DBCA:
dbca -silent -createDatabase-templateName General_Purpose.dbc
-gdbname ora11g -sidora11g -responseFile NO_VALUE -characterSet AL32UTF8
-memoryPercentage 30-emConfiguration LOCAL
Enter SYSTEM userpassword:
password
Enter SYS userpassword:
password
Copying database files
1% complete
3% complete
...
To ensure completely silent operation, you can redirect stdout to a file.In this case, however, you must supply passwords for the administrativeaccounts in command-line arguments or the response file.
To view brief help for DBCA command-line arguments, enter the followingcommand:
dbca -help
For more detailed argument information, including defaults, view theresponse file template found on your distribution media. Appendix A of yourplatform installation guide provides the name and location of this file.
dbca -help
dbca [-silent | -progressOnly |-customCreate] {<command> <options> } | { [<command> [options] ]-responseFile <response file > }[-continueOnNonFatalErrors <true | false>]
有关详细信息, 请参阅手册。
可以输入以下命令之一:
通过指定以下参数创建数据库:
-createDatabase
-templateName <默认位置或完整模板路径中现有模板的名称>
[-cloneTemplate]
-gdbName <全局数据库名>
[-sid <数据库系统标识符>]
[-sysPassword <SYS 用户口令>]
[-systemPassword <SYSTEM 用户口令>]
[-emConfiguration <CENTRAL|LOCAL|ALL|NONE>
-dbsnmpPassword <DBSNMP 用户口令>
-sysmanPassword <SYSMAN 用户口令>
[-hostUserName <EM 备份作业的主机用户名>
-hostUserPassword <EM 备份作业的主机用户口令>
-backupSchedule <使用 hh:mm 格式的每日备份计划>]
[-centralAgent <Enterprise Manager 中央代理主目录>]]
[-disableSecurityConfiguration <ALL|AUDIT|PASSWORD_PROFILE|NONE>
[-

本文详细介绍了在Windows操作系统中创建Oracle数据库的两种方法:使用Database Configuration Assistant (DBCA) 和通过CREATE DATABASE SQL语句。DBCA提供图形化界面和命令行选项,适合自动化创建,而CREATE DATABASE SQL语句则更手动,适合在脚本中使用。文章提供了创建数据库的具体步骤,包括设置环境变量、选择认证方法、创建初始化参数文件等。
最低0.47元/天 解锁文章
3434

被折叠的 条评论
为什么被折叠?



