ITeye博客

killdbs

edwards0307 · 共 36 篇文章

MANAGE TABLE

1.heap table IOT PARTITION TABLE HEAP TABLE CLUSTER 2.create table t( id number, varchar2(80), name char2(10) ) pctfree 20 pctused 40 storage( initial 180k next 180k pctincrease 10 miniextents 3 maxextents 5 ) tablespace users create global temporary table temp(id number,name char(10)); alter table…

2011-12-26 16:50 · oracle · 评论(0)

MONITOR redo size

1.set autot on stat 2.unsing v$statname,v$mystat set echo off set verify off column value new_val V define S="&1" set autotrace off select a.name, b.value from v$statname a, v$mystat b where a.statistic# = b.statistic# and lower(a.name) like '%' || lower('&S')||'%' DML operations set echo off set v…

2011-12-21 17:48 · oracle · 评论(0)

What do rollback and commit

When we COMMIT, all that is left to happen is the following: • An SCN is generated for our transaction. In case you are not familiar with it, the SCN is a simple timing mechanism Oracle uses to guarantee the ordering of transactions and to enable recovery from failure. It is also used to guarantee …

2011-12-21 11:21 · oracle · 评论(0)

What is the schema ?

A schema is a collection of database objects owned by a specific database user,or schema objects. Schema has the same name as that user,every user has a single schema,so the two terms(Schema,User) are synonymous. Schema objects include the segments(tables,indexes..etc) as we can see in the tablespa…

2011-12-20 15:18 · oracle · 评论(0)

MANAGE UNDOTABS

1.manual undo_management=manual transactions transactions_per_rollback_segment rollback_segments =('rbs1','rbs2') create rollback segment rbs1 tablespace undotbs1; privs seg create public rollback segment prbs1 tablespace undotbs1 public seg alter rollback segment rbs1 online; note: create rollback…

2011-12-19 17:15 · oracle · 评论(0)

DBA SQL

1.select a.name,b.status from v$rollname a,v$rollstat b where a.name in (select segment_name from dba_segments where tablespace_name='UNDOTBS1')and a.usn=b.usn; 2. select s.username,t.xidusn,t.ubafil,t.ubablk,t.used_ublk from v$session s,v$transaction t where s.saddr=t.ses_addr; 3.select a.tablespa…

2011-12-19 15:21 · oracle · 评论(0)

SEGMENT EXTENTS ORACLEBLOCK

1.SEGMENT: allocated for a specific data structure Oracle allocates space for segments in units of one extent. A segment and all its extents are stored in one tablespace segment can span datafiles table,index,temporary,undo 2.EXTENTS: An extent is a specific number of contiguous data blocks. Oracle…

2011-12-15 16:11 · oracle · 评论(0)

MANAGE TABLESPACE AND DATAFILES

1. tablespace,segment,extent,block tablespace: database logical is divided into more tablesapces. segment: a special storage structure(table,index),span more datafiles extents:allocate unit block: use unit,write/read unit db_block_size, default block size. standand block size,system tablespace use.…

2011-12-13 15:28 · oracle · 评论(0)

ORACLE NET

1.net_service_name: servive_name: The SERVICE_NAME is the global database name .=sid+domain net_service_name= (DESCRIPTION= (ADDRESS=(PROTOCOL=tcp)(HOST=host)(PORT=port) ) (CONNECT_DATA= (SERVICE_NAME=service_name) ) ) 2. locate port: oracle_home/install/portlist.int 3. jdbc oci driver: java appica…

2011-12-12 09:49 · oracle · 评论(0)

SQLPLUS TIPS

1.SQLPLUS : a tool that execute sql ,sqlplus ,sqlplus command. 1.sqlplus command-line cmd-sqlplus /nolog 2.sqlplus GUI sqlplusw /nolog 3.sqlplus web http://127.0.0.1:5560/isqlplus/ http://ip:5560/isqlplus/dba isqlplusctl start how to start sqlplus dba login [oracle@Toshiba ~]$ JAVA_HOME=$ORACLE_HOM…

2011-12-09 17:51 · oracle · 评论(0)

ORACLE ENVIRONMENT VARIABLES

ORACLE_HOME ORACLE_SID : oracle instance PATH: LD_LIBRARY_PATH:dynamic lib TNS_ADMIN : the location of tnsname.ora SQLPATH: the location of SQL scripts;

2011-12-09 17:15 · oracle · 评论(0)

Exam Test1

1.utl_file_dir: indicate the directory which the pl/sql packages and procedure can access and use 2.V$SHARED_POOL_RESERVED :lists statistics that help you tune the reserved pool and space within the shared pool. SHARED_POOL_RESERVED_SIZE: specifies (in bytes) the shared pool space that is reserved …

2011-12-09 16:18 · oracle · 评论(0)

MANAGE ARCHIVED REDOLOGS

1. objective: copy online redologs to offline desitination database recovery update standby database 2.change redolog mode(archive log mode) in oracle 10g startup mount alter database archivelog/noarchivelog in oracle 9i startup mount alter database archivelog/noarchivelog alter system archive log …

2011-12-08 09:31 · oracle · 评论(0)

RESUMABLE SESSION

RESUMABLE SESSION Let you enable and disable resumable space allocation. This feature allows an operation to be suspended in the event of an out-of-space error condition and to resume automatically from the point of interruption when the error condition is fixed. Using RESUMABLE Session to Avoid Tr…

2011-12-07 16:56 · oracle · 评论(0)

Managing the Redo Log

1.What Is the Redo Log? store all changes made to the database as they occur. Redo log files are filled with redo records. A redo record, also called a redo entry, is made up of a group of change vectors, describe changes to the data segment block for the table, the undo segment data block, and the…

2011-12-07 10:40 · oracle · 评论(0)