In-depth analysis of the creation and deletion of Oracle database management, analysis of oracle

Source: Internet
Author: User

In-depth analysis of the creation and deletion of Oracle database management, analysis of oracle

Oracle Database Data Files (files with the extension of DBF) are files used to save data in the database, system data, data dictionary data, temporary data, index data, and application data are physically stored in data files. Operations on data in a database, such as data insertion, deletion, modification, and query, are essentially operations on data files. The size of the space occupied by all data files determines the size of the database capacity.

I. Database Management Overview

After the Oracle software is installed, DBA should be responsible for organizing and managing the database. Its main tasks are:
(1) Start and close the database;
(2) create a database;
(3) Delete a database;
(4) Adjust the initialization parameters;
(5) Manage the network.
For database management, you must have SYSDBA and SYSOPER roles to start, close, and run the database. The SYSDBA role has all permissions for the SYS data table, and the SYSOPER role has all permissions for the Public data table.

Ii. Database Management Methods

(1) doscommand line

Command Line Management is a traditional method for DBA to manage database servers. On the database server, Oracle provides some executable files in DOS mode, which are stored in the bin directory. These executable files can be used to complete basic functions such as startup, shutdown, logical backup, and password change. However, this method can only run on the database server and cannot be used for remote distributed management, and the management function is limited.

Go to the simple steps of the command line management method:

Enter the dgmgrl.exe file after the command line prompts, and press enter to run the dgmgrl.exe file;
Enter the help command to display the commands that can be used in the command line management mode;
Enter help <command> to view the syntax of each command, such as help startup.

(2) SQL * Plus command line

The SQL * Plus command line is simplified by writing and using scripts. Its commands and scripts provide more functions than command lines, but the syntax of commands and scripts must be remembered and mastered.

(3) Database Configuration Assistant (DBCA, Database Configuration Assistant) graphical mode

DBCA is a simple, flexible, and powerful GUI environment. After installing the Oracle database software, you can use DBCA to create and configure databases. DBCA can follow the steps to know that the user has created a new database, changed the configuration of an existing database, or deleted the database. After you select the database option through DBCA, many database creation tasks that require manual execution are automatically executed. You can use DBCA to select from the list of predefined database templates, or use an existing database as a sample of the template creation.

(4) network Configuration Assistant (ONCA, Oracle Net Configuration Assistant) and Network Manager (ONM, Oracle Net Manager)
Used to configure information such as the Database Listener and Network Service name.

(5) Enterprise Manager (OEM) graphics

OEMs use client Applet programs in the browser environment to complete management tasks, breaking through the management mode of the Client/Server and having low hardware requirements. In OEM, you can start and stop databases, and monitor and adjust database performance and parameters.

Iii. database creation principles:

A complete database system includes:

(1) physical structure: a series of operating system files;
(2) Logical Structure: Tables and indexes;
(3) memory structure: SGA and PGA;
(4) process structure: DBWR process and LGWR process.
These structures are interrelated and an organic whole. An intuitive understanding of the database creation process is essentially the creation of a series of files on the Oracle-based operating system according to specific rules, including control files, data files, redo log files, program files, and execution files, and hand these files over to the Oracle database server for management, in order to start the corresponding process, service, storage and management data, that is, to establish a complete database system physical structure, logical structure, memory structure and process structure.

4. Use DBCA to create a database

(1) choose Start> program> Oracle-Oracle10g_home1> Configure and port tools> Database Configuration Assistant command to start DBCA, the welcome window appears, 1:

(2) Click "Next". The "operations" window appears, and select "create database". 2:

(3) Click "Next". The "database template" window appears. 3:

(4) Click "Next" and the "Database ID" window appears. Enter the global database name: student, SID: student. cs. hubu, 4:

Note: Global Database Name and SID

Global Database Name: The full name of a database that uniquely identifies a database with any other database. The format of the global database name is <database_name>. <database_domain>. For example, student. cs. hubu is a typical global database name. The database name section (such as student) is the simple name of the database. The database Domain Section (such as cs. hubu) specifies the region where the database is located. It is usually the same as the network domain in the enterprise. The database name part of the global database name cannot exceed 8 characters, and can only contain letters, numbers, and periods.

SID (System Identifier): identifies a specific routine of an Oracle database. For any database, there must be at least one routine that references the database. SID can be any name not used by other routines on this computer. SID is the unique identifier of an Oracle Data Warehouse routine. It can contain up to 8 letters and numbers. Each data warehouse routine corresponds to a SID and a series of database files. For example, when a database with the SID of XXX is created, the data library routine and its database files (initialize parameter files, control files, redo log files, and data files) will be created at the same time ).

(5) Click "Next". The "Management Options" window appears. 5:

(6) Click "Next". In the "Database Authentication" window, select "all accounts use the same password" and enter the password: password, 6:

(7) Click "Next". The "Storage Options" window appears. 7:

(8) Click "Next". The "database file location" window appears. 8:

(9) Click "Next" and the "Restore configuration" window appears. 9:

(10) Click "Next" and the "database content" window appears. 10:

(11) Click "Next". The "initialization parameters" window appears. 11:

(12) Click "Next" and the "database storage" window appears. 12:

(13) Click "Next". The "create option" window appears. 13:

(14) Click "finish". The "OK" window appears. 14:

 

(15) Click "Save as HTML file" to save the details as an HTML file for future viewing.
(16) Click OK. The automatic database creation interface is displayed. 15:

 

Finally, the database creation completion window appears automatically, 16:

 

Note: Remember the information in Figure 16, such as the Database Control URL.

Click "password management". The "password management" window appears, 17:

 

In Figure 17, you can lock your account and set a new password. To ensure security, you should change the password of the default DBA account (such as SYS and SYSTEM) and lock all default accounts that are not currently needed.

Click OK to return to the database creation completion window.

Note: Remember the password you set!

(17) In the database creation completion window, click "exit" to exit DBCA. At this point, the DBCA database creation operation is complete.

After the creation, the Oracle-related server services have started the new database routines and OEM console services, 18:

 

5. Use DBCA to delete a database

(1) choose Start> program> Oracle-Oracle10g_home1> Configure and port tools> Database Configuration Assistant command to start DBCA, the welcome window appears, 1:
(2) Click "Next". The "operations" window appears, and select "delete database", 19:

(3) Click "Next". In the "Database" window, select a database to be deleted from the database list. In this example, select student, 20:

(4) Click the "finish" button. The Confirmation window is displayed, 21:

 

(5) Click "yes". The automatic database deletion process window is displayed. 22:

 

(6) The "deleted Database" window appears automatically. Click "yes" to delete the database.

The above content is all described in this article and I hope to help you.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.