PowerPoint Presentation
Basic Database AdministrationINTRODUCTION TOPresented ByOrienITwww.orienit.com
ObjectivesDefine database administration.Understand database administration tasks.Perform database administration tasks using Oracle 11g Enterprise Manager.Understand Oracle 11g and SQL Server data storage structures.www.orienit.com
What is Database Administration?A Function information technology (IT) departmentDatabase Administrator (DBA)Overall health / PerformanceManages SecuritySetup Test and Dev. Environmentswww.orienit.com
3Duties of the DBAManage Database Objects Tables / Views / ProceduresDatabase performanceSecurity Logons /Users / Roles Clone data from Production to Development or TestManage backups and carry out DR plans.www.orienit.com
DBA Tools
www.orienit.com
DBA Tools Product ComparisonOracle 11gOracle Enterprise ManagerWeb-BasedSQL ServerSQL Server Management StudioClient-Based
www.orienit.com
Oracle Enterprise ManagerUser account must have DBA roleOracle Enterprise Manager (OEM)Three-tier architectureConsoleOracle Management Server (OMS)Interacts with repositoryMakes it easier for DBAs to administer multiple databases in organizations networkwww.orienit.com
7OEM Architecture
www.orienit.com
8Managing Oracle 11g Data StorageLike most DBMSs the logical structures TablesConstraintsViews / ProceduresCan be stored in physical data structuresFiles on diskDedicated drive partitionsRAMwww.orienit.com
9Oracle 11g Data StructuresTablespaceOne or more Data FilesSegmentPartitioned DataExtentGrowth rule for segmentData blockDatabase storage data blockOperating system blocks
www.orienit.com
10Table spacesOne or more Data files Stores all database structures + dataTables, data, views, sps etc
www.orienit.com
Datafiles.dbf extensions Store tablespace contentsStored in Oracle_Base\oradata\SIDUse OEM to view and modifyGrow via Extents
www.orienit.com
12Segments They Partition the data
www.orienit.com
13Extents Smallest unit added to data file Sequence of Data Blocks When an insert grows beyond the data file size allocation, a new extent is added.More efficient to add groups of data blocks vs. individual blocks.
www.orienit.com
Data Blocks Smallest Unit Read/Written
www.orienit.com
15Managing Oracle 11g Data StructuresCreate tablespaceManage datafile extentsAutoextensible tablespaceConfigure tablespace and datafile properties
www.orienit.com
16Oracle 11g Database File Architecture
www.orienit.com
17Parameter FileText file Specifies configuration information about Oracle 10g database instanceinit.oraStored in Oracle_Base\admin\SID\pfile folderDBAs can edit parameter file Modify database configuration
www.orienit.com
18Control FilesStore information about database structure and stateStored in Oracle_Base\oradata\SIDThree separate control files by default:CONTROL01.CTLCONTROL02.CTLCONTROL03.CTLAll contain same dataAt least one must be presentwww.orienit.com
19Redo Log FilesRecords information to undo action query changes.log extensionStored in Oracle_Base\ORADATA\SIDPre-imageRollback segment
www.orienit.com
20User Accountswww.orienit.com
Creating and Managing User AccountsCreate new user accountGeneral information about user accountSystem privileges user has in databaseUsers tablespace quota on database server
www.orienit.com
22Creating and Managing User AccountsCreate new user accountGeneral information about user accountSystem privileges user has in databaseUsers tablespace quota on database server
www.orienit.com
23Specifying General User InformationUse OEMGeneral page:NameProfileAuthenticationDefault tablespaceTemporary tablespaceStatus
www.orienit.com
24Specifying System PrivilegesSystem privilegeObject privilegeEnable new user to interact with Oracle 10g databaseDBA grants system privilegesUse System Privileges page in Create User pageAdmin Option
www.orienit.com
25Tablespace QuotasSpecifies amount of disk space that users database objects can occupy in default tablespaceMust be assignedQuota Size value:None, defaultUnlimitedValue
www.orienit.com
26Editing Existing User AccountsUse OEMSelect user account to be modified on Users pageGeneral page opensSelect other links to modify properties
www.orienit.com
27RolesDatabase object Represents collection of system privileges Assign to multiple usersCreate roleCan inherit privileges from other rolesGrant Role to User AccountEasier than manually assigning everything manually.
www.orienit.com
28Startup / Shutdownwww.orienit.com
Starting /Shutting Down the DBShut down database periodically Perform maintenanceRestart database
www.orienit.com
30Creating an Administrative ConnectionShutting down database makes database unavailable for user connectionsDBA must log onto database using administrative connectionSYS user account
www.orienit.com
31Using OEM to Shut Down and Start a Database InstanceDBA shuts down database instance using Normal, Transactional, or Immediate shutdown optionShutdown process performs five following tasks:Writes contents of data buffer cache to datafilesWrites contents of redo log buffer to redo log filesCloses all filesStops all background processesDeallocates SGA in servers main memory
www.orienit.com
32Instance OptionsStartupStart in one of two modes:UnrestrictedRestricted
ShutdownSpecify one of four ways to handle existing user connections:NormalTransactionalImmediateAbort
www.orienit.com
33Oracle 11g Database Instance States
www.orienit.com
34