Oracle Chapter One-the first knowledge of Oracle

Source: Internet
Author: User
Tags one table sqlplus

(The following system and version are basically similar to the WINDOWS7 system and other versions of Oracle11g,windows and other versions of Oracle.) )

I. INTRODUCTION of Oracle

Summary: Oracle is a relational database management system that is the core product of Oracle Corporation.

Main Features:

1, support multi-user, big event volume of transaction processing

2. Superior performance in maintaining data security and integrity

3. Support Distributed Data processing

4, with portability

II. Basic Concepts of Oracle

1. Database

Oracle is not a database, but a database management system , the database is literally understood, is the storage of data Warehouse, and Oracle is the person who manages this warehouse.

The database is physically represented as data files, log files, and control files, which are logically represented as table spaces.

2. Global database name

The global database name is the identity used to differentiate the database, consisting of the database name and domain name, making the database unique in the network environment.

3, data files, control files, log files

Data files: Data files with a. dbf extension for storing various database resources such as tables, indexes, stored procedures, views, etc.

Control file: The control file has a. ctl extension that stores the name and location of the data file and log file, which is necessary for the database to start and run.

Due to the importance of control files, Oracle has three control files by default, the contents of each control file are the same, which prevents a file from being damaged and cannot be started.

Log file: The log file has a. log extension that stores the change information for the data and improves the security of the data.

Log files in Oracle are used in groups, and each log file group can have one or more log files.

4. DB instance

Each database that is started corresponds to a DB instance in memory, which is a set of server daemon processes running through memory sharing.

5. Table Space

Oracle databases are made up of table spaces, and all of the users ' resources are in the table space. A tablespace can have multiple data files, but only one table space for a single data file.

6. Mode and Mode objects

A pattern is a collection of schema objects, which are resources (tables, indexes, stored procedures, views, and so on) in the database, each of which corresponds to a pattern.

The schema name is the same as the user name.

Third, configuration database

After the database is installed, the Oracle Installation tool automatically helps us configure the database in the current network environment, but it needs to be configured manually if the network environment changes.

Oracle provides us with a number of convenient configuration database tools, only the net configuration Assistant is described here.

Net Configuration Assistant can be opened in the Start menu → all programs →oracle name → configuration and Migration tool

1, in the server Configuration Listener (LISTENER)

Listener programs are used to listen for requests made from clients, and remote connections without a listener will error.

Open NET configuration Assistant, select Listener configuration, follow the prompts for the next step, you need to note:

(1), a listener is created by default when the database is created, so the general choice is to reconfigure it.

(2), the listener name cannot use special characters other than underscores.

(3), the protocol generally chooses the TCP protocol.

(4), the default port number is 1521, can be customized.

2. Configure the local network service name (TNSNAME) on the client

The client needs to configure the local network service name to make a request to the database.

Open NET Configuration Assistant, select the Local network service name configuration, follow the prompts for the next step, you need to note:

(1), the service name corresponds to the database instance name within the server and is not case sensitive.

(2), the protocol generally chooses the TCP protocol.

(3), host name writable server IP address, server name, localhost and 127.0.0.1

(4), port number corresponding to the port number of the listener

Iv. starting the database

Under Windows systems, Oracle Services are managed as a background service, enabling and shutting down Oracle services in the Windows Service management interface

(in daily development use, you can set several unimportant services to start manually to avoid wasting system resources).

1, Oracleservicesid

The Oracle database service, which is the name entered when the database is installed, is the core service of Oracle and must be started to use the Oracle database.

2, Oracleoradb11g_home1tnslistener

The listener service may have different names depending on the version or configuration. Need to be started when you need to connect to the database remotely, be aware that only the server uses

Oracle comes with a sql*plus connection and does not use @ when it is not considered a remote connection.

3, Oracleoradb11g_home1clragent

Part of the Oracle database. NET Extension service that can be used in Oracle. NET assemblies are packaged as stored procedures and generally do not open.

4, Oraclemtsrecoveryservice

The service-side control service, which allows the database to act as a resource manager for a Microsoft Transaction Server object and a transaction in a distributed environment, is typically not turned on.

5, Oraclejobschedulersid

Oracle Task Scheduler (timer) service, scheduling the work schedule is enabled, when enabled, it consumes a lot of system resources, generally do not open.

6, Oracledbconsolesid

Database Console service, if you want to enter the Web-based enterprise management control platform, need to start, generally do not open.

7. Oracle SID VSS Writer Service

Oracle Volume Map copy write service, which can create a mapped copy on multiple volumes or on a single volume without affecting the performance of the system, is generally not turned on.

The above is the basic Oracle service, which may also find a oracleremexecservice service when used, which is a temporary service, when it is oui used

will appear, Oui will disappear after completing the work, can ignore the service.

V. Connecting the database

There are three ways to connect to a database, using Oracle's own Sql*plus and Sqldeveloper, and using third-party tools Pl/sqldeveloper.

This article only writes out the Sql*plus connection partial way and the Pl/sqldeveloper connection, the specific connection database way can click the connection to view the connection database.

1. Connect to the database using Sql*plus

Command format: sqlplus [Username]/[password] @sid

Use example: Sqlplus scott/[email protected]

@sid can not write, do not write the default connection to the local database, and do not write @sid can not open the monitoring service.

2. Connect to the database using Pl/sqldeveloper

Pl/sqldeveloper is a third-party graphical connection tool that has more features than Sqldeveloper (but charges apply ...). )。

After the installation, directly open to log in, fill in the login information (the database option is the local service name, the role in the login user is sys need to choose to Sysdba or Sysoper).

  Both of these connections need to be configured with the local service name and enable the listening service to connect normally (excluding @).

Oracle Chapter One-the first knowledge of Oracle

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.