A Summer Training Presentation on Oracle 10G And

Preview:

Citation preview

A SUMMER TRAINING PRESENTATION ON ORACLE 10G AND DATABASE ADMINISTRATION

Presented By:

Anil Kumar

7th Sem (Final Year)

DATABASE MANAGEMENT SYSTEM Database

A set of inter-related data acting as a central reservoir of data that can be accessed by many users

DBMSThe software that manages database. A computer-based record keeping system which consists of software for processing a collection of interrelated data.

Database AdministratorCentrally manages the database. The DBA initially studies the System and accordingly decides its various process.

ORACLE 10G-APPLICATION SERVER &DATABASE

Business intelligence

Transactional Apps

Portals

A P A C H E

Integration

MultimediaMultimedia

Object Relational DataObject Relational Data

MessagesMessages

Documents

XML

Documents

XML

ORACLE INTERNET PLATFORM

a ClientsS

yste

m m

an

ag

em

en

t

Network services

DatabasesApplication

servers

Develo

pm

en

t tools

Internet applications

Presentation andbusiness logic

Business logicand data

Any browser Any FTP clientAny mailclient

JavaJava

SQLSQL

PL/SQLPL/SQL

CODD’S RULES FOR A DATABASECODD’S RULES:- In 1970 Dr. E.F.Codd define some rules for

designing an database. These rules are following:- Information rule Gurrented access rule Systematic treatment of null values The database catalog must be relational too The system must implements a comprehensive data sublanguage Data view must be updatable High level insertion , update , delete Physical data independence Logical data independence Integrity data independence Distribution independency Non subversion

Oracle supports 111/2 Codd’s rule.

INTRODUCTION TO SQL

• SQL is used to make a request to retrieve data from a database.

• The DBMS processes the SQL request, retrieves the requested data

from the database, and returns it.

• This process of requesting data from a database and receiving back

the results is called a Database Query and hence the name

Structured Query Language.

• Efficient, easy to learn and use.

• Functionally complete.

SQL STATEMENTS

SQL AND ISQL*PLUS INTERACTION

CONTROLLING USER ACCESS

Database administrator

Users

Username and password Privileges

PRIVILEGES Database security:

- System security- Data security

System privileges: Gaining access to the database Object privileges: Manipulating the content of the database objects Schemas: Collections of objects, such as tables, views, and

sequences The database administrator has high-level system privileges for

tasks such as: Creating new users Removing users Removing tables Backing up tables

CREATING USERS & PRIVILEGES

The DBA creates users by using the CREATE USER statement.

CREATE USER user

IDENTIFIED BY password; Once a user is created, the DBA can grant specific system privileges

to a user. GRANT privilege [, privilege...]

TO user [, user| role, PUBLIC...]; An application developer, for example, may have the following

system privileges: CREATE SESSION CREATE TABLE CREATE SEQUENCE CREATE VIEW CREATE PROCEDURE

WHAT IS A ROLE?

Allocating privileges without a role

Privileges

Users

Manager

CREATING AND GRANTING PRIVILEGES TO A ROLE AND CHANGING PASSWORD

Create a roleCreate role anil;

Grant privileges to a roleGrant create table,create view to anil;

Grant a role to usersGrant anil to scott; The DBA creates your user account and initializes your password. You can change your password by using the ALTER USER statement.Alter user scott identified by tiger;

ARCHITECTURE OF ORACLE SERVER

PRIMARY COMPONENTS OF ORACLE SERVER ARCHITECTURE Oracle server: There are several files, processes and memory

structures in an oracle server, not all of them are used when processing a SQL statement. The oracle server consists of an oracle instance and an oracle database.

Oracle instance: An oracle instance is the combination of the background processes and memory structures.

Oracle database: An oracle database consists of operating system files, also known as database files that provide the actual physical storage for database information. The database files are used to ensure that the data is kept consistent and can be recovered in the event of a failure of a instance.

LOGICAL ARCHITECTURE

PROCESSING ON A SQL STATEMENT • Connect to an instance using: – The user process – The server process • The Oracle server components that are used depend on the type of

SQL statement: – Queries return rows. – DML statements log changes. – Commit ensures transaction recovery. • Some Oracle server components do not participate in SQL

statement processing. A data manipulation language (DML) statement requires only two

phases of processing, 1. Parse is the same as the parse phase used for processing a query. 2. Execute requires additional processing to make data changes.

STARTING DATABASE IN RHEL

Starting Up To start up an instance, use the following command: STARTUP [FORCE] [RESTRICT] [PFILE=filename] [OPEN [RECOVER][database] |MOUNT |NOMOUNT]

Changing the Status of the Database

To open the database from STARTUP NOMOUNT to a MOUNT stage or from MOUNT to an

ALTER DATABASE { MOUNT | OPEN } To start up an instance, use the following command:

ALTER DATABASE OPEN [READ WRITE| READ ONLY]

Opening a Database in Restricted Mode command:

ALTER SYSTEM [ {ENABLE|DISABLE} RESTRICTED SESSION ]

Terminate Sessions

ALTER SYSTEM KILL SESSION 'integer1, integer2'

SHUTTING DOWN THE DATABASE Shut down the database to make operating system offline backups of

all physical structures and to have modified static initialization parameters take effect.To shut down an instance you must connect as SYSOPER or SYSDBA and use the following

command: SHUTDOWN [NORMAL | TRANSACTIONAL | IMMEDIATE |

ABORT ]

DATABASE ADMINISTRATOR

A database administrator (DBA) is a person who is responsible for the environmental aspects of a database. In general, these include:

a) Recoverability - Creating and testing backups b) Integrity - Verifying or helping to verify data integrity c) Security - Defining and/or implementing access controls to the

data d) Performance - Ensuring maximum performance

DATABASE ADMINISTRATOR

A database administrator (DBA) is a person who is responsible for the environmental aspects of a database. In general, these include:

a) Recoverability - Creating and testing backups

b) Integrity - Verifying or helping to verify data integrity

c) Security - Defining and/or implementing access controls to the data

d) Performance - Ensuring maximum performance

THANK YOU !!!!!!!!!!!

ANY QUERIES ???????