<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
    <title>Sky&apos; Digests</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/" />
    <link rel="self" type="application/atom+xml" href="http://www.heysky.net/digest/atom.xml" />
    <id>tag:www.heysky.net,2008-07-11:/digest//1</id>
    <updated>2009-08-27T08:42:03Z</updated>
    
    <generator uri="http://www.sixapart.com/movabletype/">Movable Type 4.261</generator>

<entry>
    <title>oracle 行列转换</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2009/08/oracle-row-column-exchange.html" />
    <id>tag:www.heysky.net,2009:/digest//1.338</id>

    <published>2009-08-27T08:38:35Z</published>
    <updated>2009-08-27T08:42:03Z</updated>

    <summary>From: http://blog.csdn.net/you_tube/archive/2009/04/09/4059251.aspx1.概述最近论坛很多人提的问题都与行列转换有关系，所以我对行列转换的相关知识做了一个总结，希望对大家有所帮助，同时有何错疏，恳请大家指出，我也是在写作过程中学习，算是一起和大家学习吧！行列转换包括以下六种情况：1)列转行2)行转列3)多列转换成字符串4)多行转换成字符串5)字符串转换成多列6)字符串转换成多行下面分别进行举例介绍。首先声明一点，有些例子需要如下10g及以后才有的知识：A.掌握model子句B.正则表达式C.加强的层次查询讨论的适用范围只包括8i,9i,10g及以后版本。2.列转行CREATE TABLE t_col_row(ID INT,c1 VARCHAR2(10),c2 VARCHAR2(10),c3 VARCHAR2(10));INSERT INTO t_col_row VALUES (1, &apos;v11&apos;, &apos;v21&apos;, &apos;v31&apos;);INSERT INTO t_col_row VALUES (2, &apos;v12&apos;, &apos;v22&apos;, NULL);INSERT INTO t_col_row VALUES (3, &apos;v13&apos;, NULL, &apos;v33&apos;);INSERT INTO t_col_row VALUES (4, NULL, &apos;v24&apos;, &apos;v34&apos;);INSERT INTO t_col_row VALUES (5,...</summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Databases" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="plsql" label="pl/sql" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="行列转换" label="行列转换" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<i>From: http://blog.csdn.net/you_tube/archive/2009/04/09/4059251.aspx</i><br /><br />1.<br />概述<br />最近论坛很多人提的问题都与行列转换有关系，所以我对行列转换的相关知识做了一个总结，希望对大家有所帮助，同时有何错疏，恳请大家指出，我也是在写作过程中学习，算是一起和大家学习吧！<br />行列转换包括以下六种情况：<br />1)<br />列转行<br />2)<br />行转列<br />3)<br />多列转换成字符串<br />4)<br />多行转换成字符串<br />5)<br />字符串转换成多列<br />6)<br />字符串转换成多行<br />下面分别进行举例介绍。<br />首先声明一点，有些例子需要如下10g及以后才有的知识：<br />A.<br />掌握model子句<br />B.<br />正则表达式<br />C.<br />加强的层次查询<br />讨论的适用范围只包括8i,9i,10g及以后版本。<br />2.<br />列转行<br />CREATE TABLE t_col_row(<br />ID INT,<br />c1 VARCHAR2(10),<br />c2 VARCHAR2(10),<br />c3 VARCHAR2(10));<br />INSERT INTO t_col_row VALUES (1, 'v11', 'v21', 'v31');<br />INSERT INTO t_col_row VALUES (2, 'v12', 'v22', NULL);<br />INSERT INTO t_col_row VALUES (3, 'v13', NULL, 'v33');<br />INSERT INTO t_col_row VALUES (4, NULL, 'v24', 'v34');<br />INSERT INTO t_col_row VALUES (5, 'v15', NULL, NULL);<br />INSERT INTO t_col_row VALUES (6, NULL, NULL, 'v35');<br />INSERT INTO t_col_row VALUES (7, NULL, NULL, NULL);<br />COMMIT;<br />SELECT * FROM t_col_row;<br />2.1<br />UNION ALL<br />适用范围：8i,9i,10g及以后版本<br />SELECT id, 'c1' cn, c1 cv<br />FROM t_col_row<br />UNION ALL<br />SELECT id, 'c2' cn, c2 cv<br />FROM t_col_row<br />UNION ALL<br />SELECT id, 'c3' cn, c3 cv FROM t_col_row;<br />若空行不需要转换，只需加一个where条件，<br />WHERE COLUMN IS NOT NULL 即可。<br />2.2<br />MODEL<br />适用范围：10g及以后<br />SELECT id, cn, cv FROM t_col_row<br />MODEL<br />RETURN UPDATED ROWS<br />PARTITION BY (ID)<br />DIMENSION BY (0 AS n)<br />MEASURES ('xx' AS cn,'yyy' AS cv,c1,c2,c3)<br />RULES UPSERT ALL<br />(<br />cn[1] = 'c1',<br />cn[2] = 'c2',<br />cn[3] = 'c3',<br />cv[1] = c1[0],<br />cv[2] = c2[0],<br />cv[3] = c3[0]<br />)<br />ORDER BY ID,cn;<br />2.3<br />COLLECTION<br />适用范围：8i,9i,10g及以后版本<br />要创建一个对象和一个集合：<br />CREATE TYPE cv_pair AS OBJECT(cn VARCHAR2(10),cv VARCHAR2(10));<br />CREATE TYPE cv_varr AS VARRAY(8) OF cv_pair;<br />SELECT id, t.cn AS cn, t.cv AS cv<br />FROM t_col_row,<br />TABLE(cv_varr(cv_pair('c1', t_col_row.c1),<br />cv_pair('c2', t_col_row.c2),<br />cv_pair('c3', t_col_row.c3))) t<br />ORDER BY 1, 2;<br /><br /> ]]>
        <![CDATA[3.<br />
行转列<br />
CREATE TABLE t_row_col AS<br />
SELECT id, 'c1' cn, c1 cv<br />
FROM t_col_row<br />
UNION ALL<br />
SELECT id, 'c2' cn, c2 cv<br />
FROM t_col_row<br />
UNION ALL<br />
SELECT id, 'c3' cn, c3 cv FROM t_col_row;<br />
SELECT * FROM t_row_col ORDER BY 1,2;<br />
3.1<br />
AGGREGATE FUNCTION<br />
适用范围：8i,9i,10g及以后版本<br />
SELECT id,<br />
MAX(decode(cn, 'c1', cv, NULL)) AS c1,<br />
MAX(decode(cn, 'c2', cv, NULL)) AS c2,<br />
MAX(decode(cn, 'c3', cv, NULL)) AS c3<br />
FROM t_row_col<br />
GROUP BY id<br />
ORDER BY 1;<br />
MAX聚集函数也可以用sum、min、avg等其他聚集函数替代。<br />
被指定的转置列只能有一列，但固定的列可以有多列，请看下面的例子：<br />
SELECT mgr, deptno, empno, ename FROM emp ORDER BY 1, 2;<br />
SELECT mgr,<br />
deptno,<br />
MAX(decode(empno, '7788', ename, NULL)) "7788",<br />
MAX(decode(empno, '7902', ename, NULL)) "7902",<br />
MAX(decode(empno, '7844', ename, NULL)) "7844",<br />
MAX(decode(empno, '7521', ename, NULL)) "7521",<br />
MAX(decode(empno, '7900', ename, NULL)) "7900",<br />
MAX(decode(empno, '7499', ename, NULL)) "7499",<br />
MAX(decode(empno, '7654', ename, NULL)) "7654"<br />
FROM emp<br />
WHERE mgr IN (7566, 7698)<br />
AND deptno IN (20, 30)<br />
GROUP BY mgr, deptno<br />
ORDER BY 1, 2;<br />
这里转置列为empno，固定列为mgr，deptno。<br />
还有一种行转列的方式，就是相同组中的行值变为单个列值，但转置的行值不变为列名：<br />
ID CN_1 CV_1 CN_2 CV_2 CN_3 CV_3<br />
1 c1 v11 c2 v21 c3 v31<br />
2 c1 v12 c2 v22 c3<br />
3 c1 v13 c2 c3 v33<br />
4 c1 c2 v24 c3 v34<br />
5 c1 v15 c2 c3<br />
6 c1 c2 c3 v35<br />
7 c1 c2 c3<br />
这种情况可以用分析函数实现：<br />
SELECT id,<br />
MAX(decode(rn, 1, cn, NULL)) cn_1,<br />
MAX(decode(rn, 1, cv, NULL)) cv_1,<br />
MAX(decode(rn, 2, cn, NULL)) cn_2,<br />
MAX(decode(rn, 2, cv, NULL)) cv_2,<br />
MAX(decode(rn, 3, cn, NULL)) cn_3,<br />
MAX(decode(rn, 3, cv, NULL)) cv_3<br />
FROM (SELECT id,<br />
cn,<br />
cv,<br />
row_number() over(PARTITION BY id ORDER BY cn, cv) rn<br />
FROM t_row_col)<br />
GROUP BY ID;<br />
3.2<br />
PL/SQL<br />
适用范围：8i,9i,10g及以后版本<br />
这种对于行值不固定的情况可以使用。<br />
下面是我写的一个包，包中<br />
p_rows_column_real用于前述的第一种不限定列的转换；<br />
p_rows_column用于前述的第二种不限定列的转换。<br />
CREATE OR REPLACE PACKAGE pkg_dynamic_rows_column AS<br />
TYPE refc IS REF CURSOR;<br />
PROCEDURE p_print_sql(p_txt VARCHAR2);<br />
FUNCTION f_split_str(p_str VARCHAR2, p_division VARCHAR2, p_seq INT)<br />
RETURN VARCHAR2;<br />
PROCEDURE p_rows_column(p_table IN VARCHAR2,<br />
p_keep_cols IN VARCHAR2,<br />
p_pivot_cols IN VARCHAR2,<br />
p_where IN VARCHAR2 DEFAULT NULL,<br />
p_refc IN OUT refc);<br />
PROCEDURE p_rows_column_real(p_table IN VARCHAR2,<br />
p_keep_cols IN VARCHAR2,<br />
p_pivot_col IN VARCHAR2,<br />
p_pivot_val IN VARCHAR2,<br />
p_where IN VARCHAR2 DEFAULT NULL,<br />
p_refc IN OUT refc);<br />
END;<br />
/<br />
CREATE OR REPLACE PACKAGE BODY pkg_dynamic_rows_column AS<br />
PROCEDURE p_print_sql(p_txt VARCHAR2) IS<br />
v_len INT;<br />
BEGIN<br />
v_len := length(p_txt);<br />
FOR i IN 1 .. v_len / 250 + 1 LOOP<br />
dbms_output.put_line(substrb(p_txt, (i - 1) * 250 + 1, 250));<br />
END LOOP;<br />
END;<br />
FUNCTION f_split_str(p_str VARCHAR2, p_division VARCHAR2, p_seq INT)<br />
RETURN VARCHAR2 IS<br />
v_first INT;<br />
v_last INT;<br />
BEGIN<br />
IF p_seq &lt; 1 THEN<br />
RETURN NULL;<br />
END IF;<br />
IF p_seq = 1 THEN<br />
IF instr(p_str, p_division, 1, p_seq) = 0 THEN<br />
RETURN p_str;<br />
ELSE<br />
RETURN substr(p_str, 1, instr(p_str, p_division, 1) - 1);<br />
END IF;<br />
ELSE<br />
v_first := instr(p_str, p_division, 1, p_seq - 1);<br />
v_last := instr(p_str, p_division, 1, p_seq);<br />
IF (v_last = 0) THEN<br />
IF (v_first &gt; 0) THEN<br />
RETURN substr(p_str, v_first + 1);<br />
ELSE<br />
RETURN NULL;<br />
END IF;<br />
ELSE<br />
RETURN substr(p_str, v_first + 1, v_last - v_first - 1);<br />
END IF;<br />
END IF;<br />
END f_split_str;<br />
PROCEDURE p_rows_column(p_table IN VARCHAR2,<br />
p_keep_cols IN VARCHAR2,<br />
p_pivot_cols IN VARCHAR2,<br />
p_where IN VARCHAR2 DEFAULT NULL,<br />
p_refc IN OUT refc) IS<br />
v_sql VARCHAR2(4000);<br />
TYPE v_keep_ind_by IS TABLE OF VARCHAR2(4000) INDEX BY BINARY_INTEGER;<br />
v_keep v_keep_ind_by;<br />
TYPE v_pivot_ind_by IS TABLE OF VARCHAR2(4000) INDEX BY BINARY_INTEGER;<br />
v_pivot v_pivot_ind_by;<br />
v_keep_cnt INT;<br />
v_pivot_cnt INT;<br />
v_max_cols INT;<br />
v_partition VARCHAR2(4000);<br />
v_partition1 VARCHAR2(4000);<br />
v_partition2 VARCHAR2(4000);<br />
BEGIN<br />
v_keep_cnt := length(p_keep_cols) - length(REPLACE(p_keep_cols, ',')) + 1;<br />
v_pivot_cnt := length(p_pivot_cols) -<br />
length(REPLACE(p_pivot_cols, ',')) + 1;<br />
FOR i IN 1 .. v_keep_cnt LOOP<br />
v_keep(i) := f_split_str(p_keep_cols, ',', i);<br />
END LOOP;<br />
FOR j IN 1 .. v_pivot_cnt LOOP<br />
v_pivot(j) := f_split_str(p_pivot_cols, ',', j);<br />
END LOOP;<br />
v_sql := 'select max(count(*)) from ' || p_table || ' group by ';<br />
FOR i IN 1 .. v_keep.LAST LOOP<br />
v_sql := v_sql || v_keep(i) || ',';<br />
END LOOP;<br />
v_sql := rtrim(v_sql, ',');<br />
EXECUTE IMMEDIATE v_sql<br />
INTO v_max_cols;<br />
v_partition := 'select ';<br />
FOR x IN 1 .. v_keep.COUNT LOOP<br />
v_partition1 := v_partition1 || v_keep(x) || ',';<br />
END LOOP;<br />
FOR y IN 1 .. v_pivot.COUNT LOOP<br />
v_partition2 := v_partition2 || v_pivot(y) || ',';<br />
END LOOP;<br />
v_partition1 := rtrim(v_partition1, ',');<br />
v_partition2 := rtrim(v_partition2, ',');<br />
v_partition := v_partition || v_partition1 || ',' || v_partition2 ||<br />
', row_number() over (partition by ' || v_partition1 ||<br />
' order by ' || v_partition2 || ') rn from ' || p_table;<br />
v_partition := rtrim(v_partition, ',');<br />
v_sql := 'select ';<br />
FOR i IN 1 .. v_keep.COUNT LOOP<br />
v_sql := v_sql || v_keep(i) || ',';<br />
END LOOP;<br />
FOR i IN 1 .. v_max_cols LOOP<br />
FOR j IN 1 .. v_pivot.COUNT LOOP<br />
v_sql := v_sql || ' max(decode(rn,' || i || ',' || v_pivot(j) ||<br />
',null))' || v_pivot(j) || '_' || i || ',';<br />
END LOOP;<br />
END LOOP;<br />
IF p_where IS NOT NULL THEN<br />
v_sql := rtrim(v_sql, ',') || ' from (' || v_partition || ' ' ||<br />
p_where || ') group by ';<br />
ELSE<br />
v_sql := rtrim(v_sql, ',') || ' from (' || v_partition ||<br />
') group by ';<br />
END IF;<br />
FOR i IN 1 .. v_keep.COUNT LOOP<br />
v_sql := v_sql || v_keep(i) || ',';<br />
END LOOP;<br />
v_sql := rtrim(v_sql, ',');<br />
p_print_sql(v_sql);<br />
OPEN p_refc FOR v_sql;<br />
EXCEPTION<br />
WHEN OTHERS THEN<br />
OPEN p_refc FOR<br />
SELECT 'x' FROM dual WHERE 0 = 1;<br />
END;<br />
PROCEDURE p_rows_column_real(p_table IN VARCHAR2,<br />
p_keep_cols IN VARCHAR2,<br />
p_pivot_col IN VARCHAR2,<br />
p_pivot_val IN VARCHAR2,<br />
p_where IN VARCHAR2 DEFAULT NULL,<br />
p_refc IN OUT refc) IS<br />
v_sql VARCHAR2(4000);<br />
TYPE v_keep_ind_by IS TABLE OF VARCHAR2(4000) INDEX BY BINARY_INTEGER;<br />
v_keep v_keep_ind_by;<br />
TYPE v_pivot_ind_by IS TABLE OF VARCHAR2(4000) INDEX BY BINARY_INTEGER;<br />
v_pivot v_pivot_ind_by;<br />
v_keep_cnt INT;<br />
v_group_by VARCHAR2(2000);<br />
BEGIN<br />
v_keep_cnt := length(p_keep_cols) - length(REPLACE(p_keep_cols, ',')) + 1;<br />
FOR i IN 1 .. v_keep_cnt LOOP<br />
v_keep(i) := f_split_str(p_keep_cols, ',', i);<br />
END LOOP;<br />
v_sql := 'select ' || 'cast(' || p_pivot_col ||<br />
' as varchar2(200)) as ' || p_pivot_col || ' from ' || p_table ||<br />
' group by ' || p_pivot_col;<br />
EXECUTE IMMEDIATE v_sql BULK COLLECT<br />
INTO v_pivot;<br />
FOR i IN 1 .. v_keep.COUNT LOOP<br />
v_group_by := v_group_by || v_keep(i) || ',';<br />
END LOOP;<br />
v_group_by := rtrim(v_group_by, ',');<br />
v_sql := 'select ' || v_group_by || ',';<br />
FOR x IN 1 .. v_pivot.COUNT LOOP<br />
v_sql := v_sql || ' max(decode(' || p_pivot_col || ',' || chr(39) ||<br />
v_pivot(x) || chr(39) || ',' || p_pivot_val ||<br />
',null)) as "' || v_pivot(x) || '",';<br />
END LOOP;<br />
v_sql := rtrim(v_sql, ',');<br />
IF p_where IS NOT NULL THEN<br />
v_sql := v_sql || ' from ' || p_table || p_where || ' group by ' ||<br />
v_group_by;<br />
ELSE<br />
v_sql := v_sql || ' from ' || p_table || ' group by ' || v_group_by;<br />
END IF;<br />
p_print_sql(v_sql);<br />
OPEN p_refc FOR v_sql;<br />
EXCEPTION<br />
WHEN OTHERS THEN<br />
OPEN p_refc FOR<br />
SELECT 'x' FROM dual WHERE 0 = 1;<br />
END;<br />
END;<br />
/<br />
4.<br />
多列转换成字符串<br />
CREATE TABLE t_col_str AS<br />
SELECT * FROM t_col_row;<br />
这个比较简单，用||或concat函数可以实现：<br />
SELECT concat('a','b') FROM dual;<br />
4.1<br />
|| OR CONCAT<br />
适用范围：8i,9i,10g及以后版本<br />
SELECT * FROM t_col_str;<br />
SELECT ID,c1||','||c2||','||c3 AS c123<br />
FROM t_col_str;<br />
5.<br />
多行转换成字符串<br />
CREATE TABLE t_row_str(<br />
ID INT,<br />
col VARCHAR2(10));<br />
INSERT INTO t_row_str VALUES(1,'a');<br />
INSERT INTO t_row_str VALUES(1,'b');<br />
INSERT INTO t_row_str VALUES(1,'c');<br />
INSERT INTO t_row_str VALUES(2,'a');<br />
INSERT INTO t_row_str VALUES(2,'d');<br />
INSERT INTO t_row_str VALUES(2,'e');<br />
INSERT INTO t_row_str VALUES(3,'c');<br />
COMMIT;<br />
SELECT * FROM t_row_str;<br />
5.1<br />
MAX + DECODE<br />
适用范围：8i,9i,10g及以后版本<br />
SELECT id,<br />
MAX(decode(rn, 1, col, NULL)) ||<br />
MAX(decode(rn, 2, ',' || col, NULL)) ||<br />
MAX(decode(rn, 3, ',' || col, NULL)) str<br />
FROM (SELECT id,<br />
col,<br />
row_number() over(PARTITION BY id ORDER BY col) AS rn<br />
FROM t_row_str) t<br />
GROUP BY id<br />
ORDER BY 1;<br />
5.2<br />
ROW_NUMBER + LEAD<br />
适用范围：8i,9i,10g及以后版本<br />
SELECT id, str<br />
FROM (SELECT id,<br />
row_number() over(PARTITION BY id ORDER BY col) AS rn,<br />
col || lead(',' || col, 1) over(PARTITION BY id ORDER BY col) ||<br />
lead(',' || col, 2) over(PARTITION BY id ORDER BY col) ||<br />
lead(',' || col, 3) over(PARTITION BY id ORDER BY col) AS str<br />
FROM t_row_str)<br />
WHERE rn = 1<br />
ORDER BY 1;<br />
5.3<br />
MODEL<br />
适用范围：10g及以后版本<br />
SELECT id, substr(str, 2) str FROM t_row_str<br />
MODEL<br />
RETURN UPDATED ROWS<br />
PARTITION BY(ID)<br />
DIMENSION BY(row_number() over(PARTITION BY ID ORDER BY col) AS rn)<br />
MEASURES (CAST(col AS VARCHAR2(20)) AS str)<br />
RULES UPSERT<br />
ITERATE(3) UNTIL( presentv(str[iteration_number+2],1,0)=0)<br />
(str[0] = str[0] || ',' || str[iteration_number+1])<br />
ORDER BY 1;<br />
5.4<br />
SYS_CONNECT_BY_PATH<br />
适用范围：8i,9i,10g及以后版本<br />
SELECT t.id id, MAX(substr(sys_connect_by_path(t.col, ','), 2)) str<br />
FROM (SELECT id, col, row_number() over(PARTITION BY id ORDER BY col) rn<br />
FROM t_row_str) t<br />
START WITH rn = 1<br />
CONNECT BY rn = PRIOR rn + 1<br />
AND id = PRIOR id<br />
GROUP BY t.id;<br />
适用范围：10g及以后版本<br />
SELECT t.id id, substr(sys_connect_by_path(t.col, ','), 2) str<br />
FROM (SELECT id, col, row_number() over(PARTITION BY id ORDER BY col) rn<br />
FROM t_row_str) t<br />
WHERE connect_by_isleaf = 1<br />
START WITH rn = 1<br />
CONNECT BY rn = PRIOR rn + 1<br />
AND id = PRIOR id;<br />
5.5<br />
WMSYS.WM_CONCAT<br />
适用范围：10g及以后版本<br />
这个函数预定义按','分隔字符串，若要用其他符号分隔可以用，replace将','替换。<br />
SELECT id, REPLACE(wmsys.wm_concat(col), ',', '/') str<br />
FROM t_row_str<br />
GROUP BY id;<br />
6.<br />
字符串转换成多列<br />
其实际上就是一个字符串拆分的问题。<br />
CREATE TABLE t_str_col AS<br />
SELECT ID,c1||','||c2||','||c3 AS c123<br />
FROM t_col_str;<br />
SELECT * FROM t_str_col;<br />
6.1<br />
SUBSTR + INSTR<br />
适用范围：8i,9i,10g及以后版本<br />
SELECT id,<br />
c123,<br />
substr(c123, 1, instr(c123 || ',', ',', 1, 1) - 1) c1,<br />
substr(c123,<br />
instr(c123 || ',', ',', 1, 1) + 1,<br />
instr(c123 || ',', ',', 1, 2) - instr(c123 || ',', ',', 1, 1) - 1) c2,<br />
substr(c123,<br />
instr(c123 || ',', ',', 1, 2) + 1,<br />
instr(c123 || ',', ',', 1, 3) - instr(c123 || ',', ',', 1, 2) - 1) c3<br />
FROM t_str_col<br />
ORDER BY 1;<br />
6.2<br />
REGEXP_SUBSTR<br />
适用范围：10g及以后版本<br />
SELECT id,<br />
c123,<br />
rtrim(regexp_substr(c123 || ',', '.*?' || ',', 1, 1), ',') AS c1,<br />
rtrim(regexp_substr(c123 || ',', '.*?' || ',', 1, 2), ',') AS c2,<br />
rtrim(regexp_substr(c123 || ',', '.*?' || ',', 1, 3), ',') AS c3<br />
FROM t_str_col<br />
ORDER BY 1;<br />
7.<br />
字符串转换成多行<br />
CREATE TABLE t_str_row AS<br />
SELECT id,<br />
MAX(decode(rn, 1, col, NULL)) ||<br />
MAX(decode(rn, 2, ',' || col, NULL)) ||<br />
MAX(decode(rn, 3, ',' || col, NULL)) str<br />
FROM (SELECT id,<br />
col,<br />
row_number() over(PARTITION BY id ORDER BY col) AS rn<br />
FROM t_row_str) t<br />
GROUP BY id<br />
ORDER BY 1;<br />
SELECT * FROM t_str_row;<br />
7.1<br />
UNION ALL<br />
适用范围：8i,9i,10g及以后版本<br />
SELECT id, 1 AS p, substr(str, 1, instr(str || ',', ',', 1, 1) - 1) AS cv<br />
FROM t_str_row<br />
UNION ALL<br />
SELECT id,<br />
2 AS p,<br />
substr(str,<br />
instr(str || ',', ',', 1, 1) + 1,<br />
instr(str || ',', ',', 1, 2) - instr(str || ',', ',', 1, 1) - 1) AS cv<br />
FROM t_str_row<br />
UNION ALL<br />
SELECT id,<br />
3 AS p,<br />
substr(str,<br />
instr(str || ',', ',', 1, 1) + 1,<br />
instr(str || ',', ',', 1, 2) - instr(str || ',', ',', 1, 1) - 1) AS cv<br />
FROM t_str_row<br />
ORDER BY 1, 2;<br />
适用范围：10g及以后版本<br />
SELECT id, 1 AS p, rtrim(regexp_substr(str||',', '.*?' || ',', 1, 1), ',') AS cv<br />
FROM t_str_row<br />
UNION ALL<br />
SELECT id, 2 AS p, rtrim(regexp_substr(str||',', '.*?' || ',', 1, 2), ',') AS cv<br />
FROM t_str_row<br />
UNION ALL<br />
SELECT id, 3 AS p, rtrim(regexp_substr(str||',', '.*?' || ',',1,3), ',') AS cv<br />
FROM t_str_row<br />
ORDER BY 1, 2;<br />
7.2<br />
VARRAY<br />
适用范围：8i,9i,10g及以后版本<br />
要创建一个可变数组：<br />
CREATE OR REPLACE TYPE ins_seq_type IS VARRAY(8) OF NUMBER;<br />
SELECT * FROM TABLE(ins_seq_type(1, 2, 3, 4, 5));<br />
SELECT t.id,<br />
c.column_value AS p,<br />
substr(t.ca,<br />
instr(t.ca, ',', 1, c.column_value) + 1,<br />
instr(t.ca, ',', 1, c.column_value + 1) -<br />
(instr(t.ca, ',', 1, c.column_value) + 1)) AS cv<br />
FROM (SELECT id,<br />
',' || str || ',' AS ca,<br />
length(str || ',') - nvl(length(REPLACE(str, ',')), 0) AS cnt<br />
FROM t_str_row) t<br />
INNER JOIN TABLE(ins_seq_type(1, 2, 3)) c ON c.column_value &lt;=<br />
t.cnt<br />
ORDER BY 1, 2;<br />
7.3<br />
SEQUENCE SERIES<br />
这类方法主要是要产生一个连续的整数列，产生连续整数列的方法有很多，主要有：<br />
CONNECT BY,ROWNUM+all_objects,CUBE等。<br />
适用范围：8i,9i,10g及以后版本<br />
SELECT t.id,<br />
c.lv AS p,<br />
substr(t.ca,<br />
instr(t.ca, ',', 1, c.lv) + 1,<br />
instr(t.ca, ',', 1, c.lv + 1) -<br />
(instr(t.ca, ',', 1, c.lv) + 1)) AS cv<br />
FROM (SELECT id,<br />
',' || str || ',' AS ca,<br />
length(str || ',') - nvl(length(REPLACE(str, ',')), 0) AS cnt<br />
FROM t_str_row) t,<br />
(SELECT LEVEL lv FROM dual CONNECT BY LEVEL &lt;= 5) c<br />
WHERE c.lv &lt;= t.cnt<br />
ORDER BY 1, 2;<br />
SELECT t.id,<br />
c.rn AS p,<br />
substr(t.ca,<br />
instr(t.ca, ',', 1, c.rn) + 1,<br />
instr(t.ca, ',', 1, c.rn + 1) -<br />
(instr(t.ca, ',', 1, c.rn) + 1)) AS cv<br />
FROM (SELECT id,<br />
',' || str || ',' AS ca,<br />
length(str || ',') - nvl(length(REPLACE(str, ',')), 0) AS cnt<br />
FROM t_str_row) t,<br />
(SELECT rownum rn FROM all_objects WHERE rownum &lt;= 5) c<br />
WHERE c.rn &lt;= t.cnt<br />
ORDER BY 1, 2;<br />
SELECT t.id,<br />
c.cb AS p,<br />
substr(t.ca,<br />
instr(t.ca, ',', 1, c.cb) + 1,<br />
instr(t.ca, ',', 1, c.cb + 1) -<br />
(instr(t.ca, ',', 1, c.cb) + 1)) AS cv<br />
FROM (SELECT id,<br />
',' || str || ',' AS ca,<br />
length(str || ',') - nvl(length(REPLACE(str, ',')), 0) AS cnt<br />
FROM t_str_row) t,<br />
(SELECT rownum cb FROM (SELECT 1 FROM dual GROUP BY CUBE(1, 2))) c<br />
WHERE c.cb &lt;= t.cnt<br />
ORDER BY 1, 2;<br />
适用范围：10g及以后版本<br />
SELECT t.id,<br />
c.lv AS p,<br />
rtrim(regexp_substr(t.str || ',', '.*?' || ',', 1, c.lv), ',') AS cv<br />
FROM (SELECT id,<br />
str,<br />
length(regexp_replace(str || ',', '[^' || ',' || ']', NULL)) AS cnt<br />
FROM t_str_row) t<br />
INNER JOIN (SELECT LEVEL lv FROM dual CONNECT BY LEVEL &lt;= 5) c ON c.lv &lt;= t.cnt<br />
ORDER BY 1, 2;<br />
7.4<br />
HIERARCHICAL + DBMS_RANDOM<br />
适用范围：10g及以后版本<br />
SELECT id,<br />
LEVEL AS p,<br />
rtrim(regexp_substr(str || ',', '.*?' || ',', 1, LEVEL), ',') AS cv<br />
FROM t_str_row<br />
CONNECT BY id = PRIOR id<br />
AND PRIOR dbms_random.VALUE IS NOT NULL<br />
AND LEVEL &lt;=<br />
length(regexp_replace(str || ',', '[^' || ',' || ']', NULL))<br />
ORDER BY 1, 2;<br />
7.5<br />
HIERARCHICAL + CONNECT_BY_ROOT<br />
适用范围：10g及以后版本<br />
SELECT id,<br />
LEVEL AS p,<br />
rtrim(regexp_substr(str || ',', '.*?' || ',', 1, LEVEL), ',') AS cv<br />
FROM t_str_row<br />
CONNECT BY id = connect_by_root id<br />
AND LEVEL &lt;=<br />
length(regexp_replace(str || ',', '[^' || ',' || ']', NULL))<br />
ORDER BY 1, 2;<br />
7.6<br />
MODEL<br />
适用范围：10g及以后版本<br />
SELECT id, p, cv FROM t_str_row<br />
MODEL<br />
RETURN UPDATED ROWS<br />
PARTITION BY(ID)<br />
DIMENSION BY( 0 AS p)<br />
MEASURES( str||',' AS cv)<br />
RULES UPSERT<br />
(cv<br />
[ FOR p<br />
FROM 1 TO length(regexp_replace(cv[0],'[^'||','||']',null))]]>
    </content>
</entry>

<entry>
    <title>On Tuning by Tracing</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2009/07/on-tuning-by-tracing.html" />
    <id>tag:www.heysky.net,2009:/digest//1.337</id>

    <published>2009-07-31T08:21:41Z</published>
    <updated>2009-07-31T08:29:52Z</updated>

    <summary>From: http://www.oracle.com/technology/oramag/oracle/08-jan/o18asktom.htmlOn Tuning by Tracing By Tom Kyte Our technologist does a tune-up with SQL_TRACE. My all-time favorite presentation is called &quot;All About Binds.&quot; It takes me about three hours to do the entire talk--which covers performance, memory utilization, scalability,...</summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Databases" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="asktom" label="asktom" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="bind" label="bind" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="histogram" label="histogram" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="parse" label="parse" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="peeking" label="peeking" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="trace" label="trace" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<i>From: <a href="http://www.oracle.com/technology/oramag/oracle/08-jan/o18asktom.html">http://www.oracle.com/technology/oramag/oracle/08-jan/o18asktom.html</a></i><br /><br /><span class="topstoryhead">On Tuning by Tracing </span><br />
<span class="italicbodycopy">By Tom Kyte <img src="http://www.oracle.com/technology/admin/images/ace_2.gif" alt="Oracle ACE" height="12" width="12" /></span>

<p>
<span class="boldbodycopy">Our technologist does a tune-up with SQL_TRACE. </span>
</p>
<p>
<span class="bodycopy">My all-time favorite presentation is called "All
About Binds." It takes me about three hours to do the entire talk--which
covers performance, memory utilization, scalability, security, bind
mismatches, bind variable peeking, and cursor sharing--from start to
finish. </span>
</p>
<p>
<span class="bodycopy">Today, I got this message on <a href="http://asktom.oracle.com/" target="_blank"><span class="bodylink">Ask Tom</span></a>:</span>
</p>
<p>
<span class="boldbodycopy">I have a query that runs slowly (it takes
about two minutes). So what do I do? I turn on tracing (SQL_TRACE=TRUE)
before running the query, and consistently, 100 percent of the time,
without my changing anything else, when I enable tracing the query
comes back instantly!</span>
</p>
<p>
<span class="bodycopy">This message on Ask Tom shows exactly what I
demonstrate in the "All About Binds" presentation, during which I say,
"I'm going to show you how to tune by setting SQL_TRACE=TRUE. You are
probably all thinking that I'm going to run a query, observe it running
slowly, trace it, and then tune it. Well, I'm not going to do that--all
I'm going to do is set SQL_TRACE=TRUE, and you'll observe that the
query performance and resource utilization are dramatically
affected--all for the better!"</span>
</p>
<p>
<span class="bodycopy">I know exactly what is happening in the Ask Tom scenario--it is a combination of two things:</span>
</p>
<p>
</p><ul><li><span class="bodycopy"> When you set SQL_TRACE=TRUE, you set up a
new "parse environment" (a made-up term). You have changed your session
in such a way that it will </span><span class="italicbodycopy">not</span><span class="bodycopy">
share any existing SQL that was not parsed with SQL_TRACE enabled. So
it is highly likely that you will either hard-parse a new version of
the query or use some existing child cursor that is different from the
one you would use with SQL_TRACE disabled. </span></li><p>
</p><li><span class="bodycopy"> Bind variable peeking happens at hard-parse time and may affect the plan chosen by the optimizer.</span></li></ul><br />]]>
        <![CDATA[<p>
<span class="bodycopy">Let's start with the setup script to demonstrate this phenomenon. I'll set up a very skewed set of data for emphasis:</span>
</p>

<p>
</p>
<pre>SQL&gt; create table t<br />  2    as<br />  3    select case when rownum = 1 <br />  4    then 1 else 99 end id, a.* <br />  5      from all_objects a<br />  6    /<br />Table created.<br /><br />SQL&gt; create index t_idx on t(id);<br />Index created.<br /><br />SQL&gt; begin<br />  2    dbms_stats.gather_table_stats<br />  3    ( user, 'T',<br />  4     method_opt=&gt; <br />  5    'for all'|| <br />  6    'indexed columns'|| <br />  7    'size 254' );<br />  8    end; <br />  9    /<br />PL/SQL procedure successfully completed.<br /></pre>


<p>
<span class="bodycopy">It is quite clear that WHERE ID=1 will return
one record and WHERE ID=99 will return all of the rest (about 50,000
records). Also, the optimizer is very aware of this fact, because of
the histograms in place, and if we parse by using literals, we can
definitely see different plans for different inputs, as shown in
Listing 1. </span>
</p>

<p>
<span class="boldbodycopy">Code Listing 1:</span> <span class="bodycopy">Different inputs, different plans</span>
</p>

<p>
</p>
<pre>SQL&gt; set autotrace traceonly explain<br />SQL&gt; select * from t where id = 1;<br /><br />Execution Plan<br />-------------------------------------------------------------------------------------------------------<br />|  Id  |  Operation                          |  Name  |  Rows  |  Bytes  |  Cost (%CPU)  |  Time      |<br />-------------------------------------------------------------------------------------------------------<br />|   0  |  SELECT STATEMENT                   |        |      1 |      96 |      2   (0)  |  00:00:01  |<br />|   1  |    TABLE ACCESS BY INDEX ROWID      | T      |      1 |      96 |      2   (0)  |  00:00:01  |<br />|*  2  |      INDEX RANGE SCAN               | T_IDX  |      1 |         |      1   (0)  |  00:00:01  |<br />-------------------------------------------------------------------------------------------------------<br />SQL&gt; select * from t where id = 99;<br /><br />Execution Plan<br />-------------------------------------------------------------------------------------------------------<br />|  Id  |  Operation                          |  Name  |  Rows  |  Bytes |  Cost (%CPU)  |  Time       |<br />-------------------------------------------------------------------------------------------------------<br />|   0  |  SELECT STATEMENT                   |        |  50244 |  4710K |   235    (4)  |  00:00:02   |<br />|*  1  |   TABLE ACCESS FULL                 | T      |  50244 |  4710K |   235    (4)  |  00:00:02   |<br />-------------------------------------------------------------------------------------------------------<br /></pre>


<p>
<span class="parahead1">Oracle8<i>i</i> Database Release 3 
and Earlier</span>
</p>

<p>
<span class="bodycopy">But what happens when we bind the ID input--when
we issue SELECT * FROM t WHERE ID = :ID? Well, the answer depends on
which release of Oracle Database is being used. With Oracle8i Database
Release 3 and earlier, the optimizer will more or less "guess." It will
not have any information about the WHERE ID = :ID clause. The
information it has is </span>
</p>

<p>
</p>
<ul><li><span class="bodycopy"> ID has two values in the table: 1 and 99.</span></li><li><span class="bodycopy"> There are 50,000 records in the table.</span></li></ul>


<p>
<span class="bodycopy">And because ID has only two values, this old
optimizer will guess that for any query on ID, about half of the table
on average will be selected. And the database would come up with one
plan, regardless of the inputs. In this case, it would likely do a full
scan of the table. </span>
</p>

<p>
<span class="parahead1">Oracle9<i>i</i> Database and Oracle 
Database 10<i>g</i></span>
</p>

<p>
<span class="bodycopy">From Oracle9<i>i</i> Database Release 1 through Oracle Database 10<i>g</i>
Release 2, Oracle Database will wait until the cursor is opened to do
the actual optimization of the query--it will wait for the bind variable
value to be supplied by the application before figuring out the </span><span class="italicbodycopy">right</span><span class="bodycopy"> way to optimize the query. This is called </span><span class="italicbodycopy">bind variable peeking</span><span class="bodycopy">,
when the optimizer first looks at the bind values and then optimizes
the query. In this case, however, depending on which inputs are used to
first run the query, the database will either choose a full scan or an
index range scan plus table access by index rowid. And in Oracle9<i>i</i> Database Release 1 through Oracle Database 10<i>g</i>
Release 2, that is the plan that will be used to execute the SELECT *
FROM t WHERE ID = :ID query, regardless of the subsequent bind values,
until the query is hard-parsed and optimized again. </span>
</p>

<p>
<span class="bodycopy">I'll address what happens in Oracle Database 11<i>g</i>
Release 1 in a minute, but first let's take a look at what is happening
to the person whose scenario on Ask Tom inspired this discussion: </span>
</p>

<p>
<span class="boldbodycopy">1.</span><span class="bodycopy"> Someone hard-parsed the query in question, and the inputs used resulted in "Plan A."</span>
</p>

<p>
<span class="boldbodycopy">2.</span><span class="bodycopy"> Plan A was the best plan for that person, given the inputs--it was the most efficient plan. </span>
</p>

<p>
<span class="boldbodycopy">3.</span><span class="bodycopy"> Later,
someone else executed the same query. Using shared SQL, this person
reused the plan generated by the other person (Plan A in No. 1), but
the new bind variable inputs were different and the plan generated for
No. 1 was not the best plan for these inputs. In fact, the plan was
miserable for these new inputs. </span>
</p>

<p>
<span class="boldbodycopy">4.</span><span class="bodycopy"> The person
in No. 3 turned on SQL_TRACE and executed the query with inputs from
No. 3 again, but because SQL_TRACE was on, the query did not share the
SQL. The query was hard-parsed--with the new inputs--and this resulted in
a very different plan, "Plan B," and given these inputs, Plan B was
much better than Plan A.</span>
</p>

<p>
<span class="bodycopy">Using Oracle Database 10<i>g</i> Release 2, we can observe this easily. Consider the following:</span>
</p>

<p>
</p>
<pre>SQL&gt; variable id number<br />SQL&gt; set autotrace traceonly statistics<br />SQL&gt; exec :id := 99<br />PL/SQL procedure successfully completed.<br /><br />SQL&gt; select * from t where id = :id;<br />50254 rows selected.<br /><br />Statistics<br />----------------------------------<br />          <br />       4031  consistent gets<br />          <br />      50254  rows processed<br /></pre>


<p>
<span class="bodycopy">So we started off with ID=99 as the bind, and
the optimizer chose a full scan (you can prove that via TKPROF by
looking at the row source operation if you wish; I did. . . .)
Therefore, regardless of the bind value, the database will execute a
full scan from now on. For example, </span>
</p>

<p>
</p>
<pre>SQL&gt; exec :id : = 1<br />PL/SQL procedure successfully completed.<br /><br />SQL&gt; select * from t where id = :id;<br /><br />Statistics<br />----------------------------------<br />         <br />        720  consistent gets<br />         <br />          1  rows processed<br /></pre>


<p>
<span class="bodycopy">This result demonstrates that it was unlikely
that an index range scan/table access by index rowid was executed. In
such a case, we'd expect many fewer logical I/Os (consistent
gets)--three or four against an index and one against the table. This
result represents our "poorly performing query." Now we turn on
SQL_TRACE to find the performance characteristics, and we observe</span>
</p>

<p>
</p>
<pre>SQL&gt; alter session set sql_trace = true;<br />Session altered.<br /><br />SQL&gt; select * from t where id = :id;<br /><br />Statistics<br />-----------------------------------<br />          <br />          4  consistent gets<br />          <br />          1  rows processed<br /></pre>


<p>
<span class="bodycopy">Apparently just setting SQL_TRACE=TRUE is our
tuning mechanism! It isn't really--bind peeking and hard parsing are
what's causing this result, but unless you know that SQL_TRACE sets up
a child cursor and that bind peeking happens, this looks very
mysterious, especially if you turn SQL_TRACE off:</span>
</p>

<p>
</p>
<pre>SQL&gt; alter session set sql_trace=false;<br />Session altered.<br /><br />SQL&gt; select * from t where id = :id;<br /><br />Statistics<br />------------------------------------<br />          <br />        720  consistent gets<br />          <br />          1  rows processed<br /></pre>


<p>
<span class="bodycopy">See it run slowly (720 consistent gets). And now that we've seen slow, turn SQL_TRACE on again:</span>
</p>

<p>
</p>
<pre>SQL&gt; alter session set sql_trace=true;<br />Session altered.<br /><br />SQL&gt; select * from t where id = :id;<br />Statistics<br />--------------------------------------<br />          <br />          4  consistent gets<br />          <br />          1  rows processed<br /></pre>


<p>
<span class="bodycopy">And see it go fast. It is not magic; it is bind
peeking. To see the real plans, you can query V$SQL_PLAN /
V$SQL_PLAN_STATISTICS or use DBMS_XPLAN to dump the plans for each
child cursor, as shown in Listing 2.</span>
</p>

<p>
<span class="boldbodycopy">Code Listing 2:</span><span class="bodycopy"> Using DBMS_XPLAN to show the plans for each child cursor</span>
</p>

<p>
</p>
<pre>SQL&gt; select sql_id from v$sql where sql_text = 'select * from t where id = :id';<br /><br />SQL_ID<br />---------------------------------------<br />8s40hfjcbmxzk<br />8s40hfjcbmxzk<br /><br />SQL&gt; select * from table( dbms_xplan.display_cursor( '8s40hfjcbmxzk', 0 ) );<br /><br />PLAN_TABLE_OUTPUT<br />---------------------------------------<br />SQL_ID  8s40hfjcbmxzk, child number 0<br />---------------------------------------<br />select * from t where id = :id<br /><br />Plan hash value: 1601196873<br /><br />--------------------------------------------------------------------------------------<br />|  Id  |  Operation            |  Name  |  Rows |  Bytes  |  Cost (%CPU)  |  Time    |<br />--------------------------------------------------------------------------------------<br />|   0  |  SELECT STATEMENT     |        |       |         |    235 (100)  |          |<br />|*  1  |    TABLE ACCESS FULL  | T      | 50250 |   4710K |    235   (4)  |  00:00:02|<br />--------------------------------------------------------------------------------------<br /><br />Predicate Information (identified by operation id):<br />--------------------------------------------------------------------------------------<br />1 - filter("ID"=:ID)<br /><br />18 rows selected.<br /><br />SQL&gt; select * from table( dbms_xplan.display_cursor( '8s40hfjcbmxzk', 1 ) );<br /><br />PLAN_TABLE_OUTPUT<br />------------------------------------------<br />SQL_ID  8s40hfjcbmxzk, child number 1<br />------------------------------------------<br />select * from t where id = :id<br /><br />Plan hash value: 470836197<br /><br />-------------------------------------------------------------------------------------------------<br />|  Id  |  Operation                     |  Name  |  Rows  |  Bytes  |  Cost (%CPU)  |  Time     |<br />-------------------------------------------------------------------------------------------------<br />|   0  |  SELECT STATEMENT              |        |        |         |   2   (100)   |           |<br />|   1  |   TABLE ACCESS BY INDEX ROWID  |  T     |      1 |     96  |   2      (0)  | 00:00:01  |<br />|*  2  |    INDEX RANGE SCAN            |  T_IDX |      1 |         |   1      (0)  | 00:00:01  |<br />-------------------------------------------------------------------------------------------------<br /><br />Predicate Information (identified by operation id):<br />----------------------------------------------------<br />2 - access("ID"=:ID)<br /><br />19 rows selected.<br /></pre>


<p>



<span class="bodycopy">You can use v$sql_shared_cursor and the SQL_ID from Listing 2 to see why you have multiple child cursors as well. For example,</span>
</p>

<p>
</p>
<pre>SQL&gt; select child_number, <br />  2         stats_row_mismatch<br />  3      from v$sql_shared_cursor <br />  4      where sql_id = '8s40hfjcbmxzk'<br />  5    /<br /><br />CHILD_NUMBER   STATS_ROW_MISMATCH <br />-------------  ------------------                                                 <br />                   0 N<br />                   1 Y<br /></pre>


<p>
<span class="bodycopy">That is what you would look for to verify that
you were seeing an "it must be SQL_TRACE creating a new child cursor
and a hard parse with different binds" result. (The queries you run to
verify this in Oracle9<i>i</i> Database are slightly different from the Oracle Database 10<i>g</i> Release 2 queries above. If you are interested in the Oracle9<i>i</i> Database queries, you can review <a href="http://tkyte.blogspot.com/2007/09/sqltracetrue-part-two.html" target="blank"><span class="bodylink">tkyte.blogspot.com/2007/09/sqltracetrue-part-two.html</span></a>, where I worked the example through in that release.)</span>
</p>

<p>
<span class="parahead1">Oracle Database 11<i>g</i> Release 1</span>
</p>

<p>
<span class="bodycopy">The current release of Oracle Database--Oracle Database 11<i>g</i>--changes
the above behavior for the better. A new feature--intelligent cursor
sharing--enables the optimizer to recognize that performance can be
affected when a fixed, one-size-fits-all plan is used and come up with
different plans for certain bind ranges. In the following example, I
simply used the schema from above--the copy of ALL_OBJECTS, with one row
having the value ID=1, the index in place, and statistics gathered.
Then I ran a PL/SQL block that would open a cursor by using one of two
inputs--either 1 or 99. This time, instead of just one plan being
generated, we'll see two. The optimizer recognized that one plan was
not sufficient for all inputs and allowed for multiple plans to be
generated, as shown in Listing 3. </span>
</p>

<p>
<span class="boldbodycopy">Code Listing 3:</span><span class="bodycopy"> Multiple plans with intelligent cursor sharing (Oracle Database 11<i>g</i>)</span>
</p>

<p>
</p>
<pre>SQL&gt; select sql_id<br />  2      from v$sql<br />  3    where sql_text = 'select * from T where id = :x';<br />no rows selected<br /><br />SQL&gt; declare<br />  2    l_cursor sys_refcursor;<br />  3    type array is table of number;<br />  4    l_data  array := array(99,1);<br />  5    type data_array is table of T%rowtype;<br />  6    l_recs  data_array;<br />  7    begin<br />  8    for i in 1 .. l_data.count<br />  9    loop<br /> 10       open l_cursor for 'select * from T where id = :x' using l_data( i );<br /> 11       loop<br /> 12          fetch l_cursor bulk collect into l_recs limit 500;<br /> 13          exit when l_cursor%notfound;<br /> 14       end loop;<br /> 15       close l_cursor;<br /> 16    end loop;<br /> 17    end;<br /> 18    /<br />PL/SQL procedure successfully completed.<br /><br />SQL&gt; select sql_id<br />  2    from v$sql<br />  3   where sql_text = 'select * from T where id = :x';<br />SQL_ID<br />-----------------------------------------------------------------------<br />gw1fks2wb4j2g<br />gw1fks2wb4j2g<br /><br />SQL&gt; select * from table(dbms_xplan.display_cursor('gw1fks2wb4j2g',0));<br /><br />SQL_ID  gw1fks2wb4j2g, child number 0<br />-------------------------------------------------------------------------<br />select * from T where id = :x<br />---------------------------------------------------------------------------------------<br />|  Id   |  Operation            |  Name  |  Rows  |  Bytes |  Cost (%CPU)  |  Time    |<br />---------------------------------------------------------------------------------------<br />|   0   |  SELECT STATEMENT     |        |        |        |    292 (100)  |          |<br />|*  1   |    TABLE ACCESS FULL  |  T     |  68207 |  6927K |   292   (2)   | 00:00:04 |<br />---------------------------------------------------------------------------------------<br /><br />SQL&gt; select * from table(dbms_xplan.display_cursor('gw1fks2wb4j2g',1));<br /><br />SQL_ID  gw1fks2wb4j2g, child number 1<br />-------------------------------------<br />select * from T where id = :x<br />---------------------------------------------------------------------------------------------------<br />|  Id   |  Operation                     |  Name  |  Rows  |  Bytes  |  Cost (%CPU)  |  Time      |<br />---------------------------------------------------------------------------------------------------<br />|   0   |  SELECT STATEMENT              |        |        |         |   2    (100)  |            |<br />|   1   |    TABLE ACCESS BY INDEX ROWID | T      |     1  |    104  |   2       (0) |  00:00:01  |<br />|*  2   |      INDEX RANGE SCAN          | T_IDX  |     1  |         |   1       (0) |  00:00:01  |<br />---------------------------------------------------------------------------------------------------<br /></pre>


<p>
<span class="parahead1">IF Bind Variable Peeking Is a Problem</span>
</p>

<p>
<span class="bodycopy">Most of the time--almost all of the time, in
fact--bind variable peeking works as the designers of the feature
intended: in a positive, helpful manner. The query in the application
uses bind values that drive it to one plan or the other consistently.
It is only when the plan flip-flops between two radically different
execution paths, and for some segment of users, that you have a really
bad plan. In such cases, Oracle Database 11<i>g</i> might be the right answer for you, because it accommodates multiple plans. </span>
</p>
<span class="bodycopy">But when bind variable peeking doesn't work "nicely" and Oracle Database 11<i>g</i> is not a viable solution for you, what can you do to get around bind variable peeking? I'll go through the ideas one by one.<!--,span-->
</span>
<p>
<span class="boldbodycopy">Don't bind that query.</span><span class="bodycopy">
Yes, you read that correctly--don't use a bind variable (yes, I wrote
that--do not use a bind variable!) In my example, ID has two values--1
and 99. Let's say ID wasn't ID but rather was PROCESSED_FLAG and had
two values--Y and N. Most of the records are PROCESSED_FLAG=Y; some of
them are N. Some people query the processed records (Y=yes). They want
a full scan. Others query the unprocessed records in order to process
them (N=no). They want an index range scan. </span>
</p>
<p>
<span class="bodycopy">Here my suggestion would be not to bind against
PROCESSED_FLAG; instead, use literals. That way we have two queries and
two plans.</span>
</p>
<p>
<span class="bodycopy">This is also why I do not like
CURSOR_SHARING=FORCE, because when a programmer does this (uses
literals) and the DBA turns on CURSOR_SHARING=FORCE, we are back to the
original problem! Bind variable peeking comes into play once
again--there is one plan for all, and it depends on who runs the query
first. (By the way, CURSOR_SHARING=SIMILAR would not have this side
effect. It would choose not to bind against PROCESSED_FLAG based on the
statistics). </span>
</p>
<p>
<span class="boldbodycopy">Don't gather statistics that cause the plan to flip-flop.</span><span class="bodycopy">
If there is only one plan that the optimizer would ever choose, then
bind variable peeking will have no effect. If you were to execute the
above example without gathering histograms, the plan would not
flip-flop.</span>
</p>
<p>
<span class="boldbodycopy">Use your domain knowledge of the data.</span><span class="bodycopy">
If you know that when a certain query is executed with a date that
falls within the last 30 days, the volume of data would be small and
indexes would be used and that if the date is way in the past, the
volume of data would be large and full scans would be used, then just
use if/then/else. </span>
</p>
<p>
</p><pre>[[... if/then/else]]: <br /><br />if ( p_date &gt; sysdate-30 )<br />then<br />  open l_cursor for <br />  select * from t less_than_30 where ...<br />else<br />   open l_cursor for<br />   select * from t more_than_30 where ...<br />end if;<br />loop<br />   fetch l_cursor into ...; <br />...<br /></pre>


<p>
<span class="bodycopy">This works when you have good knowledge of your data. This approach is similar to what Oracle Database 11<i>g</i> is doing with intelligent cursor sharing. </span>
</p>
<p>
<span class="boldbodycopy">Use CURSOR_SHARING=SIMILAR.</span><span class="bodycopy">
If you use CURSOR_SHARING=SIMILAR, you can let Oracle Database decide
what to bind and what not to bind. For more details on that, with a
full example, see <a href="http://tkyte.blogspot.com/2007/09/sqltracetrue-part-two.html" target="_blank"><span class="bodylink">tkyte.blogspot.com/2007/09/sqltracetrue-part-two.html</span></a>. </span>
</p>
<p>
<span class="boldbodycopy">Use stored outlines.</span><span class="bodycopy">
Stored outlines are also known as query plan stability. In a test
environment, you would exercise the application by using appropriate or
representative inputs. Additionally, you would be capturing stored
outlines into the outline tables. You would then move these into
production and have the application issue ALTER SESSION to use these
stored outlines. </span>
</p>
<p>
<span class="bodycopy">Using stored outlines, you--in effect--freeze the
plans. (And you can stop gathering statistics as well, because you just
froze the plans.)</span>
</p>
<p>

<span class="boldbodycopy">Disable the bind peeking feature.</span><span class="bodycopy"> You can disable bind peeking by using an undocumented init.ora parameter, but--because this really affects you only if you have </span><span class="italicbodycopy">statistics</span><span class="bodycopy"> that cause plans to flip-flop--I would say, instead, that you should </span><span class="italicbodycopy">stop gathering those statistics</span><span class="bodycopy"> to save the time and resources it takes, and you'll have achieved basically the same goal. </span>
</p>]]>
    </content>
</entry>

<entry>
    <title>Dataguard Configuration: LOG_ARCHIVE_CONFIG and VALID_FOR in Oracle 10G</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2009/07/dataguard-configuration-log-archive-config-and-valid-for-in-oracle-10g.html" />
    <id>tag:www.heysky.net,2009:/digest//1.336</id>

    <published>2009-07-14T05:23:54Z</published>
    <updated>2009-07-14T05:25:23Z</updated>

    <summary><![CDATA[Subject: Dataguard Configuration: LOG_ARCHIVE_CONFIG and VALID_FOR in Oracle 10G &nbsp; Doc ID: 249594.1 Type: BULLETIN &nbsp; Modified Date : 12-MAY-2009 Status: PUBLISHED Checked for relevance on 12-May-2009 PURPOSE ------- This document has been created to explain the new Dataguard Configuration...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Databases" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="dataguard" label="dataguard" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="log_archive_config" label="LOG_ARCHIVE_CONFIG" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="standby" label="standby" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="valid_for" label="VALID_FOR" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<font face="helvetica"><table border="0" cellpadding="0" cellspacing="6" width="80%"><tbody><tr><td align="right" valign="TOP">Subject: </td>
<td colspan="4" align="left"><strong>Dataguard Configuration:  LOG_ARCHIVE_CONFIG and VALID_FOR in Oracle 10G</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="TOP"><a href="https://metalink2.oracle.com/help/usaeng/Search/search.html#file">Doc ID</a>: </td>
<td align="left"><strong>249594.1</strong></td>
<td align="right" valign="TOP">Type: </td>
<td align="left"><strong>BULLETIN</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="TOP">Modified Date
: </td>
<td align="left"><strong>12-MAY-2009</strong></td>
<td align="right" valign="TOP">Status: </td>
<td align="left"><strong>PUBLISHED</strong></td>
</tr>
</tbody></table>
</font>
<pre><font face="courier"><br />    Checked for relevance on 12-May-2009<br />    PURPOSE<br />    -------<br /><br />    This document has been created to explain the new Dataguard Configuration <br />    parameters that were added in Oracle 10G. The Dataguard configuration and <br />    db_unique_name parameters have been added to remove some complexities, <br />    and limitations inherent in previous versions of DataGuard.<br /><br /><br /> <br />    SCOPE &amp; APPLICATION<br />    -------------------<br /><br />    For use by Customers and Support analysts in understanding and using the <br />    new features.<br /><br /><br />    Dataguard Configuration:  LOG_ARCHIVE_CONFIG and VALID_FOR in Oracle 10G <br />    ------------------------------------------------------------------------<br /><br />    The Data Guard Configuration feature allows the user to optionally identify <br />    the current database as well as all the other databases in the configuration<br />    using the new LOG_ARCHIVE_CONFIG parameter.  When used, the <br />    LOG_ARCHIVE_CONFIG parameter defines the list of databases in this <br />    configuration.  Log transport will not be allowed to any database not on <br />    the list .  <br /><br />    Each database in the configuration will have a db_unique_name and the <br />    configuration can include 1 or more db_unique_names.<br /><br />    To set this up you will assign each database a unique name, example:<br /><br /><br />	db_unique_name = 'Chicago_Sales'  # Note this parameter is not dynamic<br /><br />    You will then add all the databases you want to be in this configuration, <br />    example:<br /><br />	log_archive_config='DG_CONFIG=(Chicago_Sales,Denver_Sales)'<br /><br /><br />    In this Simple Configuration we will only allow log transport between these <br />    2 databases, uniquely identified as: Chicago_Sales and Denver_Sales<br /><br />    Following this you can now specify the db_unique_name for each log archive <br />    destination. This will be used along with the VALID_FOR parameter to <br />    determine what logs to transport dependent on the database's current ROLE<br />    in the configuration.  The advantage of this feature is that we can <br />    switchover without having to change parameters to defer/enable destinations.<br /><br />    Is should be noted that although the DG_CONFIG attribute is an optional <br />    attribute of the optional LOG_ARCHIVE_CONFIG initialization parameter, <br />    it must be set to enable the dynamic addition of a standby database to a <br />    Data Guard configuration that has a Real Application Clusters primary <br />    database running in either maximum protection or maximum availability mode. <br /><br /><br />    How does the VALID_FOR Parameter Work ?<br />    ---------------------------------------<br /><br />    The VALID_FOR Parameter states that a specific log transport destination is <br />    VALID_FOR only when this database is in a certain ROLE (STANDBY/PRIMARY).<br /><br />    In this way you can set up a transport destination that will only be <br />    enabled when this db_unique_name is in a specific ROLE.<br /><br />    The default setting is ..<br /><br />	VALID_FOR=(ALL_LOGFILES, ALL_ROLES)<br /><br />    That setting will state that the log_archive_dest_n is valid for online <br />    redo log and standby redo log archival. It is also Valid if the database <br />    is currently in PRIMARY or STANDBY ROLE.<br />    <br />    More simply put: always archive to this destination.<br /><br /><br />    The full syntax for a local archive destination would be like this..<br /><br />	log_archive_dest_1='LOCATION=/u01/Sales/oradata/arch VALID_FOR=(ALL_LOGFILES,ALL_ROLES)' db_unique_name='Chicago_Sales'                     	                    db_unique_name=CHicago_Sales' <br /><br />    or if using a flash_recovery_area<br /><br />	log_archive_dest_1='LOCATION=USE_DB_RECOVERY_FILE_DEST VALID_FOR=(ALL_LOGFILES,ALL_ROLES)' db_unique_name='Chicago_Sales'                     	            		    db_unique_name=Chicago_Sales' <br /><br />    The real use of this parameter is to dynamically enable/defer destinations <br />    dependent on whether the database is mounted in the PRIMARY or STANDBY ROLE.<br /><br />    In a real situation you may set..<br />	<br />	db_unique_name='Chicago_Sales'<br />	log_archive_config='DG_CONFIG=(Chicago_Sales,Denver_Sales)'<br />	log_archive_dest_2='SERVICE=Denver_Sales LGWR ASYNC REOPEN=10<br />             VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) db_unique_name=Denver_Sales'<br /><br />    So we would only ship redo to Denver_Sales if Chicago_sales is running in<br />    the PRIMARY ROLE. Clearly if you were to Switchover and Chicago_Sales would <br />    take on the STANDBY_ROLE then this destination would become deferred <br />    dynamically.<br /><br /><br />    What views show the Setup ?<br />    ---------------------------<br /><br />    The view V$ARCHIVE_DEST has new columns to handle the new values.<br /><br />	<br />	SQL&gt; column DEST_NAME format A19<br />	SQL&gt; column DB_UNIQUE_NAME format A15<br />	SQL&gt; column VALID_NOW format A9<br />	SQL&gt; column VALID_TYPE format A15<br />	SQL&gt; column VALID_ROLE format A15<br />	SQL&gt; select DEST_NAME,DB_UNIQUE_NAME,VALID_NOW as CURRENT,VALID_TYPE,VALID_ROLE<br />             from V$ARCHIVE_DEST WHERE DB_UNIQUE_NAME &lt;&gt; 'NONE';<br /><br />	DEST_NAME           DB_UNIQUE_NAME  VALID_NOW  VALID_TYPE      VALID_ROLE<br />	------------------- --------------  ---------  --------------- ---------------<br />	LOG_ARCHIVE_DEST_2  Denver_Sales    YES        ONLINE_LOGFILE  PRIMARY_ROLE<br />	LOG_ARCHIVE_DEST_10 Chicago_sales   YES        ALL_LOGFILES    ALL_ROLES<br /><br /><br />    So this shows us that in fact both the destinations are currently in use <br />    as the database Chicago_Sales is the Primary..  <br />    <br />    Note LOG_ARCHIVE_DEST_10 is the default log_archive_dest_n parameter used<br />    when making use of a flash recovery area.<br /><br /><br /><br />RELATED DOCUMENTS<br />-----------------<br /><br />Oracle® Data Guard Concepts and Administration 10g Release 1 (10.1)<br />Oracle® Data Guard Concepts and Administration 10g Release 2 (10.2)<br /><br /><br /></font></pre> ]]>
        
    </content>
</entry>

<entry>
    <title>Comparison Between Features : RAC, Dataguard, Streams, Advanced Replication and Basic Replication</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2009/07/comparison-between-features-rac-dataguard-streams-advanced-replication-and-basic-replication.html" />
    <id>tag:www.heysky.net,2009:/digest//1.335</id>

    <published>2009-07-14T05:17:32Z</published>
    <updated>2009-07-14T05:19:02Z</updated>

    <summary><![CDATA[Subject: Comparison Between Features : RAC, Dataguard, Streams, Advanced Replication and Basic Replication &nbsp; Doc ID: 370850.1 Type: BULLETIN &nbsp; Modified Date : 30-JAN-2009 Status: PUBLISHED In this Document &nbsp;&nbsp;Purpose &nbsp;&nbsp;Scope and Application &nbsp;&nbsp;Comparison Between Features : RAC, Dataguard, Streams,...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Databases" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="dataguard" label="dataguard" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="metalink" label="metalink" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="rac" label="RAC" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="replication" label="replication" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="standby" label="standby" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="streams" label="Streams" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<font face="helvetica"><table border="0" cellpadding="0" cellspacing="6" width="80%"><tbody><tr><td align="right" valign="TOP">Subject: </td>
<td colspan="4" align="left"><strong>Comparison Between Features : RAC, Dataguard, Streams, Advanced Replication and Basic Replication</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="TOP"><a href="https://metalink2.oracle.com/help/usaeng/Search/search.html#file">Doc ID</a>: </td>
<td align="left"><strong>370850.1</strong></td>
<td align="right" valign="TOP">Type: </td>
<td align="left"><strong>BULLETIN</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="TOP">Modified Date
: </td>
<td align="left"><strong>30-JAN-2009</strong></td>
<td align="right" valign="TOP">Status: </td>
<td align="left"><strong>PUBLISHED</strong></td>
</tr>
</tbody></table>
</font>
<table border="0" cellpadding="0" cellspacing="0" height="0" width="98%"><tbody><tr><td colspan="3" bgcolor="#ffffff" valign="TOP" width="100%"><link rel="stylesheet" type="text/css" href="https://metalink2.oracle.com/images/metalink/generic/awiz.css" target="new">
<p><b>In this Document</b><br /><font size="-1">
&nbsp;&nbsp;<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,370850.1,1,1,1,helvetica#PURPOSE">Purpose</a><br />
&nbsp;&nbsp;<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,370850.1,1,1,1,helvetica#SCOPE">Scope and Application</a><br />
&nbsp;&nbsp;<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,370850.1,1,1,1,helvetica#BODYTEXT">Comparison Between Features : RAC, Dataguard, Streams, Advance Replication and Basic Replication</a><br />
</font></p><hr size="1"><p>
</p><p>
</p><h2 class="awiz">Applies to: </h2> 
Oracle Server - Enterprise Edition - Version: 9.0.1.4<br />Information in this document applies to any platform.<br />
Database Features :<br />
<br />
    Real Application Clusters (RAC)<br />
    Dataguard : Physical Standby &amp; Logical Standby<br />
    Streams<br />
    Advance Replication : Multi-Master Replication &amp; Updatable Materialized Views<br />
    Basic Replication : Read-only Materialized Views
<h2 class="awiz"><a href="http://www.heysky.net/digest/mt-static/html/editor-content.html?cs=utf-8" name="PURPOSE"></a>Purpose</h2>
This article describes similarities and differences between different
features available for high availability and distributed systems. <br /><br />It contains comparison between multiple features in matrix format <br /><br />It would help users to select feature useful and feasible in their environment. <br />
<h2 class="awiz"><a href="http://www.heysky.net/digest/mt-static/html/editor-content.html?cs=utf-8" name="SCOPE"></a>Scope and Application</h2>
This article is meant for DBA and Support Engineers. It does not require in-depth technical knowledge in any of these features. <br /><br />The article contains overview of covered topics and not technical details/steps. <br />
<h2 class="awiz"><a href="http://www.heysky.net/digest/mt-static/html/editor-content.html?cs=utf-8" name="BODYTEXT"></a>Comparison Between Features : RAC, Dataguard, Streams, Advance Replication and Basic Replication</h2>
<p>






<link rel="File-List" href="https://metalink2.oracle.com/metalink/plsql/Features%20Comparison_files/filelist.xml" target="new">

<!--[if gte mso 9]><xml>
 <o:DocumentProperties>
  <o:Author>Janak</o:Author>
  <o:LastAuthor>Janak</o:LastAuthor>
  <o:Revision>21</o:Revision>
  <o:TotalTime>601</o:TotalTime>
  <o:Created>2006-05-24T06:45:00Z</o:Created>
  <o:LastSaved>2006-05-24T10:20:00Z</o:LastSaved>
  <o:Pages>3</o:Pages>
  <o:Words>2467</o:Words>
  <o:Characters>14066</o:Characters>
  <o:Company>Oracle Corporation</o:Company>
  <o:Lines>117</o:Lines>
  <o:Paragraphs>28</o:Paragraphs>
  <o:CharactersWithSpaces>17274</o:CharactersWithSpaces>
  <o:Version>9.7616</o:Version>
 </o:DocumentProperties>
</xml><![endif]-->
<style>
<!--
 /* Font Definitions */
	{font-family:Wingdings;
	panose-1:5 0 0 0 0 0 0 0 0 0;
	mso-font-charset:2;
	mso-generic-font-family:auto;
	mso-font-pitch:variable;
	mso-font-signature:0 268435456 0 0 -2147483648 0;}
	{font-family:"Arial Unicode MS";
	panose-1:2 11 6 4 2 2 2 2 2 4;
	mso-font-charset:128;
	mso-generic-font-family:swiss;
	mso-font-pitch:variable;
	mso-font-signature:-1 -369098753 63 0 4129023 0;}
	{font-family:"\@Arial Unicode MS";
	panose-1:2 11 6 4 2 2 2 2 2 4;
	mso-font-charset:128;
	mso-generic-font-family:swiss;
	mso-font-pitch:variable;
	mso-font-signature:-1 -369098753 63 0 4129023 0;}
 /* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{mso-style-parent:"";
	margin:0in;
	margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:12.0pt;
	font-family:"Times New Roman";
	mso-fareast-font-family:"Times New Roman";}
h1
	{mso-style-next:Normal;
	margin:0in;
	margin-bottom:.0001pt;
	text-align:center;
	mso-pagination:widow-orphan;
	page-break-after:avoid;
	mso-outline-level:1;
	font-size:10.0pt;
	font-family:Arial;
	mso-font-kerning:0pt;}
h2
	{mso-style-next:Normal;
	margin:0in;
	margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	page-break-after:avoid;
	mso-outline-level:2;
	font-size:10.0pt;
	font-family:Arial;}
h3
	{mso-style-next:Normal;
	margin:0in;
	margin-bottom:.0001pt;
	text-align:center;
	mso-pagination:widow-orphan;
	page-break-after:avoid;
	mso-outline-level:3;
	font-size:10.0pt;
	font-family:Arial;
	color:blue;}
p.MsoBodyText, li.MsoBodyText, div.MsoBodyText
	{margin:0in;
	margin-bottom:.0001pt;
	mso-pagination:widow-orphan;
	font-size:10.0pt;
	font-family:Arial;
	mso-fareast-font-family:"Times New Roman";}
	{size:8.5in 11.0in;
	margin:1.0in 1.25in 1.0in 1.25in;
	mso-header-margin:.5in;
	mso-footer-margin:.5in;
	mso-paper-source:0;}
div.Section1
	{page:Section1;}
 /* List Definitions */
	{mso-list-id:164057655;
	mso-list-type:hybrid;
	mso-list-template-ids:-2110868504 36090700 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
	{mso-level-start-at:0;
	mso-level-number-format:bullet;
	mso-level-text:\F0B7;
	mso-level-tab-stop:.25in;
	mso-level-number-position:left;
	margin-left:.25in;
	text-indent:-.25in;
	font-family:Symbol;
	mso-fareast-font-family:"Times New Roman";
	mso-bidi-font-family:Arial;}
	{mso-level-tab-stop:1.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:1.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:2.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:2.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:3.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:3.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:4.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:4.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-list-id:938096607;
	mso-list-type:hybrid;
	mso-list-template-ids:950291966 36090700 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
	{mso-level-start-at:0;
	mso-level-number-format:bullet;
	mso-level-text:\F0B7;
	mso-level-tab-stop:.25in;
	mso-level-number-position:left;
	margin-left:.25in;
	text-indent:-.25in;
	font-family:Symbol;
	mso-fareast-font-family:"Times New Roman";
	mso-bidi-font-family:Arial;}
	{mso-level-tab-stop:1.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:1.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:2.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:2.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:3.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:3.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:4.0in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-level-tab-stop:4.5in;
	mso-level-number-position:left;
	text-indent:-.25in;}
	{mso-list-id:1438599885;
	mso-list-type:hybrid;
	mso-list-template-ids:-1321180056 67698689 67698691 67698693 67698689 67698691 67698693 67698689 67698691 67698693;}
	{mso-level-number-format:bullet;
	mso-level-text:\F0B7;
	mso-level-tab-stop:.25in;
	mso-level-number-position:left;
	margin-left:.25in;
	text-indent:-.25in;
	font-family:Symbol;}
ol
	{margin-bottom:0in;}
ul
	{margin-bottom:0in;}
-->
</style>
<!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext="edit" spidmax="1027"/>
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext="edit">
  <o:idmap v:ext="edit" data="1"/>
 </o:shapelayout></xml><![endif]-->

</p><div class="Section1">
<p class="MsoNormal"><!--[if !supportEmptyParas]-->&nbsp;<!--[endif]--><o:p></o:p></p>
<table style="border: medium none ; background: rgb(243, 243, 243) none repeat scroll 0% 0%; width: 675pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; border-collapse: collapse;" bgcolor="#f3f3f3" border="1" cellpadding="0" cellspacing="0" width="966">
 <tbody><tr style="height: 25.9pt;">
  <td style="border: 1.5pt double windowtext; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 25.9pt;" valign="top" width="131">
  <h1 style="text-align: left;" align="left"><span style="color: rgb(51, 51, 153);"><span style="">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>Features<o:p></o:p></span></h1>
  </td>
  <td rowspan="2" style="border-style: double solid double none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 1.5pt 0.75pt 1.5pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 25.9pt;" valign="top" width="118">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Real <span style="">&nbsp;</span>Application Clusters <span style="">&nbsp;&nbsp;&nbsp;&nbsp;</span>(RAC)</span></b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);"><o:p></o:p></span></p>
  </td>
  <td colspan="2" style="border-style: double solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 1.5pt 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 164.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 25.9pt;" valign="top" width="235">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Dataguard</span></b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);"><o:p></o:p></span></p>
  </td>
  <td rowspan="2" style="border-style: double solid double none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 1.5pt 0.75pt 1.5pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 25.9pt;" valign="top" width="120">
  <h3 style=""><span style="color: rgb(51, 51, 153);">Streams</span><span style="color: rgb(51, 51, 153);"><o:p></o:p></span></h3>
  </td>
  <td colspan="2" style="border-style: double solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 1.5pt 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 168.2pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 25.9pt;" valign="top" width="241">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Advance Replication</span></b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);"><o:p></o:p></span></p>
  </td>
  <td style="border-style: double double solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 1.5pt 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 25.9pt;" valign="top" width="120">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Basic Replication</span></b><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);"><o:p></o:p></span></b></p>
  </td>
 </tr>
 <tr style="height: 35.15pt;">
  <td style="border-style: none double double; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 1.5pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 35.15pt;" valign="top" width="131">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial;">Topic of Comparison</span></b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid double none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 1.5pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 35.15pt;" valign="top" width="119">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Physical <span style="">&nbsp;</span>Standby</span></b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid double none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 1.5pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 35.15pt;" valign="top" width="116">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Logical <span style="">&nbsp;&nbsp;</span>Standby</span></b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid double none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 1.5pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 35.15pt;" valign="top" width="120">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Multi-Master Replication</span></b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid double none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 1.5pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 35.15pt;" valign="top" width="120">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Updatable Materialized
  Views</span></b><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none double double none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 1.5pt medium; padding: 0.7pt 0.7pt 0in; background: silver none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 35.15pt;" valign="top" width="120">
  <p class="MsoNormal" style="text-align: center;" align="center"><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);">Read-only Materialized
  Views</span></b><b><span style="font-size: 10pt; font-family: Arial; color: rgb(51, 51, 153);"><o:p></o:p></span></b></p>
  </td>
 </tr>
 <tr style="height: 147.65pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 147.65pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Description</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 147.65pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Allows the Oracle database to run
  applications across a set of clustered servers.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 147.65pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Provides a physically identical
  copy of the primary database, with on disk database structures that are
  identical to the primary database on a block-for-block basis.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 147.65pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Contains the same logical
  information as the production database, although the physical organization
  and structure of the data can be different.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 147.65pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Enables information sharing in
  form of stream of messages. Enables the propagation and management of data,
  transactions, and events in a data stream.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 147.65pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">(Also called peer-to-peer or n-way
  replication)<span style="">&nbsp; </span>Enables multiple sites,
  acting as equal peers, to manage groups of replicated database objects.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 147.65pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Provides complete or partial copy
  (replica) of a target table from a single point in time. Enable users to work
  on a subset of a database while disconnected from the central database
  server.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 147.65pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Provides complete or partial
  read-only copy (replica) of a target table from a single point in time.
  Enable users to view a subset of a database while disconnected from the
  central database server.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 85.4pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 85.4pt;" valign="top" width="131">
  <h2 style="">Purpose<span style=""><o:p></o:p></span></h2>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 85.4pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- High availability</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Scalability</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Redundancy during failures</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 85.4pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Data protection</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Disaster recovery</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 85.4pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- High availability<o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Data protection<o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Disaster recovery<o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Efficient use of redundant
  hardware</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 85.4pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Data distribution</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Data sharing</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 85.4pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Data sharing</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 85.4pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Data distribution</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Sharing subset of data with
  update access.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 85.4pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Data distribution</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">- Sharing subset of data in
  read-only mode.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 51.05pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Hardware</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">All nodes must have hardware that
  runs same OS.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">All sites must have hardware that
  runs same OS.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">All sites must have hardware that
  runs same OS.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Servers with different hardware
  can be used.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Servers with different hardware
  can be used.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Servers with different hardware
  can be used.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Servers with different hardware
  can be used.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 51.05pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">OS</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Same OS on all nodes including
  Patchset release</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Same OS. Patchset release can be
  different in different sites.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Same OS. Patchset release can be
  different in different sites.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Can be used with different OS</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Can be used with different OS</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Can be used with different OS</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Can be used with different OS</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 51.05pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Oracle Software</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Same version on all nodes
  including Oracle Patchset release</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Same version on all nodes
  including Oracle Patchset release</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Same version on all nodes
  including Oracle Patchset release</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Can be used with different Oracle
  versions</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Can be used with different Oracle
  versions</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Can be used with different Oracle
  versions</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 51.05pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Can be used with different Oracle
  versions</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 132.8pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 132.8pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Feature Specific Terms</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 132.8pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Servers involved in RAC
  configuration are generally known as Nodes. High-speed link between nodes is
  called Interconnect.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 132.8pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Primary and Standby database
  servers are generally known as Primary Site and Standby Site respectively.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 132.8pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Primary and Standby database
  servers are generally known as Primary Site and Standby Site respectively.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 132.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Database from where changes are
  captured is called source or capture site. Database from where changes are
  applied is called destination or apply site.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 132.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">One database where Replication
  Administrative activities can be performed is called Master Definition Site.
  All other replicated databases are called Master sites.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 132.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Database with Master table is
  called Master Site or Target Site. Database where Materialized view is
  created is called Materialized view site.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 132.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Database with Master table is
  called Master Site or Target Site. Database where Materialized view is
  created is called Materialized view site.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 88.8pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Database</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Multiple instances linked by
  interconnect to share access to an Oracle database.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">One production database and one or
  more physical standby databases.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">One production database and one or
  more logical standby databases. </span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Data stream can propagate data
  either within a database or from one database to another.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Complete copy of replicated table
  is maintained in multiple databases.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Updatable Materialized view is
  created in database other than the one containing master table.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Read-only materialized view can be
  created either within a database or in another database.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 88.8pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Data Storage</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Single database on shared storage.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Primary site and Standby sites
  have their own database.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Primary site and Standby sites
  have their own database.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Source and Destination can either
  be same database or they can be different databases.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">All replicated master sites are
  having their own databases.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Master table and Materialized
  views are part of different databases.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Master table and Materialized
  views can either be in same database or they can be in different databases.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 168.8pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 168.8pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Logical Database Structure</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 168.8pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">As there is one database, there is
  one logical structure of the database.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 168.8pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">As physical structure of the
  database is exactly (block-by-block) same, the logical structure also remains
  same in primary and standby databases.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 168.8pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">When created, logical standby
  database has same structure as primary. Later, additional schema/objects can
  be created in logical standby database. However, original objects must remain
  same as primary.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 168.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Streams provide flexibility to
  have different structure of schema/objects at source and destination
  databases.<span style="">&nbsp; </span>This can be accomplished
  by using transformation of messages.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 168.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Logical structure of replicated
  objects must be same. Owner of those objects must be same in all master
  sites.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 168.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Both row and column subsetting
  enable you to create materialized views that contain a partial copy of the
  data at a master table. However, they are always based on a single master
  table.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 168.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Both row and column subsetting
  enable you to create materialized views that contain a partial copy of the
  data at a master table. Read-only materialized views can be created using
  join between multiple master tables.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 276.35pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 276.35pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Architecture Overview</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 276.35pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">A cluster comprises multiple
  interconnected computers or servers that appear as if they are one server to
  end users and applications. RAC uses Oracle Clusterware for the
  infrastructure to bind multiple servers so that they operate as a single
  system. If one clustered server fails, the Oracle database will continue
  running on the surviving servers.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 276.35pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Standby database is kept
  synchronized with the primary database, though Redo Apply, which recovers the
  redo data, received from the primary database and applies the redo to the
  standby database. If the primary database becomes unavailable, standby database
  can be switched to the primary role.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 276.35pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Standby database is kept
  synchronized with the primary database though SQL Apply, which uses logminer,
  transforms the data from redo logs into SQL statements and then executing the
  SQL statements on the standby database. If the primary database becomes
  unavailable, standby database can be switched to the primary role.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 276.35pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Each unit of shared information is
  called a message. Streams can capture, stage, and manage messages in Queue.
  Messages can be DML, DDL and user-defined messages. Streams can propagate the
  messages from one queue to other queue. When messages reach a destination,
  Streams can consume them based on your specifications.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 276.35pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Internal triggers capture changes
  applied at one site. The trigger stores those captured transactions locally.
  The source master site pushes (propagates and applies) those transactions to
  destination site.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 276.35pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Updatable Materialized view is a
  view that stores view data in it's own storage. A push process that is same
  as multi-master replication pushes updated data from MV site. However,
  changes from master site are pulled by refresh site using refresh process.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 276.35pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Read-only Materialized view is a
  view that stores view data in it's own storage. Data in materialized view are
  refreshed by refresh process. Refresh process is initiated at Materialized
  view site. Refresh process pulls data from master table using SQL query that
  was used to create Materialized view.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 393.8pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 393.8pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Overview of Installation/Setup</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 393.8pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">RAC installation is a two-phase
  installation. In phase one, use Oracle Universal Installer (OUI) to install
  Oracle Clusterware. In second phase, use OUI to install the RAC software
  (I.e. Oracle RDBMS with RAC option). You must install Oracle Clusterware and Oracle
  RDBMS in separate home directories.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 393.8pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Prepare Primary Database by making
  required changes in parameters, logging, archiving etc. Create a Backup Copy
  of the Primary Database Datafiles. Create a Control File for the Standby
  Database. Prepare an Initialization Parameter File for the Standby Database.
  Copy Files from the Primary System to the Standby System. Set Up the
  Environment to Support the Standby Database. Start the Physical Standby
  Database in continuous recovery mode.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 393.8pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Verify prerequisites Logical
  Standby Database (e.g. Datatypes, Primary Key etc). Create a Physical Standby
  Database. Stop Redo Apply on the Physical Standby Database. Prepare the
  Primary Database to Support a Logical Standby Database. Convert to a Logical
  Standby Database. Adjust Initialization Parameters for the Logical Standby
  Database. Open the Logical Standby Database and then perform certain
  Post-Creation Steps.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 393.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Create streams administrator user
  in all databases. In source database, create Capture Process and Propagation
  schedule for propagation to destination database. Create Apply Process in
  destination database.<span style="">&nbsp; </span>Start
  Supplemental Logging in source database. . Prepare source database/objects.
  Create copy of those objects in destination database using export/import
  (datapump or traditional) or using RMAN. Complete the instantiation of
  objects. Start Apply, Propagation and Capture processes.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 393.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Create replication administrator
  user at all the sites with required privileges. Create propagation from each
  site to all other sites. At one site create Master replication group. The
  group remains in quiesced state when created. This site becomes MDS. Add
  objects (to be replicated) in the group from MDS. Add all master sites in
  master group from MDS. Start replication by resuming replication group. It
  alters replication group from quiesced to normal state.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 393.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">At master site, create replication
  administrator. At materialized view (MV) site, create MV administrator.
  Create propagation from MV site to master site. Create master group at master
  site and add master objects in master group. Create materialized views at MV
  site. Create MV group at MV site and add materialized views in the MV group.
  On the MV site, create refresh group and add materialized views in refresh
  group.<span style="">&nbsp; </span>Start replication by resuming
  replication group.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 393.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">If MV is being created in database
  other than the one containing master table, then create database link in MV
  database to point to master database for accessing master table. Create
  materialized view.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 150.8pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 150.8pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Database/Instance status</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 150.8pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">All or any node of RAC can have
  instance with database open for DML/DDL access.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 150.8pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Redo apply requires database in
  recovery mode. When Physical standby database is in recovery mode, it cannot
  be opened. When not in recovery mode, it can only be opened in read-only
  mode.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 150.8pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">SQL Apply requires database open
  for running SQL statements. Hence, Logical standby database must be open in
  normal circumstances.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 150.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Apply process requires database
  open for running SQL statements. Hence, destination database must be open in
  normal circumstances.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 150.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Push job requires master sites to
  be open when it pushes transaction to other master sites. Hence, in normal
  circumstances, all the master databases must be open.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 150.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Push as well as refresh job
  requires master and MV sites to be open. Hence, in normal circumstances, the
  master and MV databases must be open.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 150.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">Refresh job requires master and MV
  sites to be open. Hence, in normal circumstances, the master and MV databases
  must be open.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
 </tr>
 <tr style="height: 88.8pt;">
  <td style="border-style: none double solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 1.5pt 0.75pt; padding: 0.7pt 0.7pt 0in; background: rgb(179, 179, 179) none repeat scroll 0% 0%; width: 91.7pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="131">
  <p class="MsoNormal" style=""><b><span style="font-size: 10pt; font-family: Arial;">Restriction on Datatypes</span></b><b><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></b></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 1.15in; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="118">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">As there is one database, it
  supports all datatypes.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 83pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="119">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">As physical structure of the
  database is exactly (block-by-block) same, it supports all datatypes.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 81.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="116">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">There is restriction on datatypes
  allowed in logical standby setup.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">There is restriction on datatypes
  allowed in streams setup.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">There is restriction on datatypes
  allowed in replicated tables.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.75pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(217, 217, 217) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">There is restriction on datatypes
  allowed in materialized views.</span><span style="font-size: 10pt; font-family: Arial;"><o:p></o:p></span></p>
  </td>
  <td style="border-style: none double solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 1.5pt 0.75pt medium; padding: 0.7pt 0.7pt 0in; background: rgb(230, 230, 230) none repeat scroll 0% 0%; width: 84.1pt; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; height: 88.8pt;" valign="top" width="120">
  <p class="MsoNormal" style=""><span style="font-size: 10pt; font-family: Arial;">There is restriction on datatypes
  allowed in materialized views.</span></p></td></tr></tbody></table></div></td></tr></tbody></table> ]]>
        
    </content>
</entry>

<entry>
    <title>Creating physical standby using RMAN duplicate without shutting down the primary</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2009/07/creating-physical-standby-using-rman-duplicate-without-shutting-down-the-primary.html" />
    <id>tag:www.heysky.net,2009:/digest//1.334</id>

    <published>2009-07-14T05:11:39Z</published>
    <updated>2009-07-14T05:14:30Z</updated>

    <summary><![CDATA[Subject: Creating physical standby using RMAN duplicate without shutting down the primary &nbsp; Doc ID: 789370.1 Type: HOWTO &nbsp; Modified Date : 23-JUN-2009 Status: MODERATED In this Document &nbsp;&nbsp;Goal &nbsp;&nbsp;Solution &nbsp;&nbsp;References This document is being delivered to you via Oracle...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Databases" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="dataguard" label="dataguard" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="metalink" label="metalink" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="rman" label="RMAN" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="standby" label="standby" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<font face="helvetica"><table border="0" cellpadding="0" cellspacing="6" width="80%"><tbody><tr><td align="right" valign="TOP">Subject: </td>
<td colspan="4" align="left"><strong>Creating physical standby using RMAN duplicate without shutting down the primary</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="TOP"><a href="https://metalink2.oracle.com/help/usaeng/Search/search.html#file">Doc ID</a>: </td>
<td align="left"><strong>789370.1</strong></td>
<td align="right" valign="TOP">Type: </td>
<td align="left"><strong>HOWTO</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="TOP">Modified Date
: </td>
<td align="left"><strong>23-JUN-2009</strong></td>
<td align="right" valign="TOP">Status: </td>
<td align="left"><strong>MODERATED</strong></td>
</tr>
</tbody></table>
</font>

<table border="0" cellpadding="0" cellspacing="0" height="0" width="98%"><tbody><tr><td colspan="3" bgcolor="#ffffff" valign="TOP" width="100%"><link rel="stylesheet" type="text/css" href="https://metalink2.oracle.com/images/metalink/generic/kmstyles.css" target="new">
<p><b>In this Document</b><br /><font size="-1">
&nbsp;&nbsp;<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,789370.1,1,1,1,helvetica#GOAL">Goal</a><br />
&nbsp;&nbsp;<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,789370.1,1,1,1,helvetica#FIX">Solution</a><br />
&nbsp;&nbsp;<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,789370.1,1,1,1,helvetica#REF">References</a><br />
</font></p><hr size="1"><p>
</p><p><table align="center" border="1" cellpadding="4" cellspacing="0">
<tbody><tr><td><font size="-1"><em>This document is being delivered to you via Oracle Support's 
<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,789370.1,1,1,1,helvetica#" onclick="window.open("ml2_documents.showNOT?p_showHeader=0&amp;p_showHelp=0&amp;p_id=283265.1", 
"popup", "resizable=yes,scrollbars=yes,width=600,height=400");return false;">Rapid Visibility</a> (RaV) 
process, and therefore has not been subject to an independent technical review.</em></font></td></tr></tbody></table>
</p><p>
</p><h2 class="km">Applies to: </h2> 
Oracle Server - Enterprise Edition - Version: 10.2.0.1 to 10.2.0.4<br />
Information in this document applies to any platform.<br />
Oracle Server Enterprise Edition - Version: 10.2.0.1 to 10.2.0.4

<h2 class="km"><a href="http://www.heysky.net/digest/mt-static/html/editor-content.html?cs=utf-8" name="GOAL"></a>Goal</h2>
The following note describes step-by-step procedure to create physical
standby by using RMAN duplicate without shutting down the primary
(Production) database. <br /><br /><strong><span class="kmfixedwidthfont">Database Name :-&nbsp;prim <br />Primary db_unique_name :-&nbsp;prim <br />standby db_unique_name :-&nbsp;stdby <br /><br />Primary Hostname :- raca.idc.oracle.com <br />standby Hostname :- core1.idc.oracle.com </span><br /></strong>
<h2 class="km"><a href="http://www.heysky.net/digest/mt-static/html/editor-content.html?cs=utf-8" name="FIX"></a>Solution</h2>
<p>STEP: 1 <br /><br />Enable Force Logging on <strong>primary</strong>, <br /><br /><code class="km"></code></p>
  <div class="kmcodeblock" style="width: 95%;">
    <p>SQL&gt; ALTER DATABASE FORCE LOGGING; </p>
    <p>Database altered.</p>
  </div>
  <p>&nbsp;</p>
  <div class="kmnotebox">NOTE: Create password file if not present, also check if archiving enabled. </div>
  <p>STEP: 2 <br /><br />Configure a Standby Redo Log <strong>on primary</strong>, <br /><br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">SQL&gt; ALTER DATABASE ADD STANDBY LOGFILE GROUP 3 '/u01/app/oracle/databases/prim/redo/log3a.log' size 50m; <br /><br />Database altered. <br /><br />SQL&gt; ALTER DATABASE ADD STANDBY LOGFILE GROUP 4 '/u01/app/oracle/databases/prim/redo/log4a.log' size 50m; <br /><br />Database altered. <br /><br />SQL&gt; ALTER DATABASE ADD STANDBY LOGFILE GROUP 5 '/u01/app/oracle/databases/prim/redo/log5a.log' size 50m; <br /><br />Database altered. <br /><br />SQL&gt; ALTER DATABASE ADD STANDBY LOGFILE GROUP 6 '/u01/app/oracle/databases/prim/redo/log6a.log' size 50m; <br /><br />Database altered. </code></div>
  <p>&nbsp;</p>
  <div class="kmnotebox">NOTE: To check the number of SRL, <br /><br />(maximum number of logfiles for each thread + 1) * maximum number 
of threads <br /><br />For example, if the primary database has 3 log files for each thread and 2 threads, then 8 standbys redo log 
file groups are needed on the standby database. <br /><br />Verify the standby redo log file groups were created.<br /><br />SQL&gt; SELECT GROUP#,ThREAD#,SEQUENCE#,ARCHIVED,STATUS FROM V$STANDBY_LOG; <br /></div>
  <p><br />STEP :3 <br /><br />Modify the primary initialization parameter for dataguard <strong>on primary</strong>, <br /><br /><code class="km"></code></p>
  <div class="kmcodeblock" style="width: 95%;">
    <p>SQL&gt;alter system set LOG_ARCHIVE_CONFIG='DG_CONFIG=(prim,stdby)'; </p>
    <p>System altered.</p>
    <p><br />SQL&gt;
alter system set
LOG_ARCHIVE_DEST_1='LOCATION=/u01/app/oracle/databases/prim/redo/
VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=prim'; </p>
    <p>System altered.</p>
    <p><br />SQL&gt;alter
system set LOG_ARCHIVE_DEST_2='SERVICE=stdby LGWR ASYNC
VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=stdby'; </p>
    <p>System altered.</p>
    <p><br />SQL&gt; alter system set LOG_ARCHIVE_DEST_STATE_1=ENABLE; </p>
    <p>System altered.</p>
    <p><br />SQL&gt;alter system set FAL_SERVER=stdby; </p>
    <p>System altered.</p>
    <p><br />SQL&gt;alter system set FAL_CLIENT=prim; </p>
    <p>System altered.</p>
    <p><br />SQL&gt;alter
system set
DB_FILE_NAME_CONVERT='/u01/app/oracle/databases/prim/data/','/u01/app/oracle/databases/stdby/data'
scope=spfile; </p>
    <p>System altered.</p>
    <p><br />SQL&gt;alter
system set
LOG_FILE_NAME_CONVERT='/u01/app/oracle/databases/prim/redo/','/u01/app/oracle/databases/stdby/redo'
scope=spfile; <br /></p>
    <p>System altered.</p>
  </div>
  <p>STEP:4 <br /><br />Run the backup job at the <strong>primary</strong> by connecting to target and catalog DB(if any) <br /><br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">run <br />{ <br />allocate channel c1 type disk; <br />allocate channel 
c2 type disk; <br />backup database format '/u01/app/oracle/databases/stage/%U'; <br />backup archivelog all format '/u01/app/oracle/databases/stage/%U'; 
<br />backup current controlfile for standby format '/u01/app/oracle/databases/stage/%U'; <br />} <br /><br /><br />using target database 
control file instead of recovery catalog <br />allocated channel: c1 <br />channel c1: sid=22 devtype=DISK <br /><br />allocated channel: 
c2 <br />channel c2: sid=32 devtype=DISK <br /><br />Starting backup at 05-MAR-09 <br />channel c1: starting full datafile backupset <br />channel 
c1: specifying datafile(s) in backupset <br />input datafile fno=00001 name=/u01/app/oracle/databases/prim/data/system01.dbf <br />input 
datafile fno=00002 name=/u01/app/oracle/databases/prim/data/undotbs01.dbf <br />channel c1: starting piece 1 at 05-MAR-09 <br />channel 
c2: starting full datafile backupset <br />channel c2: specifying datafile(s) in backupset <br />input datafile fno=00003 name=/u01/app/oracle/databases/prim/data/sysaux01.dbf 
<br />channel c2: starting piece 1 at 05-MAR-09 <br />channel c1: finished piece 1 at 05-MAR-09 <br />piece handle=/u01/app/oracle/databases/stage/0tk95ldn_1_1 
tag=TAG20090305T143325 comment=NONE <br />channel c1: backup set complete, elapsed time: 00:01:56 <br />channel c1: starting full datafile 
backupset <br />channel c1: specifying datafile(s) in backupset <br />including current control file in backupset <br />channel c1: starting 
piece 1 at 05-MAR-09 <br />channel c2: finished piece 1 at 05-MAR-09 <br />piece handle=/u01/app/oracle/databases/stage/0uk95ldn_1_1 
tag=TAG20090305T143325 comment=NONE <br />channel c2: backup set complete, elapsed time: 00:01:58 <br />channel c2: starting full datafile 
backupset <br />channel c2: specifying datafile(s) in backupset <br />channel c1: finished piece 1 at 05-MAR-09 <br />piece handle=/u01/app/oracle/databases/stage/0vk95lhb_1_1 
tag=TAG20090305T143325 comment=NONE <br />channel c1: backup set complete, elapsed time: 00:00:03 <br />including current SPFILE in 
backupset <br />channel c2: starting piece 1 at 05-MAR-09 <br />channel c2: finished piece 1 at 05-MAR-09 <br />piece handle=/u01/app/oracle/databases/stage/10k95lhd_1_1 
tag=TAG20090305T143325 comment=NONE <br />channel c2: backup set complete, elapsed time: 00:00:02 <br />Finished backup at 05-MAR-09 
<br /><br />Starting backup at 05-MAR-09 <br />current log archived <br />channel c1: starting archive log backupset <br />channel c1: specifying 
archive log(s) in backup set <br />input archive log thread=1 sequence=5 recid=1 stamp=679686819 <br />input archive log thread=1 sequence=6 
recid=2 stamp=679686958 <br />input archive log thread=1 sequence=7 recid=3 stamp=679687040 <br />input archive log thread=1 sequence=8 
recid=4 stamp=679743155 <br />input archive log thread=1 sequence=9 recid=5 stamp=680047441 <br />input archive log thread=1 sequence=10 
recid=6 stamp=680621993 <br />channel c1: starting piece 1 at 05-MAR-09 <br />channel c2: starting archive log backupset <br />channel 
c2: specifying archive log(s) in backup set <br />input archive log thread=1 sequence=11 recid=7 stamp=680636808 <br />input archive 
log thread=1 sequence=12 recid=22 stamp=680703332 <br />input archive log thread=1 sequence=13 recid=32 stamp=680704306 <br />input 
archive log thread=1 sequence=14 recid=34 stamp=680704331 <br />input archive log thread=1 sequence=15 recid=36 stamp=680704336 <br />input 
archive log thread=1 sequence=16 recid=38 stamp=680705571 <br />input archive log thread=1 sequence=17 recid=51 stamp=680711731 <br />channel 
c2: starting piece 1 at 05-MAR-09 <br />channel c2: finished piece 1 at 05-MAR-09 <br />piece handle=/u01/app/oracle/databases/stage/12k95lhl_1_1 
tag=TAG20090305T143531 comment=NONE <br />channel c2: backup set complete, elapsed time: 00:00:26 <br />channel c1: finished piece 1 
at 05-MAR-09 <br />piece handle=/u01/app/oracle/databases/stage/11k95lhl_1_1 tag=TAG20090305T143531 comment=NONE <br />channel c1: backup 
set complete, elapsed time: 00:01:01 <br />Finished backup at 05-MAR-09 <br /><br />Starting backup at 05-MAR-09 <br />channel c1: starting 
full datafile backupset <br />channel c1: specifying datafile(s) in backupset <br />including standby control file in backupset <br />channel 
c1: starting piece 1 at 05-MAR-09 <br />channel c1: finished piece 1 at 05-MAR-09 <br />piece handle=/u01/app/oracle/databases/stage/13k95lji_1_1 
tag=TAG20090305T143634 comment=NONE <br />channel c1: backup set complete, elapsed time: 00:00:02 <br />Finished backup at 05-MAR-09 <br />released channel: c1 <br />released channel: c2 <br /></code></div>
  <p>STEP :5 <br /><br />Create parameter file on primary copy it to standby and make the necessary changes, <br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">SQL&gt;create pfile='/u01/app/oracle/databases/prim/stage/initstdby.ora' from spfile; <br /><br />File created. <br /></code></div>
  <p>STEP :6 <br /><br />Copy the listener.ora,tnsname.ora and sqlnet.ora files into staging directory. <br /><br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">[oracle@raca prim]$ cp /u01/app/oracle/network/admin/*.ora /u01/app/oracle/databases/prim/stage/ <br /></code></div>
  <p><br />Copy the redo logs also to standby to avoid size mismatch, <br /><br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">[oracle@raca prim]$ cp /u01/app/oracle/databases/prim/redo/*.log /u01/app/oracle/databases/prim/stage/ <br /></code></div>
  <p>STEP : 7 <br /><br />Move the files to standby server, <br /><br />a. Create the same directory on standby server and copy the backups. <br /><br />os standby, <br /><br />$mkdir -p /u01/app/oracle/databases/stage/ </p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">[oracle@raca prim]$ scp /u01/app/oracle/databases/stage/* core1.idc.oracle.com:/u01/app/oracle/databases/stage/ </code></div>
  <p><br />b.
Alternatively we can copy the backups to standby different directory.
On standby server connect to RMAN target as primary and auxiliary
instance or if your primary is having catalog database then connect to
target as primary, catalog database and auxiliary instance. Catalog
those backup pieces to let the controlfile of primary&nbsp;or catalog
database to know the backup information. </p>
  <p><br />For details on how to catalog backup piece refer, <br /><br /><a href="https://metalink2.oracle.com/metalink/plsql/showdoc?db=NOT&amp;id=470463.1&amp;blackframe=1">Note 470463.1</a> - How To Catalog Backups / Archivelogs / Datafile Copies / Controlfile Copies</p>
  <p>STEP:&nbsp;8 <br /><br />Make the necessary changes on the copied initstdby.ora file <strong>on standby</strong>. <br /><br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">db_name=prim <br />db_unique_name=stdby <br />log_archive_config='DG_CONFIG=(prim,stdby)' 
<br />log_archive_dest_1='LOCATION=/u01/app/oracle/databases/stdby/redo/ VALID_FOR=(ALL_LOGFILES,ALL_ROLES) DB_UNIQUE_NAME=stdby' 
<br />log_archive_dest_2='SERVICE=prim LGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=prim' <br />log_archive_dest_state_1=ENABLE 
<br />db_file_name_convert='/u01/app/oracle/databases/prim/data/','/u01/app/oracle/databases/stdby/data/' <br />log_file_name_convert='/u01/app/oracle/databases/prim/redo/','/u01/app/oracle/databases/stdby/redo/' 
<br />REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE <br />standby_archive_dest='/u01/app/oracle/databases/stdby/arch/'<br />standby_file_management=AUTO <br />fal_client=stdby <br />fal_server=prim <br /></code></div>
  <p>STEP: 9</p>
  <p>Create standby instance, </p>
  <p>create the same password as that of primary. Alternatively we can copy the password file from primary and rename it on standby. </p>
  <p>For example from <strong>primary</strong> copry the password file,</p>
  <p><br />scp /u01/app/oracle/dbs/opapwprim core1.idc.oracle.com:/u01/app/oracle/dbs/ </p>
  <p><strong>on standby,</strong></p>
  <p>$mv orapwprim orapwstdby<br /></p>
  <p>or create&nbsp;new password same as primary&nbsp;as mentioned below,</p>
  <p><br />a. in UNIX, <br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km"><code class="km">$export ORACLE_SID <br />$orapwd file='$ORACLE_HOME/dbs/orapwstdby' password=sys entries=10; </code></code></div>
  <p>&nbsp;in Windows, <br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">d:&gt;set ORACLE_SID=stdby <br />d:&gt;oradim -new -sid stdby -intpwd sys <br /></code></div>
  <p><br />b Create necessary directories and start the auxiliary instance <strong>on standby</strong>&nbsp;<br /><br /><code class="km"></code></p>
  <div class="kmcodeblock" style="width: 95%;">
    <p>[oracle@core1 stdby]$ pwd <br />/u01/app/oracle/databases/stdby <br /><br />[oracle@core1 stdby]$mkdir data redo oradata stage udump bdump cdump <br /><br />SQL&gt;create spfile from pfile='/u01/app/oracle/databases/stage/initstdby.ora'; </p>
    <p>File created.<br /><br />SQL&gt;start nomount; <br /><br />ORACLE instance started. <br /><br />Total System Global Area 612368384 bytes <br />Fixed Size 1220844 bytes <br />Variable Size 167776020 bytes <br />Database Buffers 436207616 bytes <br />Redo Buffers 7163904 bytes <br /><br /><br />SQL&gt;exit <br /></p>
  </div>
  <p><br />STEP :10 <br /><br />Create net services on <strong>both primary and standby</strong>, <br /><br />At prim server, <br /><br />prim 
= <br />(DESCRIPTION = <br />(ADDRESS_LIST = <br />(ADDRESS = (PROTOCOL = TCP)(HOST =raca.idc.oracle.com )(PORT = 1521)) <br />) <br />(CONNECT_DATA 
= <br />(SERVICE_NAME = prim) <br />) <br />) <br /><br />stdby = <br />(DESCRIPTION = <br />(ADDRESS_LIST = <br />(ADDRESS = (PROTOCOL = TCP)(HOST 
=core1.idc.oracle.com )(PORT = 1521)) <br />) <br />(CONNECT_DATA = <br />(SERVICE_NAME = stdby) <br />) <br />) <br /><br /><br />At standby server, 
<br /><br />prim = <br />(DESCRIPTION = <br />(ADDRESS_LIST = <br />(ADDRESS = (PROTOCOL = TCP)(HOST =raca.idc.oracle.com )(PORT = 1521)) 
<br />) <br />(CONNECT_DATA = <br />(SERVICE_NAME = prim) <br />) <br />) <br /><br />stdby = <br />(DESCRIPTION = <br />(ADDRESS_LIST = <br />(ADDRESS 
= (PROTOCOL = TCP)(HOST =core1.idc.oracle.com )(PORT = 1521)) <br />) <br />(CONNECT_DATA = <br />(SERVICE_NAME = stdby) <br />) <br />) <br /><br />STEP :&nbsp;11&nbsp; Use RMAN duplicate for standby <strong>on standby</strong>,</p>
  <p>When
'dorecover' is specified in the duplicate for stanby command then do a
archivelog switch on the target database and run the duplicate. <br /><br />Example : <br /><br /><strong>on primary</strong>, <br /><br />sql&gt; alter system archive log current; </p>
  <p><strong>on </strong><strong>standby,</strong></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">Connect to target(i.e. prim via connect string) and catalog database(if 
any) and this auxiliary database by, <br /><br />$RMAN target /@prim catalog RMAN/RMAN@catdb auxiliary / <br /><br />if no catalog database, 
<br /><br />$RMAN target sys/&lt;password&gt;@prim auxiliary / <br /><br />Recovery Manager: Release 10.2.0.1.0 - Production on Thu Mar 5 12:30:56 2009 <br /><br />Copyright (c) 1982, 2005, Oracle. All rights reserved. <br /><br />connected to target database: PRIM (DBID=3971986030) 
<br />connected to auxiliary database: PRIM (DBID=3971986030, not open) <br /><br />RMAN&gt; duplicate target database for standby dorecover; <br /><br />Starting Duplicate Db at 05-MAR-09 <br />using target database control file instead of recovery catalog <br />allocated channel: 
ORA_AUX_DISK_1 <br />channel ORA_AUX_DISK_1: sid=36 devtype=DISK <br /><br />contents of Memory Script: <br />{ <br />set until scn 503194; 
<br />restore clone standby controlfile; <br />sql clone 'alter database mount standby database'; <br />} <br />executing Memory Script 
<br /><br />executing command: SET until clause <br /><br />Starting restore at 05-MAR-09 <br />using channel ORA_AUX_DISK_1 <br /><br />channel 
ORA_AUX_DISK_1: starting datafile backupset restore <br />channel ORA_AUX_DISK_1: restoring control file <br />channel ORA_AUX_DISK_1: 
reading from backup piece /u01/app/oracle/databases/prim/stage/0pk86cs2_1_1 <br />channel ORA_AUX_DISK_1: restored backup piece 1 
<br />piece handle=/u01/app/oracle/databases/prim/stage/0pk86cs2_1_1 tag=TAG20090224T175722 <br />channel ORA_AUX_DISK_1: restore complete, 
elapsed time: 00:00:01 <br />output filename=/u01/app/oracle/databases/stdby/oradata/control01.ctl <br />Finished restore at 05-MAR-09 
<br /><br />sql statement: alter database mount standby database <br />released channel: ORA_AUX_DISK_1 <br /><br />contents of Memory Script: 
<br />{ <br />set until scn 503194; <br />set newname for datafile 1 to <br />"/u01/app/oracle/databases/stdby/data/system01.dbf"; <br />set newname for datafile 2 to <br />"/u01/app/oracle/databases/stdby/data/undotbs01.dbf"; <br />set newname for datafile 3 to <br />"/u01/app/oracle/databases/stdby/data/sysaux01.dbf"; <br />restore <br />check readonly <br />clone database <br />; <br />} <br />executing Memory Script <br /><br />executing command: SET until clause <br /><br />executing command: SET NEWNAME <br /><br />executing 
command: SET NEWNAME <br /><br />executing command: SET NEWNAME <br /><br />Starting restore at 05-MAR-09 <br />allocated channel: ORA_AUX_DISK_1 
<br />channel ORA_AUX_DISK_1: sid=36 devtype=DISK <br /><br />channel ORA_AUX_DISK_1: starting datafile backupset restore <br />channel 
ORA_AUX_DISK_1: specifying datafile(s) to restore from backup set <br />restoring datafile 00003 to /u01/app/oracle/databases/stdby/data/sysaux01.dbf 
<br />channel ORA_AUX_DISK_1: reading from backup piece /u01/app/oracle/databases/stage/0uk95ldn_1_1 <br />channel ORA_AUX_DISK_1: restored 
backup piece 1 <br />piece handle=/u01/app/oracle/databases/stage/0uk95ldn_1_1 tag=TAG20090305T143325 <br />channel ORA_AUX_DISK_1: 
restore complete, elapsed time: 00:00:07 <br />channel ORA_AUX_DISK_1: starting datafile backupset restore <br />channel ORA_AUX_DISK_1: 
specifying datafile(s) to restore from backup set <br />restoring datafile 00001 to /u01/app/oracle/databases/stdby/data/system01.dbf 
<br />restoring datafile 00002 to /u01/app/oracle/databases/stdby/data/undotbs01.dbf <br />channel ORA_AUX_DISK_1: reading from backup 
piece /u01/app/oracle/databases/stage/0tk95ldn_1_1 <br />channel ORA_AUX_DISK_1: restored backup piece 1 <br />piece handle=/u01/app/oracle/databases/stage/0tk95ldn_1_1 
tag=TAG20090305T143325 <br />channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:15 <br />Finished restore at 05-MAR-09 <br /><br />contents 
of Memory Script: <br />{ <br />switch clone datafile all; <br />} <br />executing Memory Script <br /><br />datafile 1 switched to datafile 
copy <br />input datafile copy recid=4 stamp=680711065 filename=/u01/app/oracle/databases/stdby/data/system01.dbf <br />datafile 2 switched 
to datafile copy <br />input datafile copy recid=5 stamp=680711065 filename=/u01/app/oracle/databases/stdby/data/undotbs01.dbf <br />datafile 
3 switched to datafile copy <br />input datafile copy recid=6 stamp=680711065 filename=/u01/app/oracle/databases/stdby/data/sysaux01.dbf 
<br /><br />contents of Memory Script: <br />{ <br />set until scn 503194; <br />recover <br />standby <br />clone database <br />delete archivelog 
<br />; <br />} <br />executing Memory Script <br /><br />executing command: SET until clause <br /><br />Starting recover at 05-MAR-09 <br />using 
channel ORA_AUX_DISK_1 <br /><br />starting media recovery <br /><br />channel ORA_AUX_DISK_1: starting archive log restore to default destination 
<br />channel ORA_AUX_DISK_1: restoring archive log <br />archive log thread=1 sequence=11 <br />channel ORA_AUX_DISK_1: restoring archive 
log <br />archive log thread=1 sequence=12 <br />channel ORA_AUX_DISK_1: restoring archive log <br />archive log thread=1 sequence=13 
<br />channel ORA_AUX_DISK_1: restoring archive log <br />archive log thread=1 sequence=14 <br />channel ORA_AUX_DISK_1: restoring archive 
log <br />archive log thread=1 sequence=15 <br />channel ORA_AUX_DISK_1: restoring archive log <br />archive log thread=1 sequence=16 
<br />channel ORA_AUX_DISK_1: restoring archive log <br />archive log thread=1 sequence=17 <br />channel ORA_AUX_DISK_1: reading from 
backup piece /u01/app/oracle/databases/stage/12k95lhl_1_1 <br />channel ORA_AUX_DISK_1: restored backup piece 1 <br />piece handle=/u01/app/oracle/databases/stage/12k95lhl_1_1 
tag=TAG20090305T143531 <br />channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:03 <br />channel ORA_AUX_DISK_1: starting 
archive log restore to default destination <br />channel ORA_AUX_DISK_1: restoring archive log <br />archive log thread=1 sequence=8 
<br />channel ORA_AUX_DISK_1: restoring archive log <br />archive log thread=1 sequence=9 <br />channel ORA_AUX_DISK_1: restoring archive 
log <br />archive log thread=1 sequence=10 <br />channel ORA_AUX_DISK_1: reading from backup piece /u01/app/oracle/databases/stage/11k95lhl_1_1 
<br />channel ORA_AUX_DISK_1: restored backup piece 1 <br />piece handle=/u01/app/oracle/databases/stage/11k95lhl_1_1 tag=TAG20090305T143531 
<br />channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:15 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_8_679684398.dbf 
thread=1 sequence=8 <br />channel clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_8_679684398.dbf 
recid=8 stamp=680711072 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_9_679684398.dbf thread=1 sequence=9 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_9_679684398.dbf recid=10 
stamp=680711078 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_10_679684398.dbf thread=1 sequence=10 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_10_679684398.dbf recid=9 
stamp=680711078 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_11_679684398.dbf thread=1 sequence=11 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_11_679684398.dbf recid=6 
stamp=680711066 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_12_679684398.dbf thread=1 sequence=12 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_12_679684398.dbf recid=7 
stamp=680711067 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_13_679684398.dbf thread=1 sequence=13 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_13_679684398.dbf recid=4 
stamp=680711066 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_14_679684398.dbf thread=1 sequence=14 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_14_679684398.dbf recid=1 
stamp=680711066 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_15_679684398.dbf thread=1 sequence=15 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_15_679684398.dbf recid=3 
stamp=680711066 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_16_679684398.dbf thread=1 sequence=16 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_16_679684398.dbf recid=2 
stamp=680711066 <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_17_679684398.dbf thread=1 sequence=17 <br />channel 
clone_default: deleting archive log(s) <br />archive log filename=/u01/app/oracle/databases/stdby/redo/1_17_679684398.dbf recid=5 
stamp=680711066 <br />media recovery complete, elapsed time: 00:00:01 <br />Finished recover at 05-MAR-09 <br />Finished Duplicate Db at 05-MAR-09 <br /><br />RMAN&gt;exit <br /></code></div>
  <div class="kmnotebox">
    <p>NOTE: We can use without dorecover clause also,</p>
    <p>Example,</p>
    <p>&nbsp;RMAN&gt;duplicate target database for standby;</p>
  </div>
  <p><br />STEP :&nbsp;12 Start the MRP(managed recovery process) <strong>on standby</strong>, </p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">SQL&gt; select name,db_unique_name,database_role, from v$database; <br /><br />NAME DB_UNIQUE_NAME DATABASE_ROLE <br />--------- ---------------- -------------- <br />PRIM STDBY PHYSICAL STANDBY <br /><br /><br />SQL&gt; alter database recover managed standby database disconnect; <br /><br />Database altered.</code></div>
  <p>STEP :&nbsp;13 <br /><br />Enable the log_archive_dest_2 <strong>on primary</strong>, which is to send the logs to standby server. </p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">SQL&gt;alter system set log_archive_dest_state_2=enable; <br /><br />System altered. <br /><br /></code></div>
  <p>&nbsp;</p>
  <p>STEP :14 <br /><br />Check the standby whether it is in SYNC with primary, <br /><br />A. Check the v$archived view <strong>on standby</strong>, </p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">SQL&gt; SELECT SEQUENCE#, FIRST_TIME, NEXT_TIME FROM V$ARCHIVED_LOG ORDER BY SEQUENCE#; <br /><br />SEQUENCE# FIRST_TIM NEXT_TIME <br />---------- --------- --------- <br />29 06-MAR-09 06-MAR-09 <br />30 06-MAR-09 
06-MAR-09 <br />31 06-MAR-09 06-MAR-09 <br />32 06-MAR-09 06-MAR-09 <br />33 06-MAR-09 06-MAR-09 <br />34 06-MAR-09 06-MAR-09 <br />35 06-MAR-09 
06-MAR-09 <br />36 06-MAR-09 06-MAR-09 <br />37 06-MAR-09 06-MAR-09 <br />38 06-MAR-09 06-MAR-09 <br />39 06-MAR-09 06-MAR-09 <br /></code></div>
  <p><br />B.&nbsp;Do the log switch <strong>on primary</strong>, <br /><br /></p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">SQL&gt; ALTER SYSTEM SWITCH LOGFILE; <br /><br />System altered. <br /></code></div>
  <p>C.&nbsp;<strong>On standby</strong>, </p>
  <div class="kmcodeblock" style="width: 95%;"><code class="km">SQL&gt; SELECT SEQUENCE#, FIRST_TIME, NEXT_TIME FROM V$ARCHIVED_LOG ORDER BY SEQUENCE#; <br /><br /><br />SEQUENCE# FIRST_TIM NEXT_TIME <br />---------- --------- --------- <br />29 06-MAR-09 06-MAR-09 <br />30 
06-MAR-09 06-MAR-09 <br />31 06-MAR-09 06-MAR-09 <br />32 06-MAR-09 06-MAR-09 <br />33 06-MAR-09 06-MAR-09 <br />34 06-MAR-09 06-MAR-09 
<br />35 06-MAR-09 06-MAR-09 <br />36 06-MAR-09 06-MAR-09 <br />37 06-MAR-09 06-MAR-09 <br />38 06-MAR-09 06-MAR-09 <br />39 06-MAR-09 06-MAR-09 
<br /><br />SEQUENCE# FIRST_TIM NEXT_TIME <br />---------- --------- --------- <br />40 06-MAR-09 07-MAR-09 <br /><br /><br />SQL&gt; select sequence#,applied from v$archived_log order by sequence#; <br /><br /><br />SEQUENCE# APP <br />---------- --- <br />29 YES <br />30 YES <br />31 YES <br />32 YES 
<br />33 YES <br />34 YES <br />35 YES <br />36 YES <br />37 YES <br />38 YES <br />39 YES <br /><br />SEQUENCE# APP <br />---------- --- <br />40 YES <br /></code></div>
<h2 class="km"><a href="http://www.heysky.net/digest/mt-static/html/editor-content.html?cs=utf-8" name="REF"></a>References</h2>
<a href="https://metalink2.oracle.com/metalink/plsql/showdoc?db=NOT&amp;id=183570.1&amp;blackframe=1">Note 183570.1</a> - Creating a Data Guard Database with RMAN (Recovery Manager) using Duplicate Command<br />
<a href="https://metalink2.oracle.com/metalink/plsql/showdoc?db=NOT&amp;id=466321.1&amp;blackframe=1">Note 466321.1</a> - RMAN Duplicate For Standby Fails with Rman-06024: No Backup Or Copy Of The Control File Found To Restore</td></tr></tbody></table> ]]>
        
    </content>
</entry>

<entry>
    <title>10gR2 Dataguard Content</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2009/07/10gr2-dataguard-content.html" />
    <id>tag:www.heysky.net,2009:/digest//1.333</id>

    <published>2009-07-14T05:03:51Z</published>
    <updated>2009-07-14T05:11:02Z</updated>

    <summary><![CDATA[Subject: 10gR2 Dataguard Content &nbsp; Doc ID: 739396.1 Type: HOWTO &nbsp; Modified Date : 14-MAY-2009 Status: PUBLISHED In this Document &nbsp;&nbsp;Goal &nbsp;&nbsp;Solution Applies to: Oracle Server - Enterprise Edition - Version: 10.2.0.1 to 10.2.0.4 Information in this document applies to...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Databases" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="dataguard" label="dataguard" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="failover" label="FAILOVER" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="metalink" label="metalink" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="standby" label="standby" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<font face="helvetica"><table border="0" cellpadding="0" cellspacing="6" width="80%"><tbody><tr><td align="right" valign="TOP">Subject: </td>
<td colspan="4" align="left"><strong>10gR2 Dataguard Content</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="TOP"><a href="https://metalink2.oracle.com/help/usaeng/Search/search.html#file">Doc ID</a>: </td>
<td align="left"><strong>739396.1</strong></td>
<td align="right" valign="TOP">Type: </td>
<td align="left"><strong>HOWTO</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="TOP">Modified Date
: </td>
<td align="left"><strong>14-MAY-2009</strong></td>
<td align="right" valign="TOP">Status: </td>
<td align="left"><strong>PUBLISHED</strong></td>
</tr>
</tbody></table>
</font>

<table border="0" cellpadding="0" cellspacing="0" height="0" width="98%"><tbody><tr><td colspan="3" bgcolor="#ffffff" valign="TOP" width="100%"><link rel="stylesheet" type="text/css" href="https://metalink2.oracle.com/images/metalink/generic/kmstyles.css" target="new">
<p><b>In this Document</b><br /><font size="-1">
&nbsp;&nbsp;<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,739396.1,1,1,1,helvetica#GOAL">Goal</a><br />
&nbsp;&nbsp;<a href="https://metalink2.oracle.com/metalink/plsql/f?p=130:14:255770429578443221::::p14_database_id,p14_docid,p14_show_header,p14_show_help,p14_black_frame,p14_font:NOT,739396.1,1,1,1,helvetica#FIX">Solution</a><br />
</font></p><hr size="1"><p>
</p><p>
</p><h2 class="km">Applies to: </h2> 
Oracle Server - Enterprise Edition - Version: 10.2.0.1 to 10.2.0.4<br />
Information in this document applies to any platform.<br />

<h2 class="km"><a href="http://www.heysky.net/digest/mt-static/html/editor-content.html?cs=utf-8" name="GOAL"></a>Goal</h2>
<p>This is a place holder note for most of the dataguard content that can be accessed from one page</p>
  
<p>This specific note is for Database ver 10.2.x</p>
<h2 class="km"><a href="http://www.heysky.net/digest/mt-static/html/editor-content.html?cs=utf-8" name="FIX"></a>Solution</h2>
<table style="border: medium none ; border-collapse: collapse;" border="1" cellpadding="0" cellspacing="0">
    <tbody>
      <tr>
        <td style="border: 1pt solid black; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638"><div align="center">
          </div><p align="center"><strong>Setup and Configuration of Data Guard</strong></p><blockquote><span></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=343424.1" title="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=343424.1" target="_blank">Note.343424.</a> Creating a 10gr2 Data Guard Physical Standby database with Real-Time apply<br /><br /><span></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=380449.1" title="Creating a RAC Physical Standby for a RAC Primary" target="_blank">Note.380449.1</a> Creating a RAC Physical Standby for a RAC Primary <br /><span></span><br /><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=387339.1" target="new">Note.387339.1</a> Creating a Single Instance Physical Standby for a RAC Primary<br /><span></span><br /><a href="http://www.oracle.com/technology/deploy/availability/pdf/MAA_WP_10gR2_RACPrimaryRACLogicalStandby.pdf" target="_blank">Creating a RAC Logical Standby Database for a RAC Primary Database</a><br /><span></span><br /><a href="http://www.oracle.com/technology/deploy/availability/pdf/MAA_WP_10gR2_ClientFailoverBestPractices.pdf" target="_blank">Client Failover setup in Data Guard Configurations</a><br /><span></span><br /><a href="http://www.oracle.com/technology/deploy/availability/pdf/MAA_WP_10gR2_FastStartFailoverBestPractices.pdf" target="_blank">Data Guard Fast-Start Failover - Best Practices</a><br /><span></span><br /><a href="http://www.oracle.com/technology/deploy/availability/pdf/maa10gr2multiplestandbybp.pdf" target="_blank">Setup Multiple Standby Databases - Best Practices<br /><br /></a></blockquote>
          
          
          
          
          
          
        </td>
      </tr>
      <tr>
        <td style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" align="center" valign="top" width="638"><div align="left">
          </div><blockquote><p style="text-indent: -0.25in;"><strong>Patching, Upgrade and Migration</strong><span></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=278641.1" target="_blank"><br /></a></p><div align="left"><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=278641.1" target="_blank">Note.278641.1</a> Applying Patchset with a 10g Physical Standby in Place<span><br /><br /></span><span></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=278521.1" target="_blank">Note.278521.1</a> Upgrading to 10g with a Physical Standby in Place<span><br /><br /></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=437276.1" target="_blank">Note 437276.1</a> Upgrading Oracle Database with a Logical Standby Database In Place<span><br /><br /><a title="Oracle Recommended Patches 
-- Oracle Database" href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=756671.1" target="new">Note 756671.1</a> Oracle Recommended Patches -- Oracle Database<br /><br /></span><a href="http://www.oracle.com/technology/deploy/availability/pdf/MAA_WP_10gR2_RollingUpgradeBestPractices.pdf" target="_blank">Rolling 
Database Upgrades Using Data Guard SQL Apply</a><span><br /><br /></span><a href="http://www.oracle.com/technology/deploy/availability/pdf/maa_wp_10gr2_asmmigrationwithdg.pdf" target="_blank">Minimal 
Downtime Migration to ASM</a><span><br /><br /></span><a target="_blank" href="https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&amp;p_id=466181.1">Oracle 10<em>g</em> Upgrade Companion - for upgrading from Oracle9<em>i</em> to Oracle10<em>g</em></a><a href="http://www.oracle.com/technology/deploy/availability/pdf/maa_wp_10gr2_asmmigrationwithdg.pdf" target="_blank"><br /><br /><br /></a></div><div align="left">
          </div><div align="left">
          </div><div align="left">
          </div><div align="left">
          </div><div align="left">
          </div><div align="left">
          </div></blockquote>
        </td>
      </tr>
      <tr>
        <td style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638">
          
          <blockquote><strong><br /></strong><div align="center"><strong>Managing Data Guard - Physical</strong><span></span><br /></div><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ps.htm#i1010428" target="new"><br />Adding a Datafile or Creating a Tablespace</a><br /></blockquote><blockquote><span></span><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ps.htm#i1010512" target="new">Dropping Tablespaces and Deleting Datafiles</a><span><br /><br /></span><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ps.htm#i1034172" target="new">Renaming a Datafile in the Primary Database</a><span><br /><br /></span><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ps.htm#i1026480" target="new">Recovering Through the OPEN RESETLOGS Statement</a><span><br /><br /></span><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ps.htm#i1014482" target="new">Opening a Physical Standby Database for Read-Only Access</a><span><br /><br /></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=382686.1" title="CAN DATAGUARD HAVE DIFFERENT SCHEMA ACCOUNT STATUS FOR PRIMARY AND STANDBY DB?" target="_blank">Note.382686.1</a> CAN DATAGUARD HAVE DIFFERENT SCHEMA ACCOUNT STATUS FOR PRIMARY AND STANDBY DB ?<span><br /><br /><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=394815.1" title="How to Rename the Datafiles When using OMF in Standby" target="_blank">Note. <u><font color="#0000ff">394815.1</font></u></a></span> How to Rename the Datafiles When using OMF in Standby<br /><br /></blockquote>
          
          
          
          
          
          
        </td>
      </tr>
      <tr>
        <td style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638"><div align="center">
          </div>
          <div align="center"><strong><br />Managing Data Guard - Logical</strong><span></span><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ls.htm#CHDGBCJG" target="new"><br /><br /></a><div align="left"><blockquote><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ls.htm#CHDGBCJG" target="new">Using 
DBMS_LOGSTDBY.SKIP to Prevent Changes to Specific Schema Objects</a><span></span><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ls.htm#i1045623" target="new"><br /><br />Modifying 
a Logical Standby Database<br /><br /></a></blockquote></div></div>
          
        </td>
      </tr>
      <tr>
        <td style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638">
          
          
          
          <p style="text-indent: -0.25in;"><strong><br /></strong></p><div align="center"><strong>Switchover and Failover</strong><span></span><br /><span></span></div><p style="text-indent: -0.25in;"><span><br /></span></p><blockquote><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=414043.1" target="_blank">Note.414043.1</a> Transitions for Data Guard Configurations Using Mixed Oracle Binaries<span></span><br /><span></span><br /><span></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=738642.1" target="new">Note.738642.1</a> Step by Step Guide on How To Reinstate Failed Primary Database into Physical Standby<span></span><br /><span></span><br /><span></span><a href="http://www.oracle.com/technology/deploy/availability/pdf/MAA_WP_10gR2_SwitchoverFailoverBestPractices.pdf" target="_blank">Data Guard Switchover and Failover -<span>&nbsp; Best Practice<br /><br /></span></a></blockquote>
          
        </td>
      </tr>
      <tr>
        <td style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638"><div align="center">
          </div>
          <div align="center"><strong>Performance</strong><span></span><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ls.htm#CHDEEDJG" target="new"><br /><br /></a><blockquote><div align="left"><a href="http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14239/manage_ls.htm#CHDEEDJG" target="new">Tuning a Logical Standby Database</a></div></blockquote></div>
          <p>&nbsp;</p>
          <p><br /></p>
        </td>
      </tr>
      <tr>
        <td style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638"><div align="center">
          
          
          
          </div><div align="center"><strong>Troubleshooting</strong><span></span><br /><span></span></div><p style="text-indent: -0.25in;"><span><br /></span></p><blockquote><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=241374.1" target="_blank">Note 814417.1 Information to gather and upload for Dataguard related problems<br /><br />Note.241374.1</a> Script to Collect Data Guard Primary Site Diagnostic 
Information<span></span><br /><span></span><br /><span></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=241438.1" target="_blank">Note.241438.1</a> Script to Collect Data Guard Physical Standby Diagnostic Information<span></span><br /><span></span><br /><span></span><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=241512.1" target="_blank">Note.241512.1</a> Script to Collect Data Guard Logical Standby Diagnostic Information<br /><br /><br /></blockquote>
        </td>
      </tr>
      <tr>
        <td style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638"><div align="center">
          </div>
          <div align="center"><strong>Dataguard and RAC</strong><span></span><br /><span></span></div><p style="text-indent: -0.25in;"><span><br /></span></p><blockquote><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=370434.1" target="_blank">Note.370434.1</a> How to make CRS aware of the role change in Data Guard environment?</blockquote>
        </td>
      </tr>
      <tr>
        <td rowspan="1" style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638"><br /><div align="center"><strong>Miscelleanous</strong><br /><br /><blockquote><div align="left"><a href="https://metalink.oracle.com/CSP/main/article?cmd=show&amp;type=NOT&amp;id=386830.1" target="new">Note 386830.1</a> ALERT:  Bug 5380055 Corrupts Index Blocks Especially in Data Guard Configurations<br /></div></blockquote><div align="left"><br /></div></div></td>
      </tr><tr>
        <td style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638"><div align="center">
          </div><p align="center"><strong>Common Dataguard errors</strong><br /></p><blockquote><div align="left">ORA-<span>16057 
DGID from server not in Data Guard configuration</span><br /></div></blockquote><blockquote><div align="left">ORA-<span>12154 TNS No Listener</span></div></blockquote>
          
          
          <p>&nbsp;</p>
          <p>&nbsp;</p>
          <p>&nbsp;</p>
        </td>
      </tr><tr>
        <td rowspan="1" style="border-style: none solid solid; border-color: rgb(236, 233, 216) black black; border-width: medium 1pt 1pt; padding: 0in 5.4pt; width: 6.65in; background-color: transparent;" valign="top" width="638"><br /></td>
      </tr>
    </tbody>
  </table><br /><br /></td></tr></tbody></table> ]]>
        
    </content>
</entry>

<entry>
    <title>Solaris下调试程序方法：使用truss</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2008/09/howto-use-truss-on-solaris.html" />
    <id>tag:www.heysky.net,2008:/digest//1.332</id>

    <published>2008-09-23T10:07:31Z</published>
    <updated>2008-09-23T10:14:09Z</updated>

    <summary><![CDATA[From: http://blog.chinaunix.net/u1/42574/showart_489928.htmlSolaris下调试程序方法：使用trusstruss 介绍 solaris下的truss跟linux下的strace功能一样，用来跟踪系统/库函数调用和系统接收到的信号。并把函数调用跟信号发送到标准出错上。truss 使用方法truss&nbsp; -a&nbsp; -e&nbsp; -f&nbsp; -rall&nbsp; -wall&nbsp; -p truss&nbsp; -a&nbsp; -e&nbsp; -f&nbsp; -rall&nbsp; -wall -a&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 显示传递给exec函数的参数-e&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 显示传递给exec函数的环境变量-f&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; 显示子进程 -rall&nbsp;&nbsp;&nbsp;&nbsp; 显示所有读取的数据(默认32bytes) -wall&nbsp;&nbsp;&nbsp; 显示所有写的数据(默认32bytes) -p&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; Hook到一个已存在的进程(必须是进程的所有者或者root)-d&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; 显示跟踪进程运行的时间&lt;program&gt; 指定要运行的程序 truss 例子# truss -rall -wall -f -p &lt;PID&gt;#...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Linux" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="OS" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="command" label="command" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="debug" label="debug" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="solaris" label="Solaris" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="trace" label="trace" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="truss" label="truss" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<i>From: <a href="http://blog.chinaunix.net/u1/42574/showart_489928.html">http://blog.chinaunix.net/u1/42574/showart_489928.html</a></i><br /><br /><b><font style="font-size: 1.5625em;">Solaris下调试程序方法：使用truss</font></b><br /><br /><b>truss 介绍 </b><br /><br />solaris下的truss跟linux下的strace功能一样，用来跟踪系统/库函数调用和系统接收到的信号。并把函数调用跟信号发送到标准出错上。<br /><br /><b>truss 使用方法</b><br /><br /><i>truss&nbsp; -a&nbsp; -e&nbsp; -f&nbsp; -rall&nbsp; -wall&nbsp; -p <br /><br />truss&nbsp; -a&nbsp; -e&nbsp; -f&nbsp; -rall&nbsp; -wall </i><br /><br />-a&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 显示传递给exec函数的参数<br />-e&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 显示传递给exec函数的环境变量<br />-f&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; 显示子进程 <br />-rall&nbsp;&nbsp;&nbsp;&nbsp; 显示所有读取的数据(默认32bytes) <br />-wall&nbsp;&nbsp;&nbsp; 显示所有写的数据(默认32bytes) <br />-p&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; Hook到一个已存在的进程(必须是进程的所有者或者root)<br />-d&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; 显示跟踪进程运行的时间<br />&lt;program&gt; 指定要运行的程序 <br /><br /><b>truss 例子</b><br /><br /><i># truss -rall -wall -f -p &lt;PID&gt;<br /># truss -rall -wall lsnrctl start<br /># truss -aef lsnrctl dbsnmp_start<br />0<br /># truss -d date<br /><br />Base time stamp:&nbsp; 1066157908.5731&nbsp; [ Tue Oct 14 14:58:28 EDT 2003 ]<br /><br />&nbsp;0.0000 execve("/usr/bin/date", 0xFFBEF29C, 0xFFBEF2A4)&nbsp; argc = 1<br /><br />&nbsp;0.0449 mmap(0x00000000, 8192, PROT_READ|PROT_WRITE|PROT_EXEC,MAP_PRIVATE|MAP_ANON, -1, 0) = 0xFF3A0000<br /><br />&nbsp;0.0453 resolvepath("/usr/lib/ld.so.1", "/usr/lib/ld.so.1", 1023) = 16<br /><br />&nbsp;0.0457 open("/var/ld/ld.config", O_RDONLY)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Err#2 ENOENT<br /><br />&nbsp;0.0460 open("/usr/lib/libc.so.1", O_RDONLY)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 3<br /><br />&nbsp;0.0463 fstat(3, 0xFFBEE9C4)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0464 mmap(0x00000000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF390000<br /><br />&nbsp;0.0466 mmap(0x00000000, 794624, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF280000<br /><br />&nbsp;0.0470 mmap(0xFF33A000, 24652, PROT_READ|PROT_WRITE|PROT_EXEC,MAP_PRIVATE|MAP_FIXED, 3, 696320) = 0xFF33A000<br /><br />&nbsp;0.0474 munmap(0xFF32A000, 65536)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0479 memcntl(0xFF280000, 113332, MC_ADVISE, MADV_WILLNEED, 0, 0) = 0<br /><br />&nbsp;0.0481 close(3)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0483 open("/usr/lib/libdl.so.1", O_RDONLY)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 3<br /><br />&nbsp;0.0485 fstat(3, 0xFFBEE9C4)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0487 mmap(0xFF390000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED,3, 0) = 0xFF390000<br /><br />&nbsp;0.0490 close(3)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0493 open("/usr/platform/SUNW,Ultra-5_10/lib/libc_psr.so.1", O_RDONLY) = 3<br /><br />&nbsp;0.0496 fstat(3, 0xFFBEE854)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0497 mmap(0x00000000, 8192, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF380000<br /><br />&nbsp;0.0500 mmap(0x00000000, 16384, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0xFF370000<br /><br />&nbsp;0.0502 close(3)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0514 munmap(0xFF380000, 8192)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0521 brk(0x00022420)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0523 brk(0x00024420)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0526 time()&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 1066157908<br /><br />&nbsp;0.0531 open("/usr/share/lib/zoneinfo/US/Eastern", O_RDONLY) = 3<br /><br />&nbsp;0.0533 read(3, " T Z i f\0\0\0\0\0\0\0\0".., 8192)&nbsp;&nbsp;&nbsp;&nbsp; = 1250<br /><br />&nbsp;0.0536 close(3)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />&nbsp;0.0542 ioctl(1, TCGETA, 0xFFBEEFDC)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 0<br /><br />Tue Oct 14 14:58:28 EDT 2003<br /><br />&nbsp;0.0545 write(1, " T u e&nbsp;&nbsp; O c t&nbsp;&nbsp; 1 4&nbsp;&nbsp; 1".., 29)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 29<br /><br />&nbsp;0.0547 llseek(0, 0, SEEK_CUR)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; = 1829<br /><br />&nbsp;0.0549 _exit(0)</i> ]]>
        
    </content>
</entry>

<entry>
    <title>Solaris平台上如何知道某个端口被哪个进程和应用程序占用</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2008/09/howto-know-the-process-occupying-a-certain-port-on-solaris.html" />
    <id>tag:www.heysky.net,2008:/digest//1.331</id>

    <published>2008-09-23T08:48:39Z</published>
    <updated>2008-09-23T10:06:10Z</updated>

    <summary><![CDATA[From: http://blog.csdn.net/Adali/archive/2007/11/23/1899779.aspxSolaris平台上如何知道某个端口被哪个进程和应用程序占用我经常在Solaris服务器上启好几个Tomcat和GlassFish, 会遇到"端口"被占用的错误, 很难直接用命令得知这个端口到底被哪个进程或者应用程序占用了， Alex给了我三个解决方案。附带说一句，我只尝试了第一种方案，相当的好用。而Alex愿意花时间找解决方案，却不愿意花几分钟把这些好东西写出来，结果就是被我发表出来。功劳还是要归Alex Peng.第一种方案：1。使用下面shell script，先建立一个port.sh文件:# more /tmp/port.sh#!/bin/shfor pid in `ls /proc`do&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; pf=`/usr/bin/pfiles $pid 2&gt;/dev/null`&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if echo $pf | grep $1 &gt; /dev/null 2&gt;&amp;1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; then&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; echo $pid&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /usr/bin/pargs $pid&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; fidone2。运行port.sh, 传入端口号，比如53250 :#&nbsp; /tmp/port.sh 532503。运行结果如下：12251225:&nbsp;&nbsp; /usr/lib/thunderbird/thunderbird-bin -UILocale zh-CN-contentLocale CNargv[0]: /usr/lib/thunderbird/thunderbird-binargv[1]:...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Linux" scheme="http://www.sixapart.com/ns/types#category" />
    
        <category term="OS" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="lsof" label="lsof" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="mdb" label="MDB" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="shell" label="shell" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="solaris" label="Solaris" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="tips" label="tips" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<i>From: <a href="http://blog.csdn.net/Adali/archive/2007/11/23/1899779.aspx" target="_blank">http://blog.csdn.net/Adali/archive/2007/11/23/1899779.aspx</a></i><br /><br /><font style="font-size: 1.5625em;"><b>Solaris平台上如何知道某个端口被哪个进程和应用程序占用</b></font><br /><br />我经常在Solaris服务器上启好几个Tomcat和GlassFish, 会遇到"端口"被占用的错误, 很难直接用命令得知这个端口到底被哪个进程或者应用程序占用了， Alex给了我三个解决方案。附带说一句，我只尝试了第一种方案，相当的好用。而Alex愿意花时间找解决方案，却不愿意花几分钟把这些好东西写出来，结果就是被我发表出来。功劳还是要归Alex Peng.<br /><br /><b>第一种方案：</b><br /><br />1。使用下面shell script，先建立一个port.sh文件:<br /><br /># more /tmp/port.sh<br /><br />#!/bin/sh<br /><br />for pid in `ls /proc`<br /><br />do<br /><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; pf=`/usr/bin/pfiles $pid 2&gt;/dev/null`<br /><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if echo $pf | grep $1 &gt; /dev/null 2&gt;&amp;1<br /><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; then<br /><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; echo $pid<br /><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /usr/bin/pargs $pid<br /><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; fi<br /><br />done<br /><br />2。运行port.sh, 传入端口号，比如53250 :<br /><br />#&nbsp; /tmp/port.sh 53250<br /><br />3。运行结果如下：<br /><br />1225<br /><br />1225:&nbsp;&nbsp; /usr/lib/thunderbird/thunderbird-bin -UILocale zh-CN<br /><br />-contentLocale CN<br /><br />argv[0]: /usr/lib/thunderbird/thunderbird-bin<br /><br />argv[1]: -UILocale<br /><br />argv[2]: zh-CN<br /><br />argv[3]: -contentLocale<br /><br />argv[4]: CN<br /><br />4212<br /><br />4212:&nbsp;&nbsp; /bin/sh /tmp/port.sh 53250<br /><br />argv[0]: /bin/sh<br /><br />argv[1]: /tmp/port.sh<br /><br />argv[2]: 53250<br /><br />&nbsp;<br /><b>第二种方案：</b><br /><br />下载"lsof" package。但可能不适合每种情况<br /><br /><br /><b>第三种方案：</b><br /><br />使用MDB<br /><br />&nbsp;&nbsp; from socket info (netstat output), you can know its vnode<br /><br />&nbsp;&nbsp; from vnode info, you can know which process owns it<br /><br />&nbsp;&nbsp; from process info, you can know its args, so comes the result.<br /><br />&nbsp;<br /><b>Reference</b><br /><br />lsof：<br /><br /><a href="http://dmiessler.com/study/lsof/" target="_blank">http://dmiessler.com/study/lsof/</a><br /><a href="http://freshmeat.net/projects/lsof/" target="_blank">http://freshmeat.net/projects/lsof/</a><br /><br />MDB：<br /><br /><a href="http://www.itpub.net/616592.html" target="_blank">Solaris™ Performance and Tools: DTrace and MDB Techniques for Solaris 10 and OpenSolaris </a><br /><br />]]>
        
    </content>
</entry>

<entry>
    <title>Introduction to Unix Communication Tools</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html" />
    <id>tag:www.heysky.net,2008:/digest//1.330</id>

    <published>2008-09-08T05:18:04Z</published>
    <updated>2008-09-08T05:39:51Z</updated>

    <summary>From: http://www.helpdesk.umd.edu/systems/glue/applications/pine/1112/ Introduction to Unix Communication Tools Logging in Remotely Transferring Files with Secure FTP Electronic Mail Real-Time Communication Refusing Real-Time Talks and Messages There are several communications and networking tools that are available on nearly every UNIX system. This...</summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Linux" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="command" label="command" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="linux" label="Linux" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="talk" label="talk" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="tools" label="tools" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="unix" label="Unix" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="write" label="write" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<p><em>From: </em><a href="http://www.helpdesk.umd.edu/systems/glue/applications/pine/1112/" target="_blank"><em>http://www.helpdesk.umd.edu/systems/glue/applications/pine/1112/</em></a></p>
<p>
<table cellspacing="0" cellpadding="0" width="100%" border="0">
<tbody>
<tr>
<td>
<h3 class="sectitle">Introduction to Unix Communication Tools</h3></td></tr>
<tr>
<td valign="top" bgcolor="#990000" colspan="2"><img height="1" alt="" src="http://www.helpdesk.umd.edu/web.support/headers/images/spacer.gif" width="1" /></td></tr>
<tr>
<td valign="top" width="25"><img height="10" alt="" src="http://www.helpdesk.umd.edu/web.support/headers/images/spacer.gif" width="25" /></td>
<td valign="top"><img height="10" alt="" src="http://www.helpdesk.umd.edu/web.support/headers/images/spacer.gif" width="25" /></td></tr>
<tr>
<td valign="top" width="25"><img height="10" alt="" src="http://www.helpdesk.umd.edu/web.support/headers/images/spacer.gif" width="25" /></td>
<td valign="top">
<ul>
<li><a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#login">Logging in Remotely</a> 
<li><a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#sftp">Transferring Files with Secure FTP</a> 
<li><a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#mail">Electronic Mail</a> 
<li><a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#talk">Real-Time Communication</a> 
<li><a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#mesgn">Refusing Real-Time Talks and Messages</a> </li></ul>
<p>There are several communications and networking tools that are available on nearly every UNIX system. This document will go over a handful of the more standard ones, including clients that allow you to <a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#login">login remotely</a>, <a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#sftp">transfer files</a>, send <a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#mail">e-mail</a>, and <a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#talk">talk</a> (or <a href="http://www.heysky.net/digest/2008/09/introduction-to-unix-communication-tools.html#mesgn">refuse</a> to talk) in real-time. </p></td></tr></tbody></table></p>]]>
        <![CDATA[<hr>
 
<h3><a id="login"></a>&nbsp;Logging in Remotely</h3>
<p>The ones that are used most often are telnet and rlogin, which let you login to the system remotely. Telnet is used most often. There are telnet clients available for nearly any platform, though usually UNIX systems are the only ones running a telnet server. Telneting into a UNIX machine will allow you to use a command line shell, including full screen display programs if your terminal is set up properly. Rlogin (short for Remote-LOGIN) looks similar to telnet on the surface, but uses a different set of protocols. More information is exchanged between the client and server during an rlogin session than during a telnet session. This gives it more functionality, but also creates some security risks if not used carefully. One of the main features of rlogin is the .rhosts file. This is a file that a user can have in his or her home directory that lists a set of machines and usernames that are to be considered "trusted". This allows the user to login to one of the trusted machines, and then rlogin into the main machine <strong>without</strong> supplying a password. I'm sure it's obvious at this point why .rhosts files should be used with care. Besides rlogin, there is a whole suite of remote applications including rcp (remote copy), rsh (remote shell) and rexec (remote execute) that rely on the .rhosts file to determine trusted users and machines. Telnet and rlogin are both executed from the command line, with the remote host address as an argument. </p>
<hr>

<h3><a id="sftp"></a>File Transfer</h3>
<p>Another useful tool is sftp, or Secure File Transfer Protocol. With an sftp client, you can log into any machine that is running an sftp server (no matter what platform) and transfer files back and forth. When you login using sftp, you do not get a shell command line, you stay within the sftp client, but you navigate the directories as if you were in a shell. Using the commands put and get you can transfer files to and from the remote host. One important thing to keep in mind is that executable programs, compressed files, and any other binary files <strong>must</strong> be transferred in binary mode. Most sftp clients default to ascii (text) mode, so to be safe type binary at the sftp&gt; prompt. Some sftp clients will determine the mode automatically. SFTP sessions can also be automated from a UNIX machine by using macros in your <a href="http://www.helpdesk.umd.edu/documents/1/1094/">.netrc</a> file. </p>
<hr>

<h3><a id="mail"></a>Electronic Mail</h3>
<p>There are several mailers available for UNIX systems. The standard mailer we use is Mail (invoked by mail --note the case; you see, our systems have 'mail' aliased to /usr/ucb/Mail in the default login files). Mail is very simple to use; essentially, you type 'mail' and you read any mail messages waiting for you. Sending mail is like- mail userid1 userid2...useridn. <strong>Note:</strong> do NOT put the carbon copies here; you put them at the end of the mail session, or inside the mail item (see below). If you put it on the command line, you try to send mail to user "cc:" which usually does not exist. </p>
<p>An alternative to the standard mailer is pine. Pine uses a full screen display, which most users find a lot easier to use than mail. It saves mail in "folders", giving you an inbox, saved-mail, and sent-mail folder by default, and allowing you to define other folders to categorize your mail with. </p>
<p>Another popular mail system available on our UNIX systems is MH. MH differs from Mail in that MH is a collection of small programs that you execute from the shell. MH is more powerful and customizable than Mail, and is on all of the CSC UNIX systems. </p>
<hr>

<h3><a id="talk"></a>Real-Time Communication</h3>
<p>On UNIX machines, you have two ways of communicating in real-time. The most preferred way is 'talk.' Talk is a two-way real-time communications program, letting you see what the other person types character-by-character (as opposed to the IBM mainframe, which is line by line). To initiate a talk, type <strong>talk userid@address [tty]</strong> (the @address part is not needed if you are talking to someone on the same machine as yourself, and the tty part is only necessary if you wish the message to go to a specific tty and not the first one the system finds). The other party will get a <strong>talk daemon</strong> message: </p><pre>Message from Talk_Daemon@lewhoosh.umd.edu at 17:46 ...&nbsp;
talk: connection requested by matthews@lewhoosh.umd.edu.&nbsp;
talk: respond with:&nbsp; talk matthews@lewhoosh.umd.edu</pre>
<p>...and he/she can either ignore the message and be bothered for a while, or respond with a talk command (the system will tell you what to type to answer the request -- "respond with:..."). We will ignore the fact that talking to oneself is a sign of impending doom. To end the talk session, just hit ^C (if nobody answers for a few 'rings,' then it's safe to assume they aren't going to). Note that your terminal must be set correctly (including type, number of rows, and number of columns) for a full- screen environment, else ... well, let's just say you won't like the results otherwise and leave it at that. If you get a message: </p><pre>[Checking for invitation on caller's machine]</pre>
<p>that could mean one of two things. One: The other machine is a Sun workstation running BSD 4.2 talk (while the rest of the world is running BSD 4.3 talk) and the protocol is not compatible. You can try to use the command "otalk" instead, for Old talk. If that doesn't work, then Two applies. And Two is: something is muffed up. It could be the network is down, or it could be the other system is having problems firing up the talk daemon. Either way it's related to the protocol not being met and there's nothing you can do about this situation except wait. If you get the message: </p><pre>Target machine is too confused to talk to us</pre>
<p>then you've discovered a funny error message most likely written by someone strung out on caffeine at 3 in the morning. </p>
<p>The other method of real-time communications on UNIX is the 'write' command. This will send a one-way message. The format is pretty much the same as the IBM mainframe's TELL command: write&nbsp; &lt;userid &gt;[tty], where&nbsp;&lt;userid &gt;is the user you want to communicate with and the optional tty specifies which tty to send the message to if/when the user is logged in more than once (otherwise, write will send it to the first one it finds). Note that write will not work across systems, so you have to be logged in to the same machine your recipient is on. When you first issue the command, the recipient will get a message telling him/her you are sending him/her a message. Then you type in your message and end it with a ^d (UNIX EOF), and the recipient will see it (they will get it line by line as well). You can also use i/o redirection (write&nbsp;&lt;userid &gt;&lt; message.file or echo&nbsp;&lt;message&gt;| write&nbsp;&lt;userid&gt;). </p>
<hr>

<h3><a id="mesgn"></a>How Not to Receive Messages</h3>
<p>The commands for enabling/disabling messages to your tty, and thus your screen, are mesg y/n. Some people like to put <strong>mesg n</strong>in their ~/.login file just to make sure that people won't interrupt them. This is the default setting for the WAM machines, so in order to receive real-time messages on WAM you need to give a "mesg y" command. </p>
<p>The command <tt><font face="Courier New">who</font></tt> will tell you who is on the machine that you are on, or you could use </p>
<p><tt><strong><font face="Courier New">finger @[machine-name]</font></strong></tt> </p>
<p>to see who is on a remote machine. In order to make sure you are not interrupting someone who is busy, the "w" command will tell you what people on your machine are doing. </p>
<p>One little bit of netiquette: try not to send writes or talk requests to people who do not want to be disturbed! This includes sending random messages to people you don't know just because you're bored, and also sending them to <strong>anybody</strong> who is using a full screen program, such as a text editor or maybe another talk session. </p>
<p>&nbsp;</p>
<p><em>From: </em><a href="http://en.wikipedia.org/wiki/Write_(Unix)" target="_blank"><em>http://en.wikipedia.org/wiki/Write_(Unix)</em></a><em>)</em></p>
<h1 class="firstHeading"><strong>write (Unix)</strong></h1>
<div id="bodyContent">From Wikipedia, the free encyclopedia<!-- start content --> <br /><br />
<p><code><strong><font face="Courier New">write</font></strong></code> can refer to several <a title="Unix" href="http://en.wikipedia.org/wiki/Unix">Unix</a> commands. All known variations of <code><font face="Courier New">write</font></code> are used to write messages to another user. The most popular variation sends a message directly to another user's <a title="TTY" href="http://en.wikipedia.org/wiki/TTY">TTY</a></p></div>
<h2><span class="mw-headline">Usage</span></h2>
<p>The correct syntax for the <code><font face="Courier New">write</font></code> command is:</p><pre>write <i>user</i> [<i>tty</i>]
<i>message</i>
</pre>
<p>The write session is terminated by sending <a title="End-of-file" href="http://en.wikipedia.org/wiki/End-of-file">EOF</a>, which can be done by pressing Ctrl+D. The <i>tty</i> argument is only necessary when a user is logged into more than one terminal.</p>
<p><a id="Example" name="Example"></a></p>
<h2><span class="mw-headline">Example</span></h2>
<p>A conversation initiated between two users on the same machine:</p><pre>11:19 AM# write root pts/7
test
</pre>
<p>Will show up to the user on that console as:</p><pre>Message from root@punch on pts/8 at 11:19 ...
test</pre>
<p><a id="History" name="History"></a></p>
<h2><span class="mw-headline">History</span></h2>
<p>A version of the write command appeared in the First Edition of the <a title="Research Unix" href="http://en.wikipedia.org/wiki/Research_Unix">Research Unix</a> operating system. Another variation of <code><font face="Courier New">write</font></code> writes a message to a user on a <a class="new" title="Windows network (page does not exist)" href="http://en.wikipedia.org/w/index.php?title=Windows_network&amp;action=edit&amp;redlink=1">Windows network</a>, using the <a title="Server Message Block" href="http://en.wikipedia.org/wiki/Server_Message_Block">SMB</a> packet format.</p>
<p><a class="mw-redirect" title="Programmer's Workbench UNIX" href="http://en.wikipedia.org/wiki/Programmer%27s_Workbench_UNIX">Programmer's Workbench UNIX</a> contained a program <tt><font face="Courier New">wall</font></tt> that wrote a message to all users in the same way.</p>
<p><a id="See_also" name="See_also"></a></p>
<h2><span class="mw-headline">See also</span></h2>
<ul>
<li><a class="mw-redirect" title="List of Unix programs" href="http://en.wikipedia.org/wiki/List_of_Unix_programs">List of Unix programs</a> 
<li><a class="mw-redirect" title="Talk (Unix)" href="http://en.wikipedia.org/wiki/Talk_(Unix)">talk</a> command </li></ul><!--include virtual="/cgi-bin/fast/showlinks.pl" --><!-- Next line (Blue box) to becommented out ?/?/08 -davida -->]]>
    </content>
</entry>

<entry>
    <title>Automatic SQL Tuning and SQL Profiles Internals in Oracle 10g</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2008/08/automatic-sql-tuning-and-sql-profiles-internals-in-oracle-10g.html" />
    <id>tag:www.heysky.net,2008:/digest//1.329</id>

    <published>2008-08-03T15:00:39Z</published>
    <updated>2008-08-03T16:14:52Z</updated>

    <summary>From: http://www.oracle-base.com/articles/10g/AutomaticSQLTuning10g.phpAutomatic SQL Tuning in Oracle Database 10g This article the discusses the new features which automate the tuning of SQL statements in Oracle 10g: OverviewSQL Tuning AdvisorManaging SQL ProfilesSQL Tuning SetsUseful Views Overview In its normal mode the query...</summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="10g" label="10g" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="advisor" label="Advisor" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="automaticsqltuning" label="Automatic SQL Tuning" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="cbo" label="CBO" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="executionplan" label="Execution Plan" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="hints" label="Hints" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="internal" label="Internal" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="performance" label="Performance" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="sqlprofiles" label="SQL Profiles" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="tuning" label="tuning" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<i>From: http://www.oracle-base.com/articles/10g/AutomaticSQLTuning10g.php</i><br /><br /><h1>Automatic SQL Tuning in Oracle Database 10g</h1>

This article the discusses the new features which automate the tuning of SQL statements in Oracle 10g:<br />

<ul><li><a href="http://www.oracle-base.com/articles/10g/AutomaticSQLTuning10g.php#overview">Overview</a></li><li><a href="http://www.oracle-base.com/articles/10g/AutomaticSQLTuning10g.php#sql_tuning_advisor">SQL Tuning Advisor</a></li><li><a href="http://www.oracle-base.com/articles/10g/AutomaticSQLTuning10g.php#managing_sql_profiles">Managing SQL Profiles</a></li><li><a href="http://www.oracle-base.com/articles/10g/AutomaticSQLTuning10g.php#sql_tuning_sets">SQL Tuning Sets</a></li><li><a href="http://www.oracle-base.com/articles/10g/AutomaticSQLTuning10g.php#useful_views">Useful Views</a></li></ul>

<h2>Overview</h2>
In its normal mode the query optimizer needs to make decisions about
execution plans in a very short time. As a result it may not always be
able to
obtain enough information to make the best decision. Oracle 10g allows
the optimizer to run in tuning mode where it can gather additional
information
and make recommendations about how specific statements can be tuned
further. This process may take several minutes for a single statement
so it is
intended to be used on high-load resource-intensive statements.<br />

<br />]]>
        <![CDATA[In tuning mode the optimizer performs the following analysis:<br />


<ul><li>Statistics Analysis - The optimizer recommends the
gathering of statistics on objects with missing or stale statistics.
Additional statistics for these objects are stored in an SQL profile.<br /><br /></li><li>SQL
Profiling - The optimizer may be able to improve performance by
gathering additional statistics and altering session specific
parameters such as the <code>OPTIMIZER_MODE</code>. If such improvements are
possible the information is stored in an SQL profile. If accepted this
information can then used by the optimizer when running in normal mode.
Unlike a stored outline which fixes the execution plan, an SQL profile
may still be of benefit when the contents of the table alter
drastically. Even so, it's sensible to update profiles periodically.
The SQL profiling is not performed when the tuining optimizer is run in
limited mode.<br /><br /></li><li>Access Path Analysis -
The optimizer investigates the effect of new or modified indexes on the
access path. It's index recommendations relate to a specific statement
so where necessary it will also suggest the use of the SQL Access
Advisor to check the impact of these indexes on a representative SQL
workload.<br /><br /></li><li>SQL
Structure Analysis - The optimizer suggests alternatives for SQL
statements that contain structures that may impact on performance. The
implementation of these suggestions requires human intervention to
check their validity.</li></ul>

The automatic SQL tuning features are accessible from Enterprise
Manager on the "Advisor Central" page these or from PL/SQL using the <code>DBMS_SQLTUNE</code> package.
This article will focus on the PL/SQL API as the Enterprise Manager interface is reasonably intuative.<br />



<h2>SQL Tuning Advisor</h2>


In order to access the SQL tuning advisor API a user must be granted the <code>ADVISOR</code> privilege:<br />


<blockquote><pre>CONN sys/password AS SYSDBA<br />GRANT ADVISOR TO scott;<br />CONN scott/tiger</pre></blockquote>


The first step when using the SQL tuning advisor is to create a new tuning task using the <code>CREATE_TUNING_TASK</code>
function. The statements to be
analyzed can be retrieved from the Automatic Workload Repository (AWR),
the cursor cache, an SQL tuning set or specified manually:<br />


<blockquote><pre>SET SERVEROUTPUT ON<br /><br />-- Tuning task created for specific a statement from the AWR.<br />DECLARE<br />  l_sql_tune_task_id  VARCHAR2(100);<br />BEGIN<br />  l_sql_tune_task_id := DBMS_SQLTUNE.create_tuning_task (<br />                          begin_snap  =&gt; 764,<br />                          end_snap    =&gt; 938,<br />                          sql_id      =&gt; '19v5guvsgcd1v',<br />                          scope       =&gt; DBMS_SQLTUNE.scope_comprehensive,<br />                          time_limit  =&gt; 60,<br />                          task_name   =&gt; '19v5guvsgcd1v_AWR_tuning_task',<br />                          description =&gt; 'Tuning task for statement 19v5guvsgcd1v in AWR.');<br />  DBMS_OUTPUT.put_line('l_sql_tune_task_id: ' || l_sql_tune_task_id);<br />END;<br />/<br /><br />-- Tuning task created for specific a statement from the cursor cache.<br />DECLARE<br />  l_sql_tune_task_id  VARCHAR2(100);<br />BEGIN<br />  l_sql_tune_task_id := DBMS_SQLTUNE.create_tuning_task (<br />                          sql_id      =&gt; '19v5guvsgcd1v',<br />                          scope       =&gt; DBMS_SQLTUNE.scope_comprehensive,<br />                          time_limit  =&gt; 60,<br />                          task_name   =&gt; '19v5guvsgcd1v_tuning_task',<br />                          description =&gt; 'Tuning task for statement 19v5guvsgcd1v.');<br />  DBMS_OUTPUT.put_line('l_sql_tune_task_id: ' || l_sql_tune_task_id);<br />END;<br />/<br /><br />-- Tuning task created from an SQL tuning set.<br />DECLARE<br />  l_sql_tune_task_id  VARCHAR2(100);<br />BEGIN<br />  l_sql_tune_task_id := DBMS_SQLTUNE.create_tuning_task (<br />                          sqlset_name =&gt; 'test_sql_tuning_set',<br />                          scope       =&gt; DBMS_SQLTUNE.scope_comprehensive,<br />                          time_limit  =&gt; 60,<br />                          task_name   =&gt; 'sqlset_tuning_task',<br />                          description =&gt; 'Tuning task for an SQL tuning set.');<br />  DBMS_OUTPUT.put_line('l_sql_tune_task_id: ' || l_sql_tune_task_id);<br />END;<br />/<br /><br />-- Tuning task created for a manually specified statement.<br />DECLARE<br />  l_sql               VARCHAR2(500);<br />  l_sql_tune_task_id  VARCHAR2(100);<br />BEGIN<br />  l_sql := 'SELECT e.*, d.* ' ||<br />           'FROM   emp e JOIN dept d ON e.deptno = d.deptno ' ||<br />           'WHERE  NVL(empno, ''0'') = :empno';<br /><br />  l_sql_tune_task_id := DBMS_SQLTUNE.create_tuning_task (<br />                          sql_text    =&gt; l_sql,<br />                          bind_list   =&gt; sql_binds(anydata.ConvertNumber(100)),<br />                          user_name   =&gt; 'scott',<br />                          scope       =&gt; DBMS_SQLTUNE.scope_comprehensive,<br />                          time_limit  =&gt; 60,<br />                          task_name   =&gt; 'emp_dept_tuning_task',<br />                          description =&gt; 'Tuning task for an EMP to DEPT join query.');<br />  DBMS_OUTPUT.put_line('l_sql_tune_task_id: ' || l_sql_tune_task_id);<br />END;<br />/</pre></blockquote>


If the <code>TASK_NAME</code> parameter is specified it's value is returned as the SQL tune task identifier. If ommitted a system generated name
like "TASK_1478" is returned. If the <code>SCOPE</code> parameter is set to <code>scope_limited</code> the SQL profiling analysis is omitted. The
<code>TIME_LIMIT</code> parameter simply restricts the time the optimizer can spend compiling the recommendations.<br />


<br />


The following examples will reference the last tuning set as it has no external dependancies other than the SCOTT schema. The <code>NVL</code>
in the
SQL statement was put in to provoke a reaction from the optimizer. In
addition we can delete the statistics from one of the tables to provoke
it even more:<br />


<blockquote><pre>EXEC DBMS_STATS.delete_table_stats('SCOTT','EMP');</pre></blockquote>


With the tuning task defined the next step is to execute it using the <code>EXECUTE_TUNING_TASK</code> procedure:<br />


<blockquote><pre>EXEC DBMS_SQLTUNE.execute_tuning_task(task_name =&gt; 'emp_dept_tuning_task');</pre></blockquote>

During the execution phase you may wish to pause and restart the task,
cancel it or reset the task to allow it to be re-executed:<br />


<blockquote><pre>-- Interrupt and resume a tuning task.<br />EXEC DBMS_SQLTUNE.interrupt_tuning_task (task_name =&gt; 'emp_dept_tuning_task');<br />EXEC DBMS_SQLTUNE.resume_tuning_task (task_name =&gt; 'emp_dept_tuning_task');<br /><br />-- Cancel a tuning task.<br />EXEC DBMS_SQLTUNE.cancel_tuning_task (task_name =&gt; 'emp_dept_tuning_task');<br /><br />-- Reset a tuning task allowing it to be re-executed.<br />EXEC DBMS_SQLTUNE.reset_tuning_task (task_name =&gt; 'emp_dept_tuning_task');</pre></blockquote>


The status of the tuning task can be monitored using the <code>DBA_ADVISOR_LOG</code> view:<br />


<blockquote><pre>SELECT task_name, status FROM dba_advisor_log WHERE owner = 'SCOTT';<br /><br />TASK_NAME                      STATUS<br />------------------------------ -----------<br />emp_dept_tuning_task           COMPLETED<br /><br />1 row selected.</pre></blockquote>


Once the tuning task has executed successfully the recommendations can be displayed using the <code>REPORT_TUNING_TASK</code> function:<br />


<blockquote><pre>SET LONG 10000;<br />SET PAGESIZE 1000<br />SET LINESIZE 200<br />SELECT DBMS_SQLTUNE.report_tuning_task('emp_dept_tuning_task') AS recommendations FROM dual;<br />SET PAGESIZE 24</pre></blockquote>


In this case the output looks like this:<br />


<blockquote><pre>RECOMMENDATIONS<br />--------------------------------------------------------------------------------<br />GENERAL INFORMATION SECTION<br />-------------------------------------------------------------------------------<br />Tuning Task Name   : emp_dept_tuning_task<br />Scope              : COMPREHENSIVE<br />Time Limit(seconds): 60<br />Completion Status  : COMPLETED<br />Started at         : 05/06/2004 09:29:13<br />Completed at       : 05/06/2004 09:29:15<br /><br />-------------------------------------------------------------------------------<br />SQL ID  : 0wrmfv2yvswx1<br />SQL Text: SELECT e.*, d.* FROM   emp e JOIN dept d ON e.deptno = d.deptno<br />          WHERE  NVL(empno, '0') = :empno<br /><br />-------------------------------------------------------------------------------<br />FINDINGS SECTION (2 findings)<br />-------------------------------------------------------------------------------<br /><br />1- Statistics Finding<br />---------------------<br />  Table "SCOTT"."EMP" and its indices were not analyzed.<br /><br />  Recommendation<br />  --------------<br />    Consider collecting optimizer statistics for this table and its indices.<br />    execute dbms_stats.gather_table_stats(ownname =&gt; 'SCOTT', tabname =&gt;<br />            'EMP', estimate_percent =&gt; DBMS_STATS.AUTO_SAMPLE_SIZE,<br />            method_opt =&gt; 'FOR ALL COLUMNS SIZE AUTO', cascade =&gt; TRUE)<br /><br />  Rationale<br />  ---------<br />    The optimizer requires up-to-date statistics for the table and its indices<br />    in order to select a good execution plan.<br /><br />2- Restructure SQL finding (see plan 1 in explain plans section)<br />----------------------------------------------------------------<br />  The predicate NVL("E"."EMPNO",0)=:B1 used at line ID 2 of the execution plan<br />  contains an expression on indexed column "EMPNO". This expression prevents<br />  the optimizer from selecting indices on table "SCOTT"."EMP".<br /><br />  Recommendation<br />  --------------<br />    Rewrite the predicate into an equivalent form to take advantage of<br />    indices. Alternatively, create a function-based index on the expression.<br /><br />  Rationale<br />  ---------<br />    The optimizer is unable to use an index if the predicate is an inequality<br />    condition or if there is an expression or an implicit data type conversion<br />    on the indexed column.<br /><br />-------------------------------------------------------------------------------<br />EXPLAIN PLANS SECTION<br />-------------------------------------------------------------------------------<br /><br />1- Original<br />-----------<br />Plan hash value: 1863486531<br /><br />----------------------------------------------------------------------------------------<br />| Id  | Operation                    | Name    | Rows  | Bytes | Cost (%CPU)| Time     |<br />----------------------------------------------------------------------------------------<br />|   0 | SELECT STATEMENT             |         |     1 |   107 |     4   (0)| 00:00:01 |<br />|   1 |  NESTED LOOPS                |         |     1 |   107 |     4   (0)| 00:00:01 |<br />|   2 |   TABLE ACCESS FULL          | EMP     |     1 |    87 |     3   (0)| 00:00:01 |<br />|   3 |   TABLE ACCESS BY INDEX ROWID| DEPT    |     1 |    20 |     1   (0)| 00:00:01 |<br />|   4 |    INDEX UNIQUE SCAN         | PK_DEPT |     1 |       |     0   (0)| 00:00:01 |<br />----------------------------------------------------------------------------------------<br /><br />Note<br />-----<br />   - dynamic sampling used for this statement<br /><br />-------------------------------------------------------------------------------<br /><br /><br />1 row selected.</pre></blockquote>


Once the tuning session is over the tuning task can be dropped using the <code>DROP_TUNING_TASK</code> procedure:<br />


<blockquote><pre>BEGIN<br />  DBMS_SQLTUNE.drop_tuning_task (task_name =&gt; '19v5guvsgcd1v_AWR_tuning_task');<br />  DBMS_SQLTUNE.drop_tuning_task (task_name =&gt; '19v5guvsgcd1v_tuning_task');<br />  DBMS_SQLTUNE.drop_tuning_task (task_name =&gt; 'sqlset_tuning_task');<br />  DBMS_SQLTUNE.drop_tuning_task (task_name =&gt; 'emp_dept_tuning_task');<br />END;<br />/</pre></blockquote>



<h2>Managing SQL Profiles</h2>


To manage SQL profiles a user needs the following privileges:<br />


<blockquote><pre>CONN sys/password AS SYSDBA<br />GRANT CREATE ANY SQL PROFILE TO scott;<br />GRANT DROP ANY SQL PROFILE TO scott;<br />GRANT ALTER ANY SQL PROFILE TO scott;<br />CONN scott/tiger</pre></blockquote>


If the recommendations of the SQL tuning advisor include a suggested profile you can choose to accept it using the <code>ACCEPT_SQL_PROFILE</code> procedure:<br />


<blockquote><pre>SET SERVEROUTPUT ON<br />DECLARE<br />  l_sql_tune_task_id  VARCHAR2(20);<br />BEGIN<br />  l_sql_tune_task_id := DBMS_SQLTUNE.accept_sql_profile (<br />                          task_name =&gt; 'emp_dept_tuning_task',<br />                          name      =&gt; 'emp_dept_profile');<br />  DBMS_OUTPUT.put_line('l_sql_tune_task_id: ' || l_sql_tune_task_id);<br />END;<br />/</pre></blockquote>


The <code>NAME</code> parameter is used to specify a name for the profile. If it is not specified a system generated name will be used.<br />


<br />


The <code>STATUS</code>, <code>NAME</code>, <code>DESCRIPTION</code>, and <code>CATEGORY</code> attributes of an SQL profile can be altered using the
<code>ALTER_SQL_PROFILE</code> procedure:<br />


<blockquote><pre>BEGIN<br />  DBMS_SQLTUNE.alter_sql_profile (<br />    name            =&gt; 'emp_dept_profile',<br />    attribute_name  =&gt; 'STATUS',<br />    value           =&gt; 'DISABLED');<br />END;<br />/</pre></blockquote>


Existing SQL profiles can be dropped using the <code>DROP_SQL_PROFILE</code> procedure:<br />


<blockquote><pre>BEGIN<br />  DBMS_SQLTUNE.drop_sql_profile (<br />    name   =&gt; 'emp_dept_profile',<br />    ignore =&gt; TRUE);<br />END;<br />/</pre></blockquote>


The <code>IGNORE</code> parameter prevents errors being reported if the specified profile does not exist.<br />



<h2>SQL Tuning Sets</h2>

An SQL tuning set is a group of statements along with their execution
context. These can be created automatically via Enterprise Manager or
manually provided
you have the necessary privileges:<br />


<blockquote><pre>CONN sys/password AS SYSDBA<br />GRANT ADMINISTER ANY SQL TUNING SET TO scott;<br />CONN scott/tiger</pre></blockquote>


An SQL tuning set is created using the <code>CREATE_SQLSET</code> procedure:<br />


<blockquote><pre>BEGIN<br />  DBMS_SQLTUNE.create_sqlset (<br />    sqlset_name  =&gt; 'test_sql_tuning_set',<br />    description  =&gt; 'A test SQL tuning set.');<br />END;<br />/</pre></blockquote>


Statements are added to the set using the <code>LOAD_SQLSET</code> procedure which accepts a <code>REF CURSOR</code> of statements retrieved
using one of the following pipelined functions:<br />


<ul><li><code>SELECT_WORKLOAD_REPOSITORY</code> - Retrieves statements from the Automatic Workload Repository (AWR).</li><li><code>SELECT_CURSOR_CACHE</code> - Retrieves statements from the cursor cache.</li><li><code>SELECT_SQLSET</code> - Retrieves statements from another SQL tuning set.</li></ul>


The following are examples of their usage:<br />


<blockquote><pre>-- Load the SQL set from the Automatic Workload Repository (AWR).<br />DECLARE<br />  l_cursor  DBMS_SQLTUNE.sqlset_cursor;<br />BEGIN<br />  OPEN l_cursor FOR<br />    SELECT VALUE(p)<br />    FROM   TABLE (DBMS_SQLTUNE.select_workload_repository (<br />                    765,  -- begin_snap<br />                    766,  -- end_snap<br />                    NULL, -- basic_filter<br />                    NULL, -- object_filter<br />                    NULL, -- ranking_measure1<br />                    NULL, -- ranking_measure2<br />                    NULL, -- ranking_measure3<br />                    NULL, -- result_percentage<br />                    10)   -- result_limit<br />                  ) p;<br /><br />  DBMS_SQLTUNE.load_sqlset (<br />    sqlset_name     =&gt; 'test_sql_tuning_set',<br />    populate_cursor =&gt; l_cursor);<br />END;<br />/<br /><br />-- Load the SQL set from the cursor cache.<br />DECLARE<br />  l_cursor  DBMS_SQLTUNE.sqlset_cursor;<br />BEGIN<br />  OPEN l_cursor FOR<br />    SELECT VALUE(p)<br />    FROM   TABLE (DBMS_SQLTUNE.select_cursor_cache (<br />                    NULL, -- basic_filter<br />                    NULL, -- object_filter<br />                    NULL, -- ranking_measure1<br />                    NULL, -- ranking_measure2<br />                    NULL, -- ranking_measure3<br />                    NULL, -- result_percentage<br />                    1)    -- result_limit<br />                  ) p;<br /><br />  DBMS_SQLTUNE.load_sqlset (<br />    sqlset_name     =&gt; 'test_sql_tuning_set',<br />    populate_cursor =&gt; l_cursor);<br />END;<br />/<br /><br />-- Create a new set and load it from the existing one.<br />DECLARE<br />  l_cursor  DBMS_SQLTUNE.sqlset_cursor;<br />BEGIN<br />  DBMS_SQLTUNE.create_sqlset(<br />    sqlset_name  =&gt; 'test_sql_tuning_set_2',<br />    description  =&gt; 'Another test SQL tuning set.');<br /><br />  OPEN l_cursor FOR<br />    SELECT VALUE(p)<br />    FROM   TABLE (DBMS_SQLTUNE.select_sqlset (<br />                    'test_sql_tuning_set', -- sqlset_name<br />                    NULL,                  -- basic_filter<br />                    NULL,                  -- object_filter<br />                    NULL,                  -- ranking_measure1<br />                    NULL,                  -- ranking_measure2<br />                    NULL,                  -- ranking_measure3<br />                    NULL,                  -- result_percentage<br />                    NULL)                  -- result_limit<br />                  ) p;<br /><br />  DBMS_SQLTUNE.load_sqlset (<br />    sqlset_name     =&gt; 'test_sql_tuning_set_2',<br />    populate_cursor =&gt; l_cursor);<br />END;<br />/</pre></blockquote>


The contents of an SQL tuning set can be displayed using the <code>SELECT_SQLSET</code> function:<br />


<blockquote><pre>SELECT *<br />FROM   TABLE(DBMS_SQLTUNE.select_sqlset ('test_sql_tuning_set'));</pre></blockquote>


References can be added to a set to indicate its usage by a client using the <code>ADD_SQLSET_REFERENCE</code> function. The resulting reference ID
can be used to remove it using the <code>REMOVE_SQLSET_REFERENCE</code> procedure:<br />


<blockquote><pre>DECLARE<br />  l_ref_id  NUMBER;<br />BEGIN<br />  -- Add a reference to a set.<br />  l_ref_id := DBMS_SQLTUNE.add_sqlset_reference (<br />    sqlset_name =&gt; 'test_sql_tuning_set',<br />    reference   =&gt; 'Used for manual tuning by SQL*Plus.');<br /><br />  -- Delete the reference.<br />  DBMS_SQLTUNE.remove_sqlset_reference (<br />    sqlset_name  =&gt; 'test_sql_tuning_set',<br />    reference_id =&gt; l_ref_id);<br />END;<br />/</pre></blockquote>


The <code>UPDATE_SQLSET</code> procedure is used to update specific string (<code>MODULE</code> and <code>ACTION</code>) and number
(<code>PRIORITY</code> and <code>PARSING_SCHEMA_ID</code>) attributes of specific statements within a set:<br />


<blockquote><pre>BEGIN<br />  DBMS_SQLTUNE.update_sqlset (<br />    sqlset_name     =&gt; 'test_sql_tuning_set',<br />    sql_id          =&gt; '19v5guvsgcd1v',<br />    attribute_name  =&gt; 'ACTION',<br />    attribute_value =&gt; 'INSERT');<br />END;<br />/</pre></blockquote>


The contents of a set can be trimmed down or deleted completely using the <code>DELETE_SQLSET</code> procedure:<br />


<blockquote><pre>BEGIN<br />  -- Delete statements with less than 50 executions.<br />  DBMS_SQLTUNE.delete_sqlset (<br />    sqlset_name  =&gt; 'test_sql_tuning_set',<br />    basic_filter =&gt; 'executions &lt; 50');<br /><br />  -- Delete all statements.<br />  DBMS_SQLTUNE.delete_sqlset (<br />    sqlset_name  =&gt; 'test_sql_tuning_set');<br />END;<br />/</pre></blockquote>


Tuning sets can be dropped using the <code>DROP_SQLSET</code> procedure:<br />


<blockquote><pre>BEGIN<br />  DBMS_SQLTUNE.drop_sqlset (sqlset_name =&gt; 'test_sql_tuning_set');<br />  DBMS_SQLTUNE.drop_sqlset (sqlset_name =&gt; 'test_sql_tuning_set_2');<br />END;<br />/</pre></blockquote>



<h2>Useful Views</h2>


Useful views related to automatic SQL tuning include:<br />


<ul><li><code>DBA_ADVISOR_TASKS</code></li><li><code>DBA_ADVISOR_FINDINGS</code></li><li><code>DBA_ADVISOR_RECOMMENDATIONS</code></li><li><code>DBA_ADVISOR_RATIONALE</code></li><li><code>DBA_SQLTUNE_STATISTICS</code></li><li><code>DBA_SQLTUNE_BINDS</code></li><li><code>DBA_SQLTUNE_PLANS</code></li><li><code>DBA_SQLSET</code></li><li><code>DBA_SQLSET_BINDS</code></li><li><code>DBA_SQLSET_STATEMENTS</code></li><li><code>DBA_SQLSET_REFERENCES</code></li><li><code>DBA_SQL_PROFILES</code></li><li><code>V$SQL</code></li><li><code>V$SQLAREA</code></li><li><code>V$ACTIVE_SESSION_HISTORY</code></li></ul>


For further information see:<br />


<ul><li><a href="http://download-west.oracle.com/docs/cd/B13789_01/server.101/b10752/sql_tune.htm">Automatic SQL Tuning</a></li><li><a href="http://download-west.oracle.com/docs/cd/B13789_01/appdev.101/b10802/d_sqltun.htm">DBMS_SQLTUNE</a></li></ul>


Hope this helps. Regards Tim...<br /><br /><br /><i>From http://jonathanlewis.wordpress.com/2007/02/11/profiles/<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; http://jonathanlewis.wordpress.com/2007/02/12/sql-profiles-2/<br />By Jonathan Lewis</i><br /><br /><h3 class="storytitle"><a href="http://jonathanlewis.wordpress.com/2007/02/11/profiles/" rel="bookmark">SQL Profiles&nbsp;(10g)</a></h3><p>When the <em><strong>Tuning Advisor</strong></em> suggests that you accept a <strong><em>SQL Profile</em></strong>, what is it offering you.&nbsp;If you want to find out, the following SQL seems to be the appropriate query to run <strong><span style="text-decoration: underline;">before</span></strong> you accept the profile:<br />
<span id="more-192"></span></p>
<pre><code><br />select<br />	rat.attr1<br />from<br />	wri$_adv_tasks		tsk,<br />	wri$_adv_rationale	rat<br />where<br />	tsk.name = {sql tuning task name}<br />and	rat.task_id   = tsk.id<br />;<br /></code></pre>
<p>The <em>{sql tuning task name}</em> will be the task name generated
and printed at the top of the Enterprisie Manager screen where you can
see the recommendations. The output might list a few lines like the
following:</p>
<pre><code><br />OPT_ESTIMATE(@"SEL$1",INDEX_SCAN, "REQUESTS"@"SEL$1",REQ_UK,SCALE_ROWS=5.786002118 )<br />OPT_ESTIMATE(@"SEL$1", TABLE, "REQUESTS"@"SEL$1",SCALE_ROWS=0.0004355485551)<br /></code></pre>
<p>These are actually hints - they will be accepted if you include them
in the usual fashion in your SQL (although that wouldn't be a good idea
at present as they are undocumented, unsupported, and liable to change
in their implementation).</p>
<p>Like <strong><em>Stored Outlines</em></strong>, the <strong><em>SQL Profile</em></strong>
consists of a stored SQL statement, and a set of hints that will be
brought into play when that SQL has to be optimised. Unlike <strong><em>Stored Outlines</em></strong>, the hints for <strong><em>SQL Profiles</em></strong>
do not attempt to dictate execution mechanisms directly. Instead they
supply arithmetical correction factors to the optimizer as it does its
arithemetic as, even with a 100% sample size, it is still possible for
the optimizer to misinterpret your statistics and produce an unsuitable
execution path.</p>
<p>In principle, if the data <strong><em>distributions</em></strong> do
not change, then a stored profile will ensure that the optimizer
"understands" your data and does the right thing - even when the data <strong><em>volume</em></strong> changes.</p><br /><h3 class="storytitle"><a href="http://jonathanlewis.wordpress.com/2007/02/12/sql-profiles-2/" rel="bookmark">SQL Profiles -&nbsp;2</a></h3>
	

	
		<p>Following <a href="http://jonathanlewis.wordpress.com/2007/02/11/profiles/" target="_self">yesterday's note </a>on <strong><em>SQL Profiles</em></strong>, someone asked how I detect that an <strong><em>opt_estimate</em></strong> hint had been used - with specific reference to the <strong><em>"index_scan"</em></strong> option. The reason for this particular choice is that other <strong><em>opt_estimate</em></strong> hints have a highly visible impact in the 10053 trace files, but this one doesn't.</p>
<p><span id="more-193"></span>Here are a few extracts from the <strong><em>Single Table Access</em></strong> section of the trace:</p>
<p>a) Following: <strong><em>opt_estimate(@sel$1, table, t1@sel$1, scale_rows=10)</em></strong> (multiply row count by 10)</p>
<pre><code>   Table: T1  Alias: T1<br />    Card: Original: 4000    &gt;&gt; Single Tab Card adjusted from: 10.00  to: 100.00<br />  Rounded: 100  Computed: 100.00  Non Adjusted: 10.00      <br /><br /></code></pre>
<p>b) Following: <strong><em>opt_estimate(@sel$1, join, (t2@sel$1, t1@sel$1), scale_rows=225)</em></strong> (multiply join cardinality by 225)</p>
<pre><code>&gt;&gt; Join Card adjusted from 0.00  to: 1.00, prelen=2<br />Adjusted Join Cards: adjRatio=2666.67 cardHjSmj=1.00 cardHjSmjNPF=1.00<br /></code><code>cardNlj=1.00 cardNSQ=1.00 cardNSQ_na=0.00<br /></code></pre>
<p>As you can see, the impact of the <strong><em>opt_estimate()</em></strong> shows up very clearly in these two cases, but when we try: <em><strong>opt_estimate(@sel$1, index_scan, t1@sel$1, t1_i1, scale_rows=0.05)</strong></em> (divide index selectivity by 20), we have to check the before and after trace files:<br />
Before:</p>
<pre><code>   Access Path: index (AllEqRange)<br />    Index: T1_I1<br />    resc_io: 168.00  resc_cpu: 1278402<br />    ix_sel: 0.05  ix_sel_with_filters: 0.05<br />    Cost: 168.19  Resp: 168.19  Degree: 1<br />  Best:: AccessPath: IndexRange  Index: T1_I1<br />         Cost: 168.19  Degree: 1  Resp: 168.19  Card: 10.00  Bytes: 0     <br /><br /></code></pre>
<p>After:</p>
<pre><code>   Access Path: index (AllEqRange)<br />    Index: T1_I1<br />    resc_io: 12.00  resc_cpu: 89967<br />    ix_sel: 0.0025  ix_sel_with_filters: 0.0025<br />    Cost: 12.01  Resp: 12.01  Degree: 1<br />  Best:: AccessPath: IndexRange  Index: T1_I1<br />         Cost: 12.01  Degree: 1  Resp: 12.01  Card: 10.00  Bytes: 0     <br /><br /></code></pre>
<p>In this case, we don't get any indication of <em>"adjusted values"</em>
- we actually have to check the before and after to see what has
changed - and infer from the drop in cost that we have used a reduced
cardinality. This can be particularly awkward to interpret in cases
where the targetted index is not a suitable candidate for a <em>single table access path</em>, but becomes available as an access path later in the join evolution.</p>DBMS_SQLTUNE.ACCEPT_SQL_PROFILE (<br />task_name =&gt; '',<br />category =&gt; 'MY_CATEGORY');<br /><br />ALTER SESSION SET SQLTUNE_CATEGORY='MY_CATEGORY' ;<br /><br />Once satisfied with Plan, change category to default.<br /><br />Comment by JM -- May 29, 2008 @ 6:27 pm UTC May 29,2008 <br /><br />Yuri,<br /><br />The view dba_sql_profiles lists the profiles. The text of the query is stored as a CLOB column called sql_text in this view.<br /><br />If you have lots of profiles and it's hard to find the relevant profile by querying this table, you could use explain plan to generate an execution plan for the query. It should report (in the notes section) something like:<br /><br />SQL profile "SYS_SQLPROF_01456abbc16a4000″ used for this statement<br /><br />I think the value reported is stored as the name in the view.<br /><br />Comment by Jonathan Lewis -- January 28, 2008 @ 10:25 pm UTC Jan 28,2008<br /><br />Thank for your answer!<br />But I'm interest in some different thing.<br />I'm curious in which form does the SQL Profile been stored?<br />And upon which SQL Profile information bases the cardinality adjustment done<br />by CBO,<br />such as "Single Tab Card adjusted from:11.441291 to:28.000000″.<br />I know some about SQL Profile, for example<br /><br />SQL&gt; select p.other_xml<br />2 from dba_sqltune_plans p, dba_sql_profiles s<br />3 where p.task_id=s.task_id<br />4 and s.name='profile_lastdoc_1′<br />5 and p.attribute='Using SQL profile'<br />6 and p.id=1;<br /><br />But in this column I can`t find anything about cardinality adjustment factor.<br /><br />Comment by Yuri A.P. -- January 29, 2008 @ 8:39 pm UTC Jan 29,2008<br /><br />The content of the SQL profile is not stored in a "public" view, but it can be found in table sql$profattr - for example:<br /><br />select<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sp.sp_name, sa.attr#, sa.attr_val<br />from<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sqlprof$&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sp,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sqlprof$attr&nbsp; sa<br />where<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sp.signature = sa.signature<br />and&nbsp;&nbsp;&nbsp;&nbsp; sp.category&nbsp; = sp.category<br />order by<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sp.sp_name,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sa.attr#<br />;<br /><br />SP_NAME&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ATTR#<br />------------------------------ ----------<br />ATTR_VAL<br />-------------------------------------------------------------------------<br />SYS_SQLPROF_0145f1e5167c4000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1<br />OPT_ESTIMATE(@"SEL$1", JOIN, ("T2"@"SEL$1", "T1"@"SEL$1"), SCALE_ROWS=15)<br /><br />SYS_SQLPROF_0145f1e5167c4000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2<br />OPT_ESTIMATE(@"SEL$1", TABLE, "T2"@"SEL$1", SCALE_ROWS=200)<br /><br />SYS_SQLPROF_0145f1e5167c4000&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 3<br />OPTIMIZER_FEATURES_ENABLE(default)<br /><br />In this example, we have two adjustments - the single table cardinality of table t2 in query block sel$1 should be multiplied by 200; and the join cardinality of (t1,t2) when they are joined in query block sel$1 should be multiplied by 15.<br /><br />Comment by Jonathan Lewis -- January 29, 2008 @ 10:22 pm UTC Jan 29,2008<br /><br />Thank you very much!<br />By the way, I have discovered that on 11g database such information can be retrieved from non-documented view DBMSHSXP_SQL_PROFILE_ATTR.<br /><br />Comment by Yuri A.P. -- January 30, 2008 @ 8:34 pm UTC Jan 30,2008<br /><br /><br /><font face="helvetica"><table border="0" cellpadding="0" cellspacing="6" width="80%"><tbody><tr><td align="right" valign="top">Subject: </td>
<td colspan="4" align="left"><strong>Automatic SQL Tuning - SQL Profiles</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="top"><a href="https://metalink.oracle.com/help/usaeng/Search/search.html#file">Doc ID</a>: </td>
<td align="left"><strong>Note:271196.1</strong></td>
<td align="right" valign="top">Type: </td>
<td align="left"><strong>BULLETIN</strong></td>
</tr>
<tr>
<td>&nbsp;</td>
<td align="right" valign="top">Last Revision Date: </td>
<td align="left"><strong>29-JUL-2008</strong></td>
<td align="right" valign="top">Status: </td>
<td align="left"><strong>PUBLISHED</strong></td>
</tr>
</tbody></table>
</font>
<pre><font face="courier"><br />Checked for relevance on 12-May-2008.<br /><br />Clarification/Explanation<br />==========================<br /><br />The query optimizer can sometimes produce inaccurate estimates about <br />an attribute of a statement due to lack of information,leading to poor<br />execution plans.  Traditionally, users have corrected  this problem by<br />manually adding hints to the application code to guide the optimizer <br />into making correct decisions. For packaged applications, changing <br />application code is not an option and the only alternative available <br />is to log a bug with the application vendor and wait for a fix.<br /><br />Automatic SQL Tuning deals with this problem with its SQL Profiling <br />capability. The Automatic Tuning Optimizer creates a profile of the <br />SQL statement called a SQL Profile, consisting of auxiliary statistics <br />specific to that statement. The query optimizer under normal mode makes <br />estimates about cardinality, selectivity, and cost that can sometimes be <br />off by a significant amount resulting in poor execution plans. SQL Profile <br />addresses this problem by collecting additional information using<br />sampling and partial execution techniques to verify and, if necessary, <br />adjust these estimates.<br /><br />During SQL Profiling, the Automatic Tuning Optimizer also uses execution<br />history information of the SQL statement to appropriately set optimizer <br />parameter settings, such as changing the OPTIMIZER_MODE initialization <br />parameter setting from ALL_ROWS to FIRST_ROWS for that SQL statement.<br /><br />The output of this type of analysis is a recommendation to accept the <br />SQL Profile. A SQL Profile, once accepted, is stored persistently in <br />the data dictionary. Note that the SQL Profile is specific to a <br />particular query. If accepted, the optimizer under normal mode uses the <br />information in the SQL Profile in conjunction with regular<br />database statistics when generating an execution plan. <br />The availability of the additional information makes it possible<br />to produce well-tuned plans for corresponding SQL statement without<br />requiring any change to the application code.<br /><br />The scope of a SQL Profile can be controlled by the CATEGORY profile attribute. <br />This attribute determines which user sessions can apply the profile. <br />You can view the CATEGORY attribute for a SQL Profile in CATEGORY column <br />of the DBA_SQL_PROFILES view. By default, all profiles are created in the <br />DEFAULT category. This means that all user sessions where the SQLTUNE_CATEGORY <br />initialization parameter is set to DEFAULT can use the profile.<br /><br />By altering the category of a SQL profile, you can determine which sessions are <br />affected by the creation of a profile. For example, by setting the category <br />of a SQL Profile to DEV, only those users sessions where the SQLTUNE_CATEGORY <br />initialization parameter is set to DEV can use the profile. All other sessions <br />do not have access to the SQL Profile and execution plans for SQL statements <br />are not impacted by the SQL profile. This technique enables you to test <br />a SQL Profile in a restricted environment before making it available to other <br />user sessions.<br /><br />It is important to note that the SQL Profile does not freeze the execution plan<br />of a SQL statement, as done by stored outlines. As tables grow or indexes <br />are created or dropped, the execution plan can change with the same SQL Profile. <br />The information stored in it continues to be relevant even as the data <br />distribution or access path of the corresponding statement change. <br />However, over a long period of time, its content can become outdated and <br />would have to be regenerated. This can be done by running Automatic <br />SQL Tuning again on the same statement to regenerate the SQL Profile.<br /><br />SQL Profiles apply to the following statement types:<br /><br />     SELECT statements <br />     UPDATE statements <br />     INSERT statements (only with a SELECT clause) <br />     DELETE statements <br />     CREATE TABLE statements (only with the AS SELECT clause) <br />     MERGE statements (the update or insert operations)<br /><br />Managing SQL Profiles<br />=====================<br /><br />While SQL Profiles are usually handled by Oracle Enterprise Manager as part <br />of the Automatic SQL Tuning process, SQL Profiles can be managed through the<br />DBMS_SQLTUNE package. To use the SQL Profiles APIs, you need the <br />CREATE ANY SQL_PROFILE, DROP ANY SQL_PROFILE, and ALTER ANY SQL_PROFILE<br />system privileges.<br /><br />Accepting a SQL Profile<br />=======================<br /><br />You can use the DBMS_SQLTUNE.ACCEPT_SQL_PROFILE procedure to accept a <br />SQL Profile recommended by the SQL Tuning Advisor. This creates and stores a<br />SQL Profile in the database. For example:<br /><br />DECLARE<br /> my_sqlprofile_name VARCHAR2(30);<br />BEGIN<br /> my_sqlprofile_name := DBMS_SQLTUNE.ACCEPT_SQL_PROFILE ( <br />    task_name =&gt; 'my_sql_tuning_task',<br />    name      =&gt; 'my_sql_profile');<br />END;<br /><br /><br />Where my_sql_tuning_task is the name of the SQL tuning task.<br />You can view information about a SQL Profile in the DBA_SQL_PROFILES view.<br /><br />Altering a SQL Profile<br />======================<br /><br />You can alter the STATUS, NAME, DESCRIPTION, and CATEGORY attributes of <br />an existing  SQL Profile with the ALTER_SQL_PROFILE procedure. For example:<br /><br />BEGIN<br />  DBMS_SQLTUNE.ALTER_SQL_PROFILE(<br />     name            =&gt; 'my_sql_profile', <br />     attribute_name  =&gt; 'STATUS', <br />     value           =&gt; 'DISABLED');<br />END;<br />/<br /><br /><br />In this example, my_sql_profile is the name of the SQL Profile that you want to alter. <br />The status attribute is changed to disabled which means the SQL Profile is<br />not used during SQL compilation.<br /><br />Dropping a SQL Profile<br />======================<br />You can drop a SQL Profile with the DROP_SQL_PROFILE procedure. For example:<br /><br />BEGIN<br />  DBMS_SQLTUNE.DROP_SQL_PROFILE(name =&gt; 'my_sql_profile');<br />END;<br />/<br /><br /><br />In this example, my_sql_profile is the name of the SQL Profile you want to drop. <br />You can also specify whether to ignore errors raised if the name does not exist.<br />For this example, the default value of FALSE is accepted.<br /><br />Example<br />=======<br /><br />SESSION 1 -- SCOTT<br />=========<br /><br />SQL&gt; create table test (n number );<br /><br />Table created.<br /><br />declare<br />begin<br />for i in 1 .. 10000<br />loop<br />insert into test values(i);<br />commit;<br />end loop;<br />end;<br /><br />PL/SQL procedure successfully completed.<br /><br /><br />create index test_idx on test(n);<br /><br />Index created.<br /><br /><br />analyze table test estimate statistics (OR use dbms_stats)<br /><br />Table analyzed.<br /><br /><br />select /*+ no_index(test test_idx) */ * from test where n=1<br /><br />Execution Plan<br />----------------------------------------------------------<br />   0      SELECT STATEMENT Optimizer=ALL_ROWS (Cost=6 Card=1 Bytes=13)<br />   1    0   TABLE ACCESS (FULL) OF 'TEST' (TABLE) (Cost=6 Card=1 Bytes<br />          =13)<br /><br /><br /><br />SESSION 2  -- SYS<br />=========<br /><br />  1  DECLARE<br />  2   my_task_name VARCHAR2(30);<br />  3   my_sqltext   CLOB;<br />  4  BEGIN<br />  5   my_sqltext := 'select /*+ no_index(test test_idx) */ * from test where n=<br />1';<br />  6   my_task_name := DBMS_SQLTUNE.CREATE_TUNING_TASK(<br />  7           sql_text    =&gt; my_sqltext,<br />  8           user_name   =&gt; 'SCOTT',<br />  9           scope       =&gt; 'COMPREHENSIVE',<br /> 10           time_limit  =&gt; 60,<br /> 11           task_name   =&gt; 'my_sql_tuning_task_2',<br /> 12           description =&gt; 'Task to tune a query on a specified table');<br /> 13* END;<br /> 14  /<br /><br />PL/SQL procedure successfully completed.<br /><br /><br />  1  BEGIN<br />  2    DBMS_SQLTUNE.EXECUTE_TUNING_TASK( task_name =&gt; 'my_sql_tuning_task_2');<br />  3* end;<br />SQL&gt; /<br /><br />PL/SQL procedure successfully completed.<br /><br /><br />  1  SET LONG 1000<br />  2  SET LONGCHUNKSIZE 1000<br />  3  SET LINESIZE 100<br />  4* SELECT DBMS_SQLTUNE.REPORT_TUNING_TASK( 'my_sql_tuning_task_2') from DUAL;<br /><br /><br /><br />DBMS_SQLTUNE.REPORT_TUNING_TASK('MY_SQL_TUNING_TASK_2')<br />--------------------------------------------------------------------------------<br />--------------------<br />GENERAL INFORMATION SECTION<br />-------------------------------------------------------------------------------<br />Tuning Task Name   : my_sql_tuning_task_2<br />Scope              : COMPREHENSIVE<br />Time Limit(seconds): 60<br />Completion Status  : COMPLETED<br />Started at         : 05/04/2004 17:36:05<br />Completed at       : 05/04/2004 17:36:05<br /><br />-------------------------------------------------------------------------------<br />SQL ID  : d4wgpc5g0s0vu<br /><br />DBMS_SQLTUNE.REPORT_TUNING_TASK('MY_SQL_TUNING_TASK_2')<br />--------------------------------------------------------------------------------<br />--------------------<br />SQL Text: select /*+ no_index(test test_idx) */ * from test where n=1<br /><br />-------------------------------------------------------------------------------<br />FINDINGS SECTION (1 finding)<br />-------------------------------------------------------------------------------<br /><br />1- SQL Profile Finding (see explain plans section below)<br />--------------------------------------------------------<br />  A potentially better execution plan was found for this statement.<br /><br />  Recommendation (estimated benefit: 83.84%)<br /><br />DBMS_SQLTUNE.REPORT_TUNING_TASK('MY_SQL_TUNING_TASK_2')<br />--------------------------------------------------------------------------------<br />--------------------<br />  ------------------------------------------<br />    Consider accepting the recommended<br /><br /><br />  1  DECLARE<br />  2   my_sqlprofile_name VARCHAR2(30);<br />  3  BEGIN<br />  4   my_sqlprofile_name := DBMS_SQLTUNE.ACCEPT_SQL_PROFILE (<br />  5      task_name =&gt; 'my_sql_tuning_task_2',<br />  6      name      =&gt; 'my_sql_profile');<br />  7* END;<br />  8  /<br /><br />PL/SQL procedure successfully completed.<br /><br /><br />SQL&gt; select to_char(sql_text) from           dba_sql_profiles;<br /><br />TO_CHAR(SQL_TEXT)<br />------------------------------------------------------------------------<br />select /*+ no_index(test test_idx) */ * from test where n=1<br /><br /><br />SESSION 1 --- SCOTT<br /><br /><br />SQL&gt; select /*+ no_index(test test_idx) */ * from test where n=1;<br /><br />Execution Plan<br />----------------------------------------------------------<br />   0      SELECT STATEMENT Optimizer=ALL_ROWS (Cost=1 Card=1 Bytes=13)<br />   1    0   INDEX (RANGE SCAN) OF 'TEST_IDX' (INDEX) (Cost=1 Card=1 By<br />          tes=13<br /><br /><br />From http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:61313086268493<br /><br /></font></pre>Rasin -- Thanks for the question regarding "SQL Profiles", version 10.2<br /><br />You Asked<br /><br />Tom, <br />can you explain what are SQL Profiles, what are they used for how the CBO uses them and <br />how can we utilize this feature.<br /><br />Thanks.<br />&nbsp;<br />and we said...<br /><br />Ok, this is my conceptual explanation.&nbsp; <br /><br />In the past, the DBA could analyze single 'things'<br /><br />the DBA could analyze A TABLE - finding the number of blocks, rows, things like that.&nbsp; <br />about A TABLE.<br /><br />the DBA could analyze A COLUMN - get histograms, high/low values, number of distinct <br />values, things like that - about A COLUMN<br /><br />the DBA could analyze AN INDEX - get keys/get, leaf blocks, height, clustering factor.<br /><br />the DBA could analyze A SYSTEM - find the single block IO time, the multi-block IO time, <br />cpu speed and so on.<br /><br /><br />But - most of our queries (many of them) involve more than A TABLE, A COLUMN, AN INDEX, <br />and so on... They are complex.<br /><br />For example (blatant theft of example from Jonathan Lewis here - his CBO book is awesome, <br />I remember him first using this example in 2003 at the NoCoug meeting...)<br /><br />o How many of you are Pisces?&nbsp; 1/12th of the room will raise hands.<br /><br />o How many of you are born in December?&nbsp; 1/12 of the room will raise hands.<br /><br /><br />Now, how many of you Pisces were born in December?&nbsp; (silence, none of them are - I know, <br />I am Pisces :)<br /><br />Now, ask the optimizer!<br /><br /><br />ops$tkyte@ORA10GR2&gt; create table t<br />&nbsp; 2&nbsp; as<br />&nbsp; 3&nbsp; select decode( mod(rownum,12), 0, 'Capricorn',<br />&nbsp; 4&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 1, 'Gemini',<br />&nbsp; 5&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2, 'Libra',<br />&nbsp; 6&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 3, 'Aquarius',<br />&nbsp; 7&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 4, 'Cancer',<br />&nbsp; 8&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 5, 'Scorpio',<br />&nbsp; 9&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 6, 'Pisces',<br />&nbsp;10&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 7, 'Ariea',<br />&nbsp;11&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 8, 'Leo',<br />&nbsp;12&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 9, 'Sagittarius',<br />&nbsp;13&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 10, 'Taurus',<br />&nbsp;14&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 11, 'Virgo' ) zodiac,<br />&nbsp;15&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; add_months( to_date( '01-jan-2006' ), mod(rownum,12) ) dob<br />&nbsp;16&nbsp;&nbsp;&nbsp; from all_objects<br />&nbsp;17&nbsp; /<br /><br />Table created.<br /><br />ops$tkyte@ORA10GR2&gt;<br />ops$tkyte@ORA10GR2&gt; exec dbms_stats.gather_table_stats( user, 'T', method_opt=&gt; 'for all <br />columns size 254' );<br /><br />PL/SQL procedure successfully completed.<br /><br />ops$tkyte@ORA10GR2&gt;<br />ops$tkyte@ORA10GR2&gt; set autotrace traceonly explain<br />ops$tkyte@ORA10GR2&gt; select * from t;<br /><br />Execution Plan<br />----------------------------------------------------------<br />Plan hash value: 1601196873<br /><br />--------------------------------------------------------------------------<br />| Id&nbsp; | Operation&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Name | Rows&nbsp; | Bytes | Cost (%CPU)| Time&nbsp;&nbsp;&nbsp;&nbsp; |<br />--------------------------------------------------------------------------<br />|&nbsp;&nbsp; 0 | SELECT STATEMENT&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | 51292 |&nbsp;&nbsp; 751K|&nbsp;&nbsp;&nbsp; 52&nbsp;&nbsp; (6)| 00:00:01 |<br />|&nbsp;&nbsp; 1 |&nbsp; TABLE ACCESS FULL| T&nbsp;&nbsp;&nbsp; | 51292 |&nbsp;&nbsp; 751K|&nbsp;&nbsp;&nbsp; 52&nbsp;&nbsp; (6)| 00:00:01 |<br />--------------------------------------------------------------------------<br /><br />ops$tkyte@ORA10GR2&gt; select * from t where zodiac = 'Pisces';<br /><br />Execution Plan<br />----------------------------------------------------------<br />Plan hash value: 1601196873<br /><br />--------------------------------------------------------------------------<br />| Id&nbsp; | Operation&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Name | Rows&nbsp; | Bytes | Cost (%CPU)| Time&nbsp;&nbsp;&nbsp;&nbsp; |<br />--------------------------------------------------------------------------<br />|&nbsp;&nbsp; 0 | SELECT STATEMENT&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp; 4107 | 61605 |&nbsp;&nbsp;&nbsp; 53&nbsp;&nbsp; (8)| 00:00:01 |<br />|*&nbsp; 1 |&nbsp; TABLE ACCESS FULL| T&nbsp;&nbsp;&nbsp; |&nbsp; 4107 | 61605 |&nbsp;&nbsp;&nbsp; 53&nbsp;&nbsp; (8)| 00:00:01 |<br />--------------------------------------------------------------------------<br /><br />Predicate Information (identified by operation id):<br />---------------------------------------------------<br /><br />&nbsp;&nbsp; 1 - filter("ZODIAC"='Pisces')<br /><br />ops$tkyte@ORA10GR2&gt; select * from t where dob = to_date( '01-dec-2006' );<br /><br />Execution Plan<br />----------------------------------------------------------<br />Plan hash value: 1601196873<br /><br />--------------------------------------------------------------------------<br />| Id&nbsp; | Operation&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Name | Rows&nbsp; | Bytes | Cost (%CPU)| Time&nbsp;&nbsp;&nbsp;&nbsp; |<br />--------------------------------------------------------------------------<br />|&nbsp;&nbsp; 0 | SELECT STATEMENT&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp; 4494 | 67410 |&nbsp;&nbsp;&nbsp; 53&nbsp;&nbsp; (8)| 00:00:01 |<br />|*&nbsp; 1 |&nbsp; TABLE ACCESS FULL| T&nbsp;&nbsp;&nbsp; |&nbsp; 4494 | 67410 |&nbsp;&nbsp;&nbsp; 53&nbsp;&nbsp; (8)| 00:00:01 |<br />--------------------------------------------------------------------------<br /><br />Predicate Information (identified by operation id):<br />---------------------------------------------------<br /><br />&nbsp;&nbsp; 1 - filter("DOB"=TO_DATE('2006-12-01 00:00:00', 'yyyy-mm-dd<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; hh24:mi:ss'))<br /><br />ops$tkyte@ORA10GR2&gt; select * from t where zodiac = 'Pisces' and dob = to_date( <br />'01-dec-2006' );<br /><br />Execution Plan<br />----------------------------------------------------------<br />Plan hash value: 1601196873<br /><br />--------------------------------------------------------------------------<br />| Id&nbsp; | Operation&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Name | Rows&nbsp; | Bytes | Cost (%CPU)| Time&nbsp;&nbsp;&nbsp;&nbsp; |<br />--------------------------------------------------------------------------<br />|&nbsp;&nbsp; 0 | SELECT STATEMENT&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp;&nbsp; 360 |&nbsp; 5400 |&nbsp;&nbsp;&nbsp; 53&nbsp;&nbsp; (8)| 00:00:01 |<br />|*&nbsp; 1 |&nbsp; TABLE ACCESS FULL| T&nbsp;&nbsp;&nbsp; |&nbsp;&nbsp; 360 |&nbsp; 5400 |&nbsp;&nbsp;&nbsp; 53&nbsp;&nbsp; (8)| 00:00:01 |<br />--------------------------------------------------------------------------<br /><br />Predicate Information (identified by operation id):<br />---------------------------------------------------<br /><br />&nbsp;&nbsp; 1 - filter("ZODIAC"='Pisces' AND "DOB"=TO_DATE('2006-12-01<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 00:00:00', 'yyyy-mm-dd hh24:mi:ss'))<br /><br /><br />We can sort of see this with dynamic sampling - which is *similar* to a sql profile, <br />but not stored like a profile would be:<br /><br /><br />ops$tkyte@ORA10GR2&gt; select /*+ dynamic_sampling( t 4 ) */ * from t where zodiac = <br />'Pisces' and dob = to_date( '01-dec-2006' );<br /><br />Execution Plan<br />----------------------------------------------------------<br />Plan hash value: 1601196873<br /><br />--------------------------------------------------------------------------<br />| Id&nbsp; | Operation&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Name | Rows&nbsp; | Bytes | Cost (%CPU)| Time&nbsp;&nbsp;&nbsp;&nbsp; |<br />--------------------------------------------------------------------------<br />|&nbsp;&nbsp; 0 | SELECT STATEMENT&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp; 1 |&nbsp;&nbsp;&nbsp; 15 |&nbsp;&nbsp;&nbsp; 53&nbsp;&nbsp; (8)| 00:00:01 |<br />|*&nbsp; 1 |&nbsp; TABLE ACCESS FULL| T&nbsp;&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp; 1 |&nbsp;&nbsp;&nbsp; 15 |&nbsp;&nbsp;&nbsp; 53&nbsp;&nbsp; (8)| 00:00:01 |<br />--------------------------------------------------------------------------<br /><br />Predicate Information (identified by operation id):<br />---------------------------------------------------<br /><br />&nbsp;&nbsp; 1 - filter("ZODIAC"='Pisces' AND "DOB"=TO_DATE('2006-12-01<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 00:00:00', 'yyyy-mm-dd hh24:mi:ss'))<br /><br />Note<br />-----<br />&nbsp;&nbsp; - dynamic sampling used for this statement<br /><br />ops$tkyte@ORA10GR2&gt; set autotrace off<br /><br />the optimizer ran this query for us to parse:<br /><br />SELECT /* OPT_DYN_SAMP */ /*+ ALL_ROWS opt_param('parallel_execution_enabled',<br />&nbsp;&nbsp; 'false') NO_PARALLEL(SAMPLESUB) NO_PARALLEL_INDEX(SAMPLESUB) NO_SQL_TUNE<br />&nbsp; */ NVL(SUM(C1),:"SYS_B_0"), NVL(SUM(C2),:"SYS_B_1")<br />FROM<br />&nbsp;(SELECT /*+ NO_PARALLEL("T") FULL("T") NO_PARALLEL_INDEX("T") */ :"SYS_B_2"<br />&nbsp; AS C1, :"SYS_B_3" AS C2&nbsp; FROM "T" "T" WHERE "T"."ZODIAC"=:"SYS_B_4" AND<br />&nbsp; "T"."DOB"=TO_DATE(:"SYS_B_5", :"SYS_B_6")) SAMPLESUB<br /><br /><br />and used the results of that as the estimated cardinality.&nbsp; SQL profiles would do the <br />same - but would look at the entire query - cross table, column, whatever and do partial <br />executes on it (try out the data in your database) and remember that in the dictionary as <br />extended statistics.<br /><br />It can use that next time to parse and optimize the query.<br /><br />It'll remember other things too - like "this query is used to retrieve just the first <br />rows, we should not optimize for all rows, but first rows - let us remember that in the <br />future..."<br /><br />So, a SQL profile is sort of like gathering statistics on A QUERY - which involves many <br />tables, columns and the like....<br /><br />In fact - it is just like gathering statistics for a query, it stores additional <br />information in the dictionary which the optimizer uses at optimization time to determine <br />the correct plan.&nbsp; The SQL Profile is not "locking a plan in place", but rather giving <br />the optimizer yet more bits of information it can use to get the right plan.<br /><br />SQL PROFILES&nbsp;&nbsp; <br />Reviewer: Mark <br /><br />Tom,<br /><br />Do SQL Profiles get stale?&nbsp; If so, is there some way to refresh stale profiles like we do for <br />stats?<br /><br />Thanks for your time..<br /><br />Followup&nbsp;&nbsp; April 2, 2008 - 1pm US/Eastern:<br />you re-profile the sql statement.<br /><br />Yes, they can get "stale" - basically, sql profiles are better estimated cardinality values - better in that they are based on sampling your where clause - not based on basic 'statistical projection'.<br /><br />and if the underlying data changes - well, then they (the better card=values) would become wrong.<br /><br />Eg: if someone changes the zodiac lookup table so that pisces are born in december, the sample we ran that says "zero are" would be wrong<br /><br />sql profile vs Sql plan management of 11g&nbsp; <br />Reviewer: Aman Sharma from India<br /><br />Hi&nbsp; sir,<br />Its an excellent explanation.Can you please explain the difference in the sql profiles and sql plan <br />management /sql baselines of 11g ?<br />regards<br />Aman....<br /><br />Followup&nbsp;&nbsp; April 3, 2008 - 8pm US/Eastern:<br />the sql baselines is more akin to storing query plans and ensuring those plans are used. they are the baseline plans..<br /><br />sql profiles are what they are - cardinality information, subject to influencing a plan, but not dictating it.<br /><br /><br /><i>From http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:729346500346644123</i><br /><br />Joe -- Thanks for the question regarding "10g SQL Profiles", version 10.2<br /><br />You Asked<br />Can you explain how SQL profiles work when it comes to recommendations from the SQL Tuning Advisor in 10g?<br /><br />Thanks in advance.<br /><br />and we said...<br /><br />simply put:<br /><br />sql profiles work by taking the query itself and doing partial executions of various predicates - and remembering the ACTUAL card= values (cardinality values) and hinting the query so that it *KNOWS* "this step will return about 5 records, not the 50,000 you guessed at, but only 5"<br /><br />and the next time the query is hard parsed, we use those card= values to come up with the best plan.<br /><br />the key is to get the CORRECT card=value numbers, when we get the right number - you get the right plan. When we get the wrong number - that is when you see suboptimal plans.<br /><br />So, sql profiles simply take the query - execute bits of it, figure out how many rows are actually returned (or look at the execution HISTORY to see how many rows are actually flowing from the row sources as well) and STORE that information as extended statistics - and use that information the next time the query is hard parsed<br /><br />Profiles<br />Reviewer: Dana from Phoenix, AZ USA<br /><br />Are SQL Profiles an extension of sql outlines? <br />Many of the features sound similar or same.<br /><br />Followup&nbsp;&nbsp; March 26, 2008 - 8am US/Eastern:<br /><br />similar, but not the same.<br /><br />stored outlines are a set of hints that say "use this index, do this table first, do that next, use this access path, perform this filter then that filter"....<br /><br />sql profiles are more like extended statistics - they are the result of "analyzing a query", the information provided to the optimizer is not HOW to perform the query - but rather better information about how many rows will flow out of a step in the plan, how selective something is.<br /><br />say you have a query, you generate a stored outline for it. You now add an index to the underlying table. This index would be GREAT for the query. A stored outline won't use it, the stored outline says "use this index - query that table - then do this". Since the GREAT index did not exist when the outline was generated - it won't be used.<br /><br />say you have a query, you generate a profile for it. You now add an index to the underlying table. This index would be GREAT for the query. A profile can use it - since the profile is just more information for the CBO - better cardinality estimates.<br /><br /><br /><span class="mt-enclosure mt-enclosure-file" style="display: inline;"><a href="http://www.heysky.net/digest/uploads/2008/SQLProfiles_20060622.pdf">SQLProfiles_20060622.pdf</a></span><br /> <pre><font face="courier"><br /></font></pre><div><br /></div>]]>
    </content>
</entry>

<entry>
    <title>Hashing in Oracle</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2008/07/hashing-in-oracle.html" />
    <id>tag:www.heysky.net,2008:/digest//1.328</id>

    <published>2008-07-29T23:26:28Z</published>
    <updated>2008-07-29T23:30:43Z</updated>

    <summary><![CDATA[From http://www.dbasupport.com/oracle/ora10g/hash.shtml &nbsp; Hashing in Oracle Steve Callan, stevencallan@hotmail.com The internal workings of the Oracle RDBMS are a marvel to behold. Think about all of the things you do know with respect to what it takes to issue a select...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="10g" label="10g" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="hash" label="hash" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="_bloom_filter_enabled" label="_BLOOM_FILTER_ENABLED" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<p><em>From </em><a href="http://www.dbasupport.com/oracle/ora10g/hash.shtml"><em>http://www.dbasupport.com/oracle/ora10g/hash.shtml</em></a></p>
<p>&nbsp;</p>
<p>Hashing in Oracle <br />Steve Callan, <a href="mailto:stevencallan@hotmail.com">stevencallan@hotmail.com</a> </p>
<p>The internal workings of the Oracle RDBMS are a marvel to behold. Think about all of the things you do know with respect to what it takes to issue a select statement, perform an update, or create a table. Latches, locks, serialization, caching, pinning, flushing, checkpointing, sorting, space management, undo, redo, and the list goes on and on. Aside from visible functions, there are a slew of transparent operations. Many of these transparent operations, as the adjective implies, not only work behind the scenes, but also stay there. There are also operations whose work is largely hidden, but whose results are exposed to us. One such operation found in several key areas of how Oracle works is hashing.</p>]]>
        <![CDATA[<p>What is Hashing?<br />Hash isn't a formal term, but more of a description for what takes place: chop and mix. A hash function returns a value for an input, and the output is generally shorter or more compact than the input. For a relatively simple hash function, there is no guarantee that inputs map one to one for outputs, that is, two different inputs can have the same hashed output value. Add more sophistication to the hash function, or add yet another hashing, and the probability of two distinct inputs having the same hashed output can be greatly decreased.</p>
<p>Before getting more into where hashing takes place in Oracle, let's look at some examples of how hashing is used. A good general overview of hashing and various types of hashing can be found at a Mathematica site. The table of names takes the sum of the ASCII values of each letter, sums them, and then lists the mod 13 remainder. The table is reproduced below with an additional column to help illustrate what is taking place. I also provided some code to help reproduce the results.</p>
<p>create table hash_example<br />(lastname varchar2(12),<br />&nbsp; ascii_sum number,<br />&nbsp; hashed_value number);<br />insert into hash_example (lastname) values ('Brecker');<br />insert into hash_example (lastname) values ('Corea');<br />insert into hash_example (lastname) values ('Davis');<br />insert into hash_example (lastname) values ('Hancock');<br />insert into hash_example (lastname) values ('Harris');<br />insert into hash_example (lastname) values ('Marsalis');<br />insert into hash_example (lastname) values ('Parker');<br />commit;</p>
<p>declare<br />&nbsp; cursor c is<br />&nbsp; select lower(lastname) lastname <br />&nbsp; from hash_example <br />&nbsp; for update;<br />&nbsp; l_name hash_example.lastname%type;<br />&nbsp; l_sum hash_example.ascii_sum%type := 0;<br />&nbsp; l_tmp number := 0;<br />begin<br />&nbsp; for r in c loop<br />&nbsp;&nbsp;&nbsp; for i in 1..length(r.lastname) loop<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; l_tmp := ascii(substr(r.lastname,i,1));<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; l_sum := l_sum + l_tmp;<br />&nbsp;&nbsp;&nbsp; end loop;<br />&nbsp;&nbsp;&nbsp; update hash_example<br />&nbsp;&nbsp;&nbsp; set ascii_sum = l_sum,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; hashed_value = mod(l_sum,13)<br />&nbsp;&nbsp;&nbsp; where current of c;<br />&nbsp;&nbsp;&nbsp; l_tmp := 0;<br />&nbsp;&nbsp;&nbsp; l_sum := 0;<br />&nbsp; end loop;<br />end;<br />/</p>
<p>PL/SQL procedure successfully completed.</p>
<p>SQL&gt; select * from hash_example;</p>
<p>LASTNAME&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ASCII_SUM HASHED_VALUE<br />------------ ---------- ------------<br />Brecker&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 734&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 6<br />Corea&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 522&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2<br />Davis&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 535&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2<br />Hancock&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 727&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 12<br />Harris&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 649&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 12<br />Marsalis&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 860&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2<br />Parker&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 645&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 8</p>
<p><br />Overall, this was a pretty simple example. Given that you can pass in a value and get an output based on the hashing algorithm, and that the output is like a fingerprint of the original data, how do you think this can applied to a real table? Suppose you have a table that contains employee identification numbers along with salaries. Aside from using an already built in hashing function (e.g., SHA-1), you could devise a function to hash the combined employee ID and salary values. This hashed value could be stored elsewhere, and then auditing of the table would compare the current values and the stored values. Any (unknown) change in the fingerprint would be cause for concern. This is just one safeguard, and no doubt, you'd want to have some auditing (before the fact, not after!) on a sensitive table like this.</p>
<p>Hashing in a Database<br />So far, we've seen two uses of hashing that can be applied to a database. In the first example, a hashed value of some key attribute can be used for indexing (the hashed value points back to several values), and in the second example, hashing can be used as a comparison tool. These two concepts lend themselves to extensive use within Oracle.</p>
<p>How does Oracle know if a SQL statement is new or already parsed? A parsed statement has a hash value that is by and large unique enough (collisions, or same output for different inputs can happen, but are rare). Shown below is an extract from a trace file, and the lines show each statement's identifying information.</p>
<p>1 PARSING IN CURSOR #1 len=46 dep=0 uid=5 hv=810835083 ad='1d9cd494'</p>
<p>&nbsp; select ename from scott.emp where empno = 7369<br />&nbsp;<br />2 PARSING IN CURSOR #2 len=46 dep=0 uid=5 hv=1290101743 ad='1d9cca00'</p>
<p>&nbsp; select ename from scott.emp where empno = 7499<br />&nbsp;<br />3 PARSING IN CURSOR #1 len=46 dep=0 uid=5 hv=1589217292 ad='1d9cc7c4'</p>
<p>&nbsp; SELECT ENAME FROM SCOTT.EMP WHERE 7499 = EMPNO<br />&nbsp;<br />4 PARSING IN CURSOR #2 len=46 dep=0 uid=5 hv=810835083 ad='1d9cd494'</p>
<p>&nbsp; select ename from scott.emp where empno = 7369<br />&nbsp;<br />Statements 1, 2 and 3 are different, so each has its own hashed value (the hv value). Statements 1 and 4 are the same, and note both have the same hv value. One of the more desirable characteristics of a hashing function is that it should be quite fast and inexpensive to perform. If your statement has already been parsed (has a hash ID value), then a comparison is all that is needed. As pointed out in numerous other sources, hard parsing is undesirable. Re-use of statements can be accomplished two ways. One is via the use of bind variables, and the other is to embed commonly used statements in functions or procedures.</p>
<p>Where else is hashing used? Hash partitioning is useful for data that doesn't cleanly fall into categories such as range or list. Composite partitioning such as range-hash can be used to further categorized and distribute data. In these examples, the indexing feature or benefit is being used. Since this is such a highly performant arrangement of data, the use of hash clusters would be a natural extension. "Overview of Hash Clusters" in the Concepts guide provides a good description of how useful clusters can be. Clustered data is easier to find, and for sorted data, the benefits are even better. </p>
<p>Maybe not as obvious for usage as in the past, given how much better the cost based optimizer is, but hash joins are a frequently used means of accessing data. Incorporating a hint in a statement can result in seeing the hashing step in an execution plan. Without looking at execution plans, and by letting the optimizer do its thing, Oracle isn't going to "tell" you that a hash join was used. </p>
<p>Hidden Hashing<br />Now it's time for a behind the scene use of hashing. In fact, this particular use of hashing is so under the radar that you would probably never even know it existed in Oracle unless you encountered one of several bugs. From note 4960265.9 we have, "In some cases when using a join filter in a RAC configuration (parallel hash-join) wrong results can be produced." The stated fix for this is to set the undocumented parameter _BLOOM_FILTER_ENABLED to false. What is a Bloom filter?</p>
<p>There are lots of hashing techniques, and "General Purpose Hash Function Algorithms," by Arash Partow, gives a decent summary without delving too deep into some esoteric computer science. The definition of a Bloom filter given in the paper states the following:</p>
<p>A Bloom filter allows for the state of existence of a very large set of possible type values to be repsented with a much smaller piece of memory. This is achieved through the use of multiple distinct hash functions and also by allowing the result of a query for the existence of a particular type to have a certain amount of error. This error can be controlled by varying the size of the table used for the Bloom filter and also by varying the number of hash functions.</p>
<p>So now, we know another technique Oracle uses to store data. In a sense, the data can be "over stored," that is, we want to make really, really sure it exists in one place or another. We may be wrong about the place (and then go find an accurate location), but the main point is that it exists. With this type of hashing, it will be difficult to say we don't have it anywhere, when in fact we do.</p>
<p>In Closing<br />Hashing is but one of many cleverly implemented functions embedded in Oracle. What would be interesting is being able to document all of the hash function implementation used in Oracle. For example, how does Oracle come up with 810835083 from "select ename from scott.emp where empno = 7369?" And why do hashed partitions work better (better = data spread more evenly) when the number of buckets is a power of two?</p>]]>
    </content>
</entry>

<entry>
    <title>Oracle 数据库 10g 版本 1 中的 PL/SQL 纯编译 (NCOMP)</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2008/07/oracle-10g-plsql-ncomp.html" />
    <id>tag:www.heysky.net,2008:/digest//1.327</id>

    <published>2008-07-29T20:01:09Z</published>
    <updated>2008-07-29T20:07:20Z</updated>

    <summary><![CDATA[From http://www.oracle.com/technology/global/cn/tech/pl_sql/htdocs/ncomp_faq.html &nbsp; Oracle 数据库 10g 版本 1 中的 PL/SQL 纯编译 (NCOMP) 2004 年 9 月 4 日更新&nbsp; --------------------------------------------------------------------------------什么是纯编译？如何实现 PL/SQL 纯编译？Oracle 数据库 10g 有什么新特性？什么对象可以进行 PL/SQL 纯编译？共享库 (DLL) 的命名惯例是什么？共享的动态链接库是否可以移植？在部署端是否需要 C 编译环境？哪些 Oracle 参数与纯编译相关？plsql_native_library_dir 参数plsql_native_library_subdir_count 参数plsql_code_type 参数$ORACLE_HOME/plsql/spnc_commands 文件的格式纯编译生成的共享库存储在哪个字典表中？当删除一个"纯编译"单元时，文件系统上的共享库将发生什么？如何更改 plsql_native_library_dir？是否还有其他场合需要手动删除共享库？如果误删除了一个共享库该怎么办？甲骨文公司是否建议混合使用纯编译单元和解释单元？在操作系统升级时，是否需要重新生成纯编译的共享库？在应用程序部署期间是否能够使用纯编译模式来节省时间（通过提供预先生成的 NCOMP 共享库）？纯编译测试：简单测试将数据库中的所有 PL/SQL...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="10g" label="10g" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="ncomp" label="NCOMP" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="plsql" label="pl/sql" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<p><em>From </em><a href="http://www.oracle.com/technology/global/cn/tech/pl_sql/htdocs/ncomp_faq.html"><em>http://www.oracle.com/technology/global/cn/tech/pl_sql/htdocs/ncomp_faq.html</em></a></p>
<p>&nbsp;</p>
<p>Oracle 数据库 10g 版本 1 中的 PL/SQL 纯编译 (NCOMP)</p>
<p>2004 年 9 月 4 日更新&nbsp; </p>
<p>--------------------------------------------------------------------------------<br /><br />什么是纯编译？<br />如何实现 PL/SQL 纯编译？<br />Oracle 数据库 10g 有什么新特性？<br />什么对象可以进行 PL/SQL 纯编译？<br />共享库 (DLL) 的命名惯例是什么？<br />共享的动态链接库是否可以移植？<br />在部署端是否需要 C 编译环境？<br />哪些 Oracle 参数与纯编译相关？<br />plsql_native_library_dir 参数<br />plsql_native_library_subdir_count 参数<br />plsql_code_type 参数<br />$ORACLE_HOME/plsql/spnc_commands 文件的格式<br />纯编译生成的共享库存储在哪个字典表中？<br />当删除一个"纯编译"单元时，文件系统上的共享库将发生什么？<br />如何更改 plsql_native_library_dir？<br />是否还有其他场合需要手动删除共享库？<br />如果误删除了一个共享库该怎么办？<br />甲骨文公司是否建议混合使用纯编译单元和解释单元？<br />在操作系统升级时，是否需要重新生成纯编译的共享库？<br />在应用程序部署期间是否能够使用纯编译模式来节省时间（通过提供预先生成的 NCOMP 共享库）？<br />纯编译测试：简单测试<br />将数据库中的所有 PL/SQL 单元进行纯编译<br /></p>]]>
        <![CDATA[什么是纯编译？ 
<p>您可以通过将 PL/SQL 模块（程序包、触发器、过程、函数和类型）编译成驻留在共享库中的纯代码来加速它们的运行。过程被转换成 C 代码，然后用一个 C 编译器进行编译，并与 Oracle 进程动态链接。 </p>
<p>您可以将该技术用于随付的 Oracle 程序包以及您自己编写的过程。用这种方式编译的过程可以用于所有服务器环境，如共享服务器配置（以前称为多线程服务器）和 Oracle 真正应用集群。 </p>
<p>使用了大量有代表性测试程序的性能实验（发布在 OTN 上）表明，在 Oracle 数据库 10g 中，纯 PL/SQL 程序的应用程序在纯编译时的速度与解释编译时的速度相比（其他保持不变），预计可以获得大约 1.05 到 2.4 倍的性能提高。提高的程度取决于程序的种类。 </p>
<p>注意：许多 Oracle 提供的程序包（如 UTL_FILE、UTL_RAW、DBMS_LOB）已经用 C 实施，而仅使用 PL/SQL 来提供 API。这些程序包不大可能从纯编译中获得显著的性能提高。同样，仅调用 SQL 语句的 PL/SQL 程序单元也可能几乎得不到加速。不过，纯编译的 PL/SQL 往往至少和相应的解释代码一样快。编译的代码将与解释的代码执行相同的库调用，因此它们的行为是完全相同的。 </p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>如何实现 PL/SQL 纯编译？ </p>
<p>如果未使用纯编译，则将每个 PL/SQL 程序单元编译成一种中间形式的机器可读码 (MCode)。MCode 存储在数据库字典中，并在运行时进行解释。 </p>
<p>使用 PL/SQL 纯编译，将 PL/SQL 程序编译成无需运行时解释的纯机器码，从而加快运行速度。</p>
<p>PL/SQL 使用命令文件 $ORACLE_HOME/plsql/spnc_commands 和支持的操作系统 C 编译器和链接器，将生成的 C 代码编译并链接到共享库中。共享库存储在数据字典中，这样便可将它们自动备份并防止它们被删除。这些共享库文件被复制到文件系统中，并在调用 PL/SQL 子程序时被加载和运行。如果在关闭数据库时从文件系统中删除了这些文件，或者如果您更改了这些库所在的目录，则自动重新提取这些文件。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>Oracle 数据库 10g 有什么新特性？ </p>
<p>这个特性现在需要更少的设置和维护。</p>
<p>不需要用相同的代码类型设置来编译程序包主体及其规范。例如，可以对程序包主体进行纯编译，而对程序包规范进行解释编译。 <br />经过纯编译的子程序存储在数据库中，并在需要的时候自动提取相应的共享库。对于备份共享库、清理原有共享库等事项，您无需操心。 <br />而且简化了纯编译的初始化参数和命令的设置。唯一需要的参数是 plsql_native_library_dir。不再使用与编译器、链接器和 make 实用程序相关的参数。$ORACLE_HOME/plsql/spnc_commands 命令文件用于进行纯编译。它包含了用于编译和链接的命令和选项，从而不再依赖于 make 实用程序。不再需要或支持 plsql_native_make_utility 和 plsql_native_make_file_name 参数，但仍须像在 9.0.1 版和 9.2.0 版中一样指定 plsql_native_library_dir。这将指定用于生成共享库（在共享库被复制到数据库中之前）的目录的完整路径。 <br />纯编译期间出现的所有错误都存储在 USER_ERRORS 字典视图中，可通过 SQL*Plus 命令 SHOW ERRORS 来查询。 <br />开启和关闭纯编译是由一个单独的参数 plsql_code_type 来控制的，而不是 plsql_compiler_flags 参数的几个选项之一，现在不建议使用后者。 <br />RAC 支持：现在在没有集群（共享）文件系统的 RAC 环境中也支持 PL/SQL 纯编译。 <br />共享库清理：当删除（或在解释模式下重新编译）纯编译的 PL/SQL 模块时，现在将删除（在 plsql_native_library_dir 指定的位置下的）共享库的文件系统副本。在 RAC 配置中，将从所有实例中删除共享库。 </p>
<p><br />--------------------------------------------------------------------------------</p>
<p>什么对象可以进行 PL/SQL 纯编译？ </p>
<p>任何存储的 PL/SQL 模块都可以进行纯编译。匿名的 PL/SQL 程序块不能进行纯编译。</p>
<p>注意：Oracle 支持以下类型的存储 PL/SQL 模块：</p>
<p>FUNCTION<br />PACKAGE<br />PACKAGE BODY<br />PROCEDURE<br />TRIGGER<br />TYPE<br />TYPE BODY</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>共享库 (DLL) 的命名惯例是什么？ </p>
<p>纯编译为每个单元创建一个共享库。例如，将为程序包规范和程序包主体分别创建一个共享库。以下是生成的一些名称：</p>
<p>PKG__SCOTT__S__54682.so<br />PKG__SCOTT__B__54683.so</p>
<p>生成的名称一般包含单元名称、模式名称、对象类型和对象编号。不过，这是一个可能会变更的内部惯例，用户不应依赖这种文件名格式规范。</p>
<p>文件名的扩展名在不同平台上可能不同。例如，在 Solaris 上共享库的后缀为 .so，而在 HP-UX 上共享库的后缀为 .sl。</p>
<p>返回页首 <br />共享的动态可链接库是否可以移植？ </p>
<p>不，绝对不行！共享库包含特定于平台的目标代码。 </p>
<p>注意：在解释方式下创建的 MCode 也是特定于平台的。 </p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>在部署端是否需要 C 编译环境？ </p>
<p>是的。没有商量的余地。PL/SQL 单元可能需要在部署端进行编译，PL/SQL 纯编译依靠一个 C 编译器来生成目标（机器）代码。</p>
<p>例如，各种操作（如向表中增加一列）可能导致与该表相关的 PL/SQL 单元的自动失效。对这种单元的后续访问将触发重新编译。在这种情况下，在纯编译模式下再次重新编译该单元需要 C 编译环境。</p>
<p>另一种情况是需要在部署数据库上应用补丁。可能需要在部署环境中重新加载和编译个别程序包。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>哪些 Oracle 参数与纯编译相关？ </p>
<p>plsql_native_library_dir <br />plsql_native_library_subdir_count<br />plsql_code_type <br />返回页首 <br />plsql_native_library_dir 参数 </p>
<p>这个参数指定保存共享库 (DLL) 的 OS 副本的目录位置。</p>
<p>当对一个模块进行纯编译时，将在这个位置创建共享库，然后将其复制到数据库字典表 (ncomp_dll$) 中。虽然共享库的主副本驻留在数据库中，但还将共享对象在文件系统中进行了物化，以便能够动态地将它们加载到 Oracle 的地址空间中。</p>
<p>注释 1：用户 (DBA) 决不能在系统启动并运行时从 plsql_native_library_dir 中手动删除共享库，因为这些 DLL 可能被映射到了 Oracle 进程上。只有在系统关闭的时候才能安全地删除共享库的 OS 副本。</p>
<p>注释 2：在 RAC 配置中，必须在每个实例中设置这个参数。不要求各实例拥有共享文件系统。在每个实例上，必须将 plsql_native_library_dir 设置为指向一个实例本地目录。或者，如果 RAC 配置支持共享（集群）文件系统，您可以将（共享文件系统上的）一个公共的目录用于所有实例。</p>
<p>注释 3：您必须创建这个目录。Oracle 不会自动为您创建这个目录。</p>
<p>注释 4：甲骨文公司在单实例或 RAC 配置中都不为 plsql_native_library_dir 提供 NFS 挂载目录支持。这是因为 NFS 在写或删除文件时会导致一些不可预测的时序问题。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>plsql_native_library_subdir_count 参数 </p>
<p>一些文件系统可能无法在单个目录中处理大量的文件；您可能需要在 plsql_native_library_dir 指定的目录下创建子目录来存储纯编译生成的共享库。</p>
<p>如果您使用的是生产品质的文件系统（例如 Veritas），那么您可能无需创建子目录。然而，如果您使用的是 vanilla 文件系统，那么它可能无法在单个目录中轻松地处理大量的文件。对于拥有大约 70,000 个 PL/SQL 对象的 Oracle 应用程序，在使用 vanilla 文件系统时，我们使用了大约 500 个子目录。</p>
<p>这个参数的默认值是 0。为了指示 Oracle 将共享库分配到不同的子目录中，而不是将所有共享库存储在 plsql_native_library_dir 指定的单个目录中，请将 plsql_native_library_subdir_count 参数设为您要创建的子目录数。</p>
<p>例如，要使用 500 个子目录，则将以下行添加到您的初始化参数文件中：</p>
<p>plsql_native_library_subdir_count=500</p>
<p>然后您必须创建 500 个子目录（在 plsql_native_library_dir 参数指定的目录下），目录名称即为 d0、d1、d2、..、d498、d499。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>plsql_code_type 参数 </p>
<p>plsql_code_type 参数决定对 PL/SQL 代码是进行纯编译还是解释。默认设置是 INTERPRETED。要启用 PL/SQL 纯编译，请将 plsql_code_type 的值设为 NATIVE。如果您想以 NATIVE 方式编译整个数据库，那么甲骨文公司建议您在系统级或在初始化参数文件中设置 plsql_code_type。 </p>
<p>使用以下语法设置该参数：</p>
<p>对于纯编译模式： <br />alter session set plsql_code_type='NATIVE'<br />或者， <br />alter system set plsql_code_type='NATIVE'<br />对于解释模式： <br />alter session set plsql_code_type='INTERPRETED'<br />或者， <br />alter system set plsql_code_type='INTERPRETED'</p>
<p><br />--------------------------------------------------------------------------------</p>
<p>spnc_commands 文件的格式 </p>
<p>$ORACLE_HOME/plsql 目录中的 spnc_commands 文件包含了编译和链接各个程序的命令模板。一些特殊的名称（如 %(src)）被预先定义，并用相应的文件名进行了替换。变量 $(ORACLE_HOME) 也自动被 Oracle 主目录的位置替换。您可以包含命令行（以 # 字符开始）。该文件包含解释所有特殊符号的注释。 </p>
<p>spnc_commands 文件根据特定的操作系统为 C 编译器包含了一个预先定义的路径。（每种操作系统支持一种特定的编译器。）在大多数情况下，您不需要更改这个路径，但如果系统管理员将编译器安装在了另一个位置，您可能就需要更改它了。 </p>
<p>这种方法意味着（与 9.0.1 版和 9.2.0 版不同）这里与 make 实用程序不存在依赖关系。 </p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>纯编译生成的共享库存储在哪个字典表中？ </p>
<p>纯编译生成的共享库被作为 BLOB 存储在数据库中的 ncomp_dll$ 字典表中。</p>
<p>SQL&gt; connect / as sysdba;<br />Connected.<br />SQL&gt; describe ncomp_dll$;<br />Name&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Null?Type<br />&nbsp;------------&nbsp;&nbsp; --------------&nbsp;&nbsp;&nbsp; -------- <br />OBJ#&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; NOT NULL&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; NUMBER<br />VERSION&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; NUMBER<br />DLL&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BLOB<br />DLLNAME&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; RAW(1024)</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>当删除一个"纯编译"单元时，文件系统上的共享库将发生什么？ </p>
<p>直到 9.2.0，未发生任何事情。不会对共享库进行垃圾收集。</p>
<p>在 10.1.0 版中，当删除或在解释模式下重新编译一个纯编译的单元时，将从 ncomp_dll$ 字典表以及从 plsql_native_library_dir 参数指定的文件系统位置中删除该共享库。在 RAC 配置的情况下，将从每个实例的 plsql_native_library_dir 位置中删除该共享库。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>如何更改 plsql_native_library_dir？ </p>
<p>如果您需要更改该参数的值，建议采取以下步骤：</p>
<p>关闭数据库实例 <br />将初始化参数文件中的 plsql_native_library_dir 设置更改为指向新的位置。 <br />重新启动数据库实例。Oracle 将根据需要自动将共享库提取到这个新的位置中。 <br />注释 1：虽然可以通过 alter system..命令来更改这个参数，但 Oracle 不建议这么做。</p>
<p>注释 2：一旦执行了上述步骤，就可以安全地删除与 plsql_native_library_dir 先前的设置对应的原有目录了。Oracle 不会 自动从原有位置删除共享库。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>是否还有其他场合需要手动删除共享库？ </p>
<p>没有。 </p>
<p>唯一的例外是当您想修改 plsql_native_library_dir 的设置的时候。请按照先前所述步骤更改 plsql_native_library_dir。然后就可以从原有位置删除共享库了。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>如果误删除了一个共享库该怎么办？ </p>
<p>这可能导致非预期的内部错误和问题。建议的补救办法是关闭然后重新启动实例。Oracle 将根据需要自动从 ncomp_dll$ 字典表中提取共享库。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>甲骨文公司是否建议混合使用纯编译单元和解释单元？ </p>
<p>虽然支持混合使用，并且决不会导致错误的行为，但当纯编译单元调用解释单元时，需要付出一定代价。如果纯编译单元频繁调用解释单元，那么您可能牺牲一些潜在的性能改善。</p>
<p>如果将所有模块纯编译成共享库的时间是个问题，那么一种选择是考虑将程序包和类型规范在解释模式下进行编译，而将所有其他类型的 PL/SQL 单元（程序包主体、类型主体、过程、函数和触发器）在纯编译模式下进行编译。因为规范一般没有太多可执行代码，因此就运行时性能而言您不会有太大损失。 </p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>在操作系统升级时，是否需要重新生成纯编译的共享库？ </p>
<p>假设您已经确定甲骨文支持这种类型的 OS 升级，而无需重新生成普通的 Oracle 可执行文件，那么 PL/SQL 纯编译产生的共享库也将可用，而无需重新生成。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>在应用程序部署期间是否能够使用纯编译模式来节省时间（通过提供预先生成的 NCOMP 共享库）？ </p>
<p>不能！即使共享库是在与最终部署环境相同的平台上生成的，您也无法这么做。您也无法在解释模式下利用 MCode 这么做。</p>
<p>其原因与编译模式无关。基于 PL/SQL 的应用程序在数据库中的安装需要在数据库中加载和编译 PL/SQL 模块，以便可以正确解析所有的外部引用。</p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>纯编译测试：简单测试 </p>
<p>创建一个目录，用于存储纯编译生成的共享库，并在初始化参数文件中将 plsql_native_library_dir 参数设置为指向该目录路径。例如，您需要在初始化参数文件中添加如下内容： <br />plsql_native_library_dir=/home/kmuthukk/oracle10g/dbs/ncomp_libraries</p>
<p><br />还可以在初始化参数文件中设置 plsql_native_library_subdir_count 并创建子目录。 <br />确保 spnc_commands 文件中使用的 C 编译器 -- 以及链接器（如果适用） -- 的 OS 路径是正确的。 <br />系统参数完整性检查： 必须指定 plsql_native_library_dir。plsql_native_library_subdir_count 是可选的，可以保留为 0（如果您不打算使用基于子目录的模式）。最好在初始化参数文件中指定这些参数。 <br />SQL&gt; show parameters plsql_native<br />NAME&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; TYPE&nbsp; VALUE<br />------------------------------------ ----------- ------------------------------<br />plsql_native_library_dir&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; string&nbsp; /home/kmuthukk/oracle10g/dbs/ncomp_libraries<br />plsql_native_library_subdir_count&nbsp;&nbsp;&nbsp; integer&nbsp; 0</p>
<p>对 PL/SQL 模块进行纯编译</p>
<p>要在纯编译模式下加载和编译新的模块，必须将 plsql_code_type 参数设为 NATIVE。 <br />例如，尝试在 SQL*Plus 中执行以下操作： </p>
<p>connect scott/tiger<br />alter session set plsql_code_type='NATIVE';</p>
<p>create or replace procedure my_test is<br />begin<br />dbms_output.put_line('hello world');<br />end;<br />/<br />show errors;</p>
<p>set serveroutput on;<br />execute my_test;</p>
<p>验证步骤： </p>
<p>看一下 plsql_native_library_dir 指定的位置。应找到一个与 MY_TEST 过程相对应的新的共享库。在 Solaris 上，DLL 可能有一个类似 MY_TEST__SCOTT__P__54765.so 的名称。 <br />[要阅读有关共享库命名惯例的更多信息，请点击此处。] </p>
<p><br />此外，通过执行以下查询，确保该模块的 plsql_code_type 设置的确为 NATIVE： <br />select name, type, plsql_code_type <br />from user_plsql_object_settings <br />where name = 'MY_TEST';</p>
<p>如果您想手动地对特定的已经加载的模块进行纯编译，那么您可以使用 alter ... compile .. 语句。 <br />假定您有一个程序包 MYPKG，其规范和主体是用解释方式编译的。现在，如果您只想对其主体进行纯编译，那么可以执行以下命令： </p>
<p>alter package MYPKG compile body plsql_code_type=native reuse settings<br />&nbsp;&nbsp; <br />上面的 reuse settings 子句指示编译器应当保留该单元所有以前的设置 -- 被显式覆盖的设置（如在上述示例中设定的 plsql_code_type 的设置）除外。 </p>
<p>如果从上面的语句中删除了 body 子句，如： </p>
<p>alter package MYPKG compile plsql_code_type=native reuse settings<br />... 那么规范和主体都将在纯编译模式下重新编译。不过请注意，重新编译规范将造成依赖于该规范的其他模块失效。 </p>
<p>&nbsp;</p>
<p>--------------------------------------------------------------------------------</p>
<p>将数据库中的所有 PL/SQL 单元进行纯编译 </p>
<p>在试图将数据库中的所有 PL/SQL 单元进行纯编译之前，在一个简单的测试案例上试验一下（如上一部分所述）。这将帮助确保您的纯编译设置是正确的。</p>
<p>操作系统文件描述符限制 <br />$ORACLE_HOME/rdbms/admin 目录下的两个 SQL*Plus 脚本（dbmsupgnv.sql 和 utlrp.sql）用来在纯编译模式下重新编译所有的 PL/SQL 模块。它们使用并行作业（取决于可用的 CPU 的数量）。在这种情况下，许多作业同时生成 C 文件并试图编译它们。因此不将文件描述符的最大数的 OS 限制设得过低非常重要。 </p>
<p>例如，在我的 Solaris 计算机上：</p>
<p>% ulimit -a<br />time(seconds)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; unlimited<br />file(blocks)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; unlimited<br />data(kbytes)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2097148<br />stack(kbytes)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 8192<br />coredump(blocks)&nbsp;&nbsp;&nbsp;&nbsp; 3<br />nofiles(descriptors) 64</p>
<p>vmemory(kbytes)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; unlimited</p>
<p>注意描述符的最大数（值为 64）。这在生产环境中太少了，因为有许多作业要进行并行纯编译。您可能想查看您计算机上的限制，并将其提高。例如： </p>
<p>在 Solaris 上，需要编辑 /etc/system 文件，使之包含： </p>
<p>set rlim_fd_max=4096<br />set rlim_fd_cur=1024</p>
<p>在 HP-UX 上，相应的参数位于 /stand/system 文件中。 </p>
<p>maxfiles&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 2048 <br />maxfiles_lim&nbsp;&nbsp;&nbsp; 2048 </p>
<p><br />系统表空间 <br />因为 DLLs 的主副本存储在字典表中，因此您可能需要比以前更多的 SYSTEM 表空间。如果您遇到了与 SYSTEM 表空间的空间限制相关的错误，那么您将需要执行如下操作： </p>
<p>alter tablespace system<br />add datafile '/home/kmuthukk/oracle10g/dbs/mydata10.dbf'<br />size 500 m;</p>
<p>.. 或在数据文件上设置 autoextend。 </p>
<p><br />以纯编译模式重新编译所有的模块（dbmsupgnv.sql 和 utlrp.sql）</p>
<p>关闭所有的应用程序服务（包括 Forms Processe、Web Server、Reports Server 和 Concurrent Manager Server）。在关闭所有的应用程序服务之后，确保中断了所有与数据库的连接。 </p>
<p>关闭数据库的 TNS 监听器，以确保不会创建新的连接。 </p>
<p>关闭数据库（以正常模式或即时模式）。 </p>
<p>确定您已在初始化参数文件中设置了 plsql_native_library_dir。如果没有，则请查看上一部分所述的步骤。 </p>
<p>在初始化参数文件中将 plsql_code_type 设为 NATIVE。 <br />plsql_code_type=NATIVE</p>
<p><br />在 UPGRADE 模式下启动数据库（使用 STARTUP UPGRADE 或 ALTER DATABASE OPEN UPGRADE）。 </p>
<p>运行以下查询，获取无效对象的数量。这个值将在稍后用于作比较，以确保重新编译没有由于纯编译故障而产生额外的无效对象。 <br />Select count(*)<br />From all_objects<br />Where status='INVALID';</p>
<p>以下查询将为您展示，纯编译模式和解释模式分别编译了多少对象。 <br />SELECT plsql_code_type, count(*) <br />FROM dba_plsql_object_settings <br />GROUP BY plsql_code_type;</p>
<p>您可能看到一些对象的 plsql_code_type 为 NULL。这些是特殊的内部对象，可以忽略。 </p>
<p><br />cd（更改目录）至 $ORACLE_HOME/rdbms/admin。 </p>
<p>运行 $ORACLE_HOME/rdbms/admin/dbmsupgnv.sql（作为 SYS 用户）。 <br />注释 1： dbmsupgnv.sql 使所有的 PL/SQL 模块失效并更新字典表，将它们的 plsql_code_type 设置修改为 NATIVE。这一阶段必须在数据库上没有其他活动进行时完成；因此，我们要求在运行 dbmsupgnv.sql 期间必须以 UPGRADE 模式启动数据库。 </p>
<p>注释 2：如果您要从数据库的一个低版本向数据库高版本升级（例如，升级到 Oracle 数据库 10g），那么您必须首先运行升级脚本，然后运行 dbmsupgnv.sql。例如，如果您正从 9.2.0.3 升级到 10.1.0，那么请首先运行升级脚本 (u0902000.sql)，然后关闭数据库并运行 dbmsupgnv.sql 脚本。 </p>
<p><br />在运行 dbmsupgnv.sql 之后提交更改 <br />SQL&gt; commit;</p>
<p><br />关闭数据库。 </p>
<p>以正常模式重新启动数据库。 </p>
<p>运行 $ORACLE_HOME/rdbms/admin/utlrp.sql 脚本（作为 SYS 用户）。这一步骤将重新编译所有的 PL/SQL 模块。[在这个过程期间，您可能想定期查看 plsql_native_library_dir 指定的目录，以确保编译过程的确创建了新的共享库。] <br />注意：这一步骤是可重新启动的。如果由于任何原因这个步骤异常终止，那么您只需重新启动这个步骤（即重新运行 utlrp.sql 脚本）。它将重新编译余下的任何无效的 PL/SQL 模块。 </p>
<p><br />在编译成功完成之后，您应当验证无效对象数少于或等于重新编译之前的无效对象数。您可以使用以下查询获取无效对象数。 <br />Select count(*)<br />From all_objects<br />Where status='INVALID';</p>
<p>再运行以下查询，以确保没有遗漏解释的模块： </p>
<p>SELECT plsql_code_type, count(*) <br />FROM dba_plsql_object_settings <br />GROUP BY plsql_code_type;</p>]]>
    </content>
</entry>

<entry>
    <title>Oracle 11g Linux单机STANDBY配置</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2008/07/oracle-11g-standby-config-on-linux.html" />
    <id>tag:www.heysky.net,2008:/digest//1.326</id>

    <published>2008-07-28T19:28:45Z</published>
    <updated>2008-07-28T19:32:57Z</updated>

    <summary><![CDATA[From: http://www.itpub.net/835722.html&nbsp;By blue_prince &nbsp; Oracle 11g Linux单机STANDBY配置 环境：RHEL 4 U5+Oracle 11.1.0.6主库SID：ora11g 备用库SID:standby主库数据文件存放目录：/home/oracle/opt/oradata/ora11g/备用库数据文件存放目录：/home/oracle/opt/oradata/standby/1、&nbsp; &nbsp; &nbsp; &nbsp; 验证主库是否归档，如果是未归档模式的话必须更改为归档模式：Sys@ORA11G&gt; archive log listDatabase log mode&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;Archive ModeAutomatic archival&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; EnabledArchive destination&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;/home/oracle/opt/oradata/ora11g/archiveOldest online log sequence&nbsp;...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="10g" label="10g" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="11g" label="11g" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="dataguard" label="dataguard" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="linux" label="Linux" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="standby" label="standby" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<p>From: <a href="http://www.itpub.net/835722.html">http://www.itpub.net/835722.html</a>&nbsp;By blue_prince</p>
<p>&nbsp;</p>
<p><strong>Oracle 11g Linux单机STANDBY配置<br /></strong></p>
<div class="t_msgfont" id="message8301314">环境：RHEL 4 U5+Oracle 11.1.0.6<br />主库SID：ora11g 备用库SID:standby<br />主库数据文件存放目录：/home/oracle/opt/oradata/ora11g/<br />备用库数据文件存放目录：/home/oracle/opt/oradata/standby/<br /><br />1、&nbsp; &nbsp; &nbsp; &nbsp; 验证主库是否归档，如果是未归档模式的话必须更改为归档模式：<br /><br />Sys@ORA11G&gt; archive log list<br />Database log mode&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;Archive Mode<br />Automatic archival&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; Enabled<br />Archive destination&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;/home/oracle/opt/oradata/ora11g/archive<br />Oldest online log sequence&nbsp; &nbsp;&nbsp;&nbsp;61<br />Next log sequence to archive&nbsp; &nbsp;63<br />Current log sequence&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;63<br /><br />2、&nbsp; &nbsp; &nbsp; &nbsp; 将主库置于FORCE LOGGING模式：<br /><br />Sys@ORA11G&gt; alter database force logging;<br /><br />3、&nbsp; &nbsp; &nbsp; &nbsp; 对主库做一个全库的RMAN备份，用于STANDBY配置：</normalfont> 
<blockquote><pre><smallfont>PHP code:</smallfont><hr><code><span style="COLOR: #000000"><br />
<span style="COLOR: #0000bb"><br /></span><span style="COLOR: #007700">[</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">@</span><span style="COLOR: #0000bb">test51&nbsp;bin</span><span style="COLOR: #007700">]$&nbsp;./</span><span style="COLOR: #0000bb">rman&nbsp;target&nbsp;</span><span style="COLOR: #007700">/<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">Recovery&nbsp;Manager</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">Release&nbsp;11.1.0.6.0&nbsp;</span><span style="COLOR: #007700">-&nbsp;</span><span style="COLOR: #0000bb">Production&nbsp;on&nbsp;Thu&nbsp;Aug&nbsp;16&nbsp;15</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">51</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">22&nbsp;2007<br />
<br /><br />
<br />Copyright&nbsp;</span><span style="COLOR: #007700">(</span><span style="COLOR: #0000bb">c</span><span style="COLOR: #007700">)&nbsp;</span><span style="COLOR: #0000bb">1982</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">2007</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">Oracle</span><span style="COLOR: #007700">.&nbsp;&nbsp;</span><span style="COLOR: #0000bb">All&nbsp;rights&nbsp;reserved</span><span style="COLOR: #007700">.<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">connected&nbsp;to&nbsp;target&nbsp;database</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">ORA11G&nbsp;</span><span style="COLOR: #007700">(</span><span style="COLOR: #0000bb">DBID</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">4026454982</span><span style="COLOR: #007700">)<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">RMAN</span><span style="COLOR: #007700">&gt;&nbsp;</span><span style="COLOR: #0000bb">backup&nbsp;database&nbsp;format&nbsp;</span><span style="COLOR: #dd0000">'/home/oracle/liuyun/%U.bak'</span><span style="COLOR: #007700">;<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">Starting&nbsp;backup&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br />using&nbsp;target&nbsp;database&nbsp;control&nbsp;file&nbsp;instead&nbsp;of&nbsp;recovery&nbsp;catalog<br />
<br />allocated&nbsp;channel</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">ORA_DISK_1<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">SID</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">121&nbsp;device&nbsp;type</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">DISK<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">starting&nbsp;full&nbsp;datafile&nbsp;backup&nbsp;set<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">specifying&nbsp;datafile</span><span style="COLOR: #007700">(</span><span style="COLOR: #0000bb">s</span><span style="COLOR: #007700">)&nbsp;</span><span style="COLOR: #0000bb">in&nbsp;backup&nbsp;set<br />
<br />input&nbsp;datafile&nbsp;file&nbsp;number</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">00004&nbsp;name</span><span style="COLOR: #007700">=/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">ora11g</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">users01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />input&nbsp;datafile&nbsp;file&nbsp;number</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">00002&nbsp;name</span><span style="COLOR: #007700">=/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">ora11g</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">sysaux01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />input&nbsp;datafile&nbsp;file&nbsp;number</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">00001&nbsp;name</span><span style="COLOR: #007700">=/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">ora11g</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">system01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />input&nbsp;datafile&nbsp;file&nbsp;number</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">00005&nbsp;name</span><span style="COLOR: #007700">=/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">ora11g</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">example01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />input&nbsp;datafile&nbsp;file&nbsp;number</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">00003&nbsp;name</span><span style="COLOR: #007700">=/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">ora11g</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">undotbs01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">starting&nbsp;piece&nbsp;1&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">finished&nbsp;piece&nbsp;1&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br />piece&nbsp;handle</span><span style="COLOR: #007700">=/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">liuyun</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">03iphp8l_1_1</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">bak&nbsp;tag</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">TAG20070816T155148&nbsp;comment</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">NONE<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">backup&nbsp;set&nbsp;complete</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">elapsed&nbsp;time</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">00</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">01</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">45<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">starting&nbsp;full&nbsp;datafile&nbsp;backup&nbsp;set<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">specifying&nbsp;datafile</span><span style="COLOR: #007700">(</span><span style="COLOR: #0000bb">s</span><span style="COLOR: #007700">)&nbsp;</span><span style="COLOR: #0000bb">in&nbsp;backup&nbsp;set<br />
<br />including&nbsp;current&nbsp;control&nbsp;file&nbsp;in&nbsp;backup&nbsp;set<br />
<br />including&nbsp;current&nbsp;SPFILE&nbsp;in&nbsp;backup&nbsp;set<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">starting&nbsp;piece&nbsp;1&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">finished&nbsp;piece&nbsp;1&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br />piece&nbsp;handle</span><span style="COLOR: #007700">=/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">liuyun</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">04iphpc9_1_1</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">bak&nbsp;tag</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">TAG20070816T155148&nbsp;comment</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">NONE<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">backup&nbsp;set&nbsp;complete</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">elapsed&nbsp;time</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">00</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">00</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">01<br />
<br />Finished&nbsp;backup&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br /></span><span style="COLOR: #007700">..<br /></span><span s< font></code><hr></pre></blockquote><normalfont>4、&nbsp; &nbsp; &nbsp; &nbsp; 准备STANDBY数据文件路径和其他路径：<br /><br />[oracle@test51 oradata]$ pwd&nbsp;&nbsp;<br />/home/oracle/opt/oradata<br />[oracle@test51 oradata]$ mkdir standby<br />[oracle@test51 oradata]$ ls<br />ora11g&nbsp;&nbsp;orcl&nbsp;&nbsp;standby<br />[oracle@test51 oradata]$ cd $ORACLE_BASE/admin<br />[oracle@test51 admin]$ mkdir standby<br />[oracle@test51 admin]$ ls<br />ora11g&nbsp;&nbsp;orcl&nbsp;&nbsp;standby<br />[oracle@test51 standby]$mkdir adump<br />[oracle@test51 standby]$mkdir dpdump<br />[oracle@test51 standby]$mkdir pfile<br />[oracle@test51 standby]$ ls<br />adump&nbsp;&nbsp;dpdump&nbsp;&nbsp;pfile<br /><br />5、更改tnsnames配置，添加主库和备用库的连接字：<br /><br />primary =<br />&nbsp;&nbsp;(DESCRIPTION =<br />&nbsp; &nbsp; (ADDRESS = (PROTOCOL = TCP)(HOST = test51)(PORT = 1522))<br />&nbsp; &nbsp; (CONNECT_DATA =<br />&nbsp; &nbsp;&nbsp; &nbsp;(SERVER = DEDICATED)<br />&nbsp; &nbsp;&nbsp; &nbsp;(SERVICE_NAME = ora11g)<br />&nbsp; &nbsp; )<br />&nbsp;&nbsp;)<br /><br />standby =<br />&nbsp;&nbsp;(DESCRIPTION =<br />&nbsp; &nbsp; (ADDRESS = (PROTOCOL = TCP)(HOST = test51)(PORT = 1522))<br />&nbsp; &nbsp; (CONNECT_DATA =<br />&nbsp; &nbsp;&nbsp; &nbsp;(SERVER = DEDICATED)<br />&nbsp; &nbsp;&nbsp; &nbsp;(SERVICE_NAME = standby)<br />&nbsp; &nbsp; )<br />&nbsp;&nbsp;)<br /><br />6、生成STANDBY控制文件：<br /><br />Sys@ORA11G&gt; alter database create standby controlfile as '/home/oracle/opt/oradata/standby/control01.ctl';<br /><br />Database altered.<br /><br />[oracle@test51 standby]$ cp control01.ctl control02.ctl<br />[oracle@test51 standby]$ cp control01.ctl control03.ctl<br />[oracle@test51 standby]$ ls<br />archive&nbsp;&nbsp;control01.ctl&nbsp;&nbsp;control02.ctl&nbsp;&nbsp;control03.ctl<br /><br />6、生成standby 初始化参数文件：<br /><br />Sys@ORA11G&gt; create pfile='$ORACLE_BASE/admin/standby/pfile/init.ora' from spfile;<br /><br />File created.<br /><br />添加以下几个参数，需要注意的是从11G开始原来备用库归档参数standby_archive_dest这个参数已经废除了，STANDBY的归档路径改为常规的归档路径log_archive_dest_n。还有原来单机配置STANDBY需要的参数lock_name_space也废除了：<br /><br />*.log_archive_config='DG_CONFIG=(ora11g,standby)'<br />*.fal_client='standby'<br />*.fal_server='primary'<br />*.db_file_name_convert='ora11g','standby'<br />*.log_file_name_convert='ora11g','standby'<br />*.standby_file_management='auto'<br />*.log_archive_dest_1='location=/home/oracle/opt/oradata/standby/archive VALID_FOR=(STANDBY_LOGFILE,STANDBY_ROLE)'<br /><br />更改后的参数文件如下，注意db_unique_name要和主库区分，否则无法MOUNT STANDBY：<br /><br />standby.__db_cache_size=234881024<br />standby.__java_pool_size=12582912<br />standby.__large_pool_size=4194304<br />standby.__oracle_base='/home/oracle/opt'#ORACLE_BASE set from environment<br />standby.__pga_aggregate_target=209715200<br />standby.__sga_target=629145600<br />standby.__shared_io_pool_size=0<br />standby.__shared_pool_size=369098752<br />standby.__streams_pool_size=0<br />*.audit_file_dest='/home/oracle/opt/admin/standby/adump'<br />*.audit_trail='db'<br />*.compatible='11.1.0.0.0'<br />*.control_files='/home/oracle/opt/oradata/standby/control01.ctl','/home/oracle/opt/oradata/standby/control02.ctl','/home/oracle/opt/oradata/standby/control03.ctl'<br />*.db_block_size=8192<br />*.db_domain=''<br />*.db_name='ora11g'<br />*.db_recovery_file_dest='/home/oracle/opt/flash_recovery_area'<br />*.db_recovery_file_dest_size=2147483648<br />*.db_unique_name='standby'<br />*.ddl_lock_timeout=10<br />*.diagnostic_dest='/home/oracle/opt'<br />*.dispatchers=''<br />*.job_queue_processes=0<br />*.local_listener='LISTENER_ora11g'<br />*.memory_target=838860800<br />*.open_cursors=300<br />*.processes=150<br />*.remote_login_passwordfile='EXCLUSIVE'<br />*.undo_tablespace='UNDOTBS1'<br /><br />*.log_archive_config='DG_CONFIG=(ora11g,standby)'<br />*.fal_client='standby'<br />*.fal_server='primary'<br />*.db_file_name_convert='ora11g','standby'<br />*.log_file_name_convert='ora11g','standby'<br />*.standby_file_management='auto'<br />*.log_archive_dest_1='location=/home/oracle/opt/oradata/standby/archive VALID_FOR=(STANDBY_LOGFILE,STANDBY_ROLE)'<br /><br />7、启动STANDBY数据库，进行RESTORE：</normalfont> <blockquote><pre><smallfont>PHP code:</smallfont><hr><code><span style="COLOR: #000000"><br />
<span style="COLOR: #0000bb"><br /></span><span style="COLOR: #007700">[</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">@</span><span style="COLOR: #0000bb">test51&nbsp;standby</span><span style="COLOR: #007700">]$&nbsp;</span><span style="COLOR: #0000bb">export&nbsp;ORACLE_SID</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">standby<br />
<br /></span><span style="COLOR: #007700">[</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">@</span><span style="COLOR: #0000bb">test51&nbsp;standby</span><span style="COLOR: #007700">]$&nbsp;</span><span style="COLOR: #0000bb">sql<br />
<br /><br />
<br />SQL</span><span style="COLOR: #007700">*</span><span style="COLOR: #0000bb">Plus</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">Release&nbsp;10.2.0.1.0&nbsp;</span><span style="COLOR: #007700">-&nbsp;</span><span style="COLOR: #0000bb">Production&nbsp;on&nbsp;Thu&nbsp;Aug&nbsp;16&nbsp;16</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">27</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">08&nbsp;2007<br />
<br /><br />
<br />Copyright&nbsp;</span><span style="COLOR: #007700">(</span><span style="COLOR: #0000bb">c</span><span style="COLOR: #007700">)&nbsp;</span><span style="COLOR: #0000bb">1982</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">2005</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">Oracle</span><span style="COLOR: #007700">.&nbsp;&nbsp;</span><span style="COLOR: #0000bb">All&nbsp;rights&nbsp;reserved</span><span style="COLOR: #007700">.<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">Connected&nbsp;to&nbsp;an&nbsp;idle&nbsp;instance</span><span style="COLOR: #007700">.<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">idle</span><span style="COLOR: #007700">&gt;&nbsp;</span><span style="COLOR: #0000bb">startup&nbsp;nomount&nbsp;pfile</span><span style="COLOR: #007700">=</span><span style="COLOR: #dd0000">'$ORACLE_BASE/admin/standby/pfile/init.ora'<br />
<br /></span><span style="COLOR: #0000bb">ORACLE&nbsp;instance&nbsp;started</span><span style="COLOR: #007700">.<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">Total&nbsp;System&nbsp;</span><span style="COLOR: #007700">Global&nbsp;</span><span style="COLOR: #0000bb">Area&nbsp;&nbsp;836976640&nbsp;bytes<br />
<br />Fixed&nbsp;Size&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1303132&nbsp;bytes<br />
<br />Variable&nbsp;Size&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;595594660&nbsp;bytes<br />
<br />Database&nbsp;Buffers&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;234881024&nbsp;bytes<br />
<br />Redo&nbsp;Buffers&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;5197824&nbsp;bytes<br />
<br />idle</span><span style="COLOR: #007700">&gt;&nbsp;</span><span style="COLOR: #0000bb">alter&nbsp;database&nbsp;mount&nbsp;standby&nbsp;database</span><span style="COLOR: #007700">;<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">Database&nbsp;altered</span><span style="COLOR: #007700">.<br />
<br /><br />
<br />[</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">@</span><span style="COLOR: #0000bb">test51&nbsp;bin</span><span style="COLOR: #007700">]$&nbsp;./</span><span style="COLOR: #0000bb">rman&nbsp;target&nbsp;</span><span style="COLOR: #007700">/<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">Recovery&nbsp;Manager</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">Release&nbsp;11.1.0.6.0&nbsp;</span><span style="COLOR: #007700">-&nbsp;</span><span style="COLOR: #0000bb">Production&nbsp;on&nbsp;Thu&nbsp;Aug&nbsp;16&nbsp;16</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">30</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">11&nbsp;2007<br />
<br /><br />
<br />Copyright&nbsp;</span><span style="COLOR: #007700">(</span><span style="COLOR: #0000bb">c</span><span style="COLOR: #007700">)&nbsp;</span><span style="COLOR: #0000bb">1982</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">2007</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">Oracle</span><span style="COLOR: #007700">.&nbsp;&nbsp;</span><span style="COLOR: #0000bb">All&nbsp;rights&nbsp;reserved</span><span style="COLOR: #007700">.<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">connected&nbsp;to&nbsp;target&nbsp;database</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">ORA11G&nbsp;</span><span style="COLOR: #007700">(</span><span style="COLOR: #0000bb">DBID</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">4026454982</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">not&nbsp;open</span><span style="COLOR: #007700">)<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">RMAN</span><span style="COLOR: #007700">&gt;&nbsp;</span><span style="COLOR: #0000bb">restore&nbsp;database</span><span style="COLOR: #007700">;<br />
<br /><br />
<br /></span><span style="COLOR: #0000bb">Starting&nbsp;restore&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br />Starting&nbsp;implicit&nbsp;crosscheck&nbsp;backup&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br />using&nbsp;target&nbsp;database&nbsp;control&nbsp;file&nbsp;instead&nbsp;of&nbsp;recovery&nbsp;catalog<br />
<br />allocated&nbsp;channel</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">ORA_DISK_1<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">SID</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">147&nbsp;device&nbsp;type</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">DISK<br />
<br />Crosschecked&nbsp;4&nbsp;objects<br />
<br />Finished&nbsp;implicit&nbsp;crosscheck&nbsp;backup&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br /><br />
<br />Starting&nbsp;implicit&nbsp;crosscheck&nbsp;copy&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br />using&nbsp;channel&nbsp;ORA_DISK_1<br />
<br />Crosschecked&nbsp;2&nbsp;objects<br />
<br />Finished&nbsp;implicit&nbsp;crosscheck&nbsp;copy&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br /><br />
<br />searching&nbsp;</span><span style="COLOR: #007700">for&nbsp;</span><span style="COLOR: #0000bb">all&nbsp;files&nbsp;in&nbsp;the&nbsp;recovery&nbsp;area<br />
<br />cataloging&nbsp;files</span><span style="COLOR: #007700">...<br />
<br /></span><span style="COLOR: #0000bb">no&nbsp;files&nbsp;cataloged<br />
<br /><br />
<br />using&nbsp;channel&nbsp;ORA_DISK_1<br />
<br /><br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">starting&nbsp;datafile&nbsp;backup&nbsp;set&nbsp;restore<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">specifying&nbsp;datafile</span><span style="COLOR: #007700">(</span><span style="COLOR: #0000bb">s</span><span style="COLOR: #007700">)&nbsp;</span><span style="COLOR: #0000bb">to&nbsp;restore&nbsp;from&nbsp;backup&nbsp;set<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">restoring&nbsp;datafile&nbsp;00001&nbsp;to&nbsp;</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">standby</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">system01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">restoring&nbsp;datafile&nbsp;00002&nbsp;to&nbsp;</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">standby</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">sysaux01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">restoring&nbsp;datafile&nbsp;00003&nbsp;to&nbsp;</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">standby</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">undotbs01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">restoring&nbsp;datafile&nbsp;00004&nbsp;to&nbsp;</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">standby</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">users01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">restoring&nbsp;datafile&nbsp;00005&nbsp;to&nbsp;</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">opt</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oradata</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">standby</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">example01</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">dbf<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">reading&nbsp;from&nbsp;backup&nbsp;piece&nbsp;</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">liuyun</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">03iphp8l_1_1</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">bak<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">piece&nbsp;handle</span><span style="COLOR: #007700">=/</span><span style="COLOR: #0000bb">home</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">oracle</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">liuyun</span><span style="COLOR: #007700">/</span><span style="COLOR: #0000bb">03iphp8l_1_1</span><span style="COLOR: #007700">.</span><span style="COLOR: #0000bb">bak&nbsp;tag</span><span style="COLOR: #007700">=</span><span style="COLOR: #0000bb">TAG20070816T155148<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">restored&nbsp;backup&nbsp;piece&nbsp;1<br />
<br />channel&nbsp;ORA_DISK_1</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">restore&nbsp;complete</span><span style="COLOR: #007700">,&nbsp;</span><span style="COLOR: #0000bb">elapsed&nbsp;time</span><span style="COLOR: #007700">:&nbsp;</span><span style="COLOR: #0000bb">00</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">02</span><span style="COLOR: #007700">:</span><span style="COLOR: #0000bb">05<br />
<br />Finished&nbsp;restore&nbsp;at&nbsp;16</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">AUG</span><span style="COLOR: #007700">-</span><span style="COLOR: #0000bb">07<br />
<br /></span><span style="COLOR: #007700">..<br /></span><span s< font></code><hr></pre></blockquote><normalfont>8、添加STANDBY LOGFILE，启动STANDBY至恢复管理模式：<br />[php]<br /><br />idle&gt; alter database add standby logfile '/home/oracle/opt/oradata/standby/redo04.log' size 50M;<br /><br />Database altered.<br /><br />Elapsed: 00:00:01.06<br />idle&gt; alter database add standby logfile '/home/oracle/opt/oradata/standby/redo05.log' size 50M;<br /><br />Database altered.<br /><br />Elapsed: 00:00:01.18<br />idle&gt; alter database add standby logfile '/home/oracle/opt/oradata/standby/redo06.log' size 50M;<br /><br />Database altered.<br /><br />Elapsed: 00:00:00.85<br /><br />idle&gt; recover managed standby database disconnect from session;<br />Media recovery complete.<br />..<br />[php]<br />9、主库配置到STANDBY的归档：<br /><br />Sys@ORA11G&gt; alter system set log_archive_dest_state_2=enable;<br /><br />System altered.<br /><br />Sys@ORA11G&gt; alter system set log_archive_dest_2='service=standby ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=standby';<br /><br />System altered.<br /><br />VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE)这个在我配置的过程中是必须要的，我自作主张把里面的PRIMARY_ROLE改为STANDBY _ROLE，归档无法从主库传至STANDBY了。<br /><br />10、可以看到STANDBY端已经收到主库传递过来的归档日志了：<br /><br />[oracle@test51 archive]$ ls -l<br />total 7236<br />-rw-r-----&nbsp;&nbsp;1 oracle oracle 7392768 Aug 16 16:46 1_63_630254857.dbf<br /><br />Redo Shipping Client Connected as PUBLIC<br />-- Connected User is Valid<br />RFS[2]: Assigned to RFS process 5315<br />RFS[2]: Identified database type as 'physical standby'<br />Primary database is in MAXIMUM PERFORMANCE mode<br />Primary database is in MAXIMUM PERFORMANCE mode<br />RFS[2]: Successfully opened standby log 4: '/home/oracle/opt/oradata/standby/redo04.log'<br />Thu Aug 16 16:46:21 2007<br />Media Recovery Log /home/oracle/opt/oradata/standby/archive/1_63_630254857.dbf<br />Media Recovery Waiting for thread 1 sequence 64 (in transit)<br /><br />这样STANDBY就配置完成了。<br /></span></span></span></span></div>]]>
        
    </content>
</entry>

<entry>
    <title>在linux上单机模拟Oracle 10g RAC集群（OCFS+ASM)</title>
    <link rel="alternate" type="text/html" href="http://www.heysky.net/digest/2008/07/oracle-10g-rac-simulation-on-linux.html" />
    <id>tag:www.heysky.net,2008:/digest//1.325</id>

    <published>2008-07-28T19:13:50Z</published>
    <updated>2008-07-28T19:26:54Z</updated>

    <summary><![CDATA[From: http://www.linuxsir.org/bbs/thread198024.html&nbsp;By daniey Word 文档下载：&nbsp; linux_srac.doc &nbsp; 在linux上单机模拟Oracle 10g RAC集群（OCFS+ASM) &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 作者：daniey MSN:danieyren@hotmail.com 申明：请珍惜作者劳动，如需要转载，请注明出处 &nbsp;&nbsp;&nbsp; 本文是在参考oracle 10g 双机集群的基础上通过实践并且精简而得，撰写本文的目的是为了方便大家探讨技术，相信本文仍有许多不足之处 参考文档：http://www.oracle.com/technology/global/cn/pub/articles/hunter_rac10g.html 注：对于与多机多节点集群相同的地方，文中将直接引用参考文档相关部分 一、简介 &nbsp;&nbsp;&nbsp; 熟悉 Oracle 真正应用集群 (RAC) 10g 技术的最有效方法之一是访问一个实际的 Oracle RAC 10g 集群。没有什么方法比直接体验它们能够更好地理解其好处的了 -- 包括容错、安全性、负载均衡和可伸缩性。 &nbsp;&nbsp;&nbsp; Oracle RAC 的核心是共享磁盘子系统。集群中的所有节点必须能够访问集群中所有节点的所有数据、重做日志文件、控制文件和参数文件。数据磁盘必须在全局范围内可用，以便允许所有节点访问数据库。每个节点拥有自己的重做日志和控制文件，但是其他节点必须能够访问这些文件，以便在系统故障时恢复该节点。 &nbsp; 希望本文能对一些手头上只有一台PC而没有真正的双机环境的朋友提供一个参考。...]]></summary>
    <author>
        <name>Sky</name>
        <uri>http://www.heysky.net</uri>
    </author>
    
        <category term="Oracle" scheme="http://www.sixapart.com/ns/types#category" />
    
    <category term="10g" label="10g" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="asm" label="ASM" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="linux" label="Linux" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="ocfs" label="OCFS" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="oracle" label="Oracle" scheme="http://www.sixapart.com/ns/types#tag" />
    <category term="rac" label="RAC" scheme="http://www.sixapart.com/ns/types#tag" />
    
    <content type="html" xml:lang="en-US" xml:base="http://www.heysky.net/digest/">
        <![CDATA[<p><em>From: </em><a href="http://www.linuxsir.org/bbs/thread198024.html"><em>http://www.linuxsir.org/bbs/thread198024.html</em></a><em>&nbsp;By daniey</em></p>
<p><span><font color="#000000"><strong><br />Word 文档下载：&nbsp;
<span class="mt-enclosure mt-enclosure-file" style="DISPLAY: inline"><a href="http://www.heysky.net/digest/uploads/2008/linux_srac.doc">linux_srac.doc</a></span></strong></font></span></p>
<p>&nbsp;</p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt; TEXT-ALIGN: center" align="center"><span><strong><font color="#000000">在<font face="Times New Roman">linux</font>上单机模拟</font></strong></span><span><font face="Times New Roman"><font color="#000000"><strong>Oracle 10</strong><em>g</em></font></font><strong><font color="#000000"><font face="Times New Roman"> RAC</font>集群（<font face="Times New Roman">OCFS+ASM)<o:p></o:p></font></font></strong></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt; TEXT-ALIGN: center" align="center"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><span style="mso-tab-count: 1"><font face="Times New Roman">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </font></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">作者：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">daniey<span style="mso-tab-count: 1"> </span>MSN:danieyren@hotmail.com<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">申明：请珍惜作者劳动，如需要转载，请注明出处</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><span style="mso-spacerun: yes"><font face="Times New Roman">&nbsp;&nbsp;&nbsp; </font></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">本文是在参考</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oracle 10g </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">双机集群的基础上通过实践并且精简而得，撰写本文的目的是为了方便大家探讨技术，相信本文仍有许多不足之处</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><font color="#000000">参考文档：</font></span><span lang="EN-US"><a href="http://www.oracle.com/technology/global/cn/pub/articles/hunter_rac10g.html"><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">http://www.oracle.com/technology/global/cn/pub/articles/hunter_rac10g.html</font></span></a></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">注：对于与多机多节点集群相同的地方，文中将直接引用参考文档相关部分</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">一、简介</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 20.1pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><span style="mso-spacerun: yes"><font face="Times New Roman">&nbsp;&nbsp;&nbsp; </font></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">熟悉</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> Oracle </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">真正应用集群</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> (RAC) 10g </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">技术的最有效方法之一是访问一个实际的</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> Oracle RAC 10g </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">集群。没有什么方法比直接体验它们能够更好地理解其好处的了</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> -- </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">包括容错、安全性、负载均衡和可伸缩性。</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 20.1pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"><span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp; </span>Oracle RAC </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">的核心是共享磁盘子系统。集群中的所有节点必须能够访问集群中所有节点的所有数据、重做日志文件、控制文件和参数文件。数据磁盘必须在全局范围内可用，以便允许所有节点访问数据库。每个节点拥有自己的重做日志和控制文件，但是其他节点必须能够访问这些文件，以便在系统故障时恢复该节点。</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 20.1pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><span style="mso-spacerun: yes"><font face="Times New Roman">&nbsp; </font></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">希望本文能对一些手头上只有一台</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">PC</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">而没有真正的双机环境的朋友提供一个参考。</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">二、本文实践环境</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 21.45pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">1</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">PC</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">主要配置：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Celeron(R) CPU 1.80GHz<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Maxtor 6E040L0, ATA DISK drive 40G<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">RelTek 8139C </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">网卡</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">一块</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">内存</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">DDR333 512MB * 2<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">显示卡：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">ATI [Radeon 9200 SE] <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><font color="#000000">操作系统</font></span><span lang="EN-US"><a href="http://www.whiteboxlinux.org/download.html"><font color="#000080"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">：</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">White Box Enterprise Linux 3 </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">（本文同样适用于</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">RedHat</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">企业版</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">,</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">不同之处是</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">WBEL3</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">目前可以免费运用于商业</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">)</font></span></font></a></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><span lang="EN-US"><a href="http://www.whiteboxlinux.org/download.html"><font color="#000080"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">远程终端一台，装有</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">windowsXP</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">和远程</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">X-server</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">软件</span></font></a></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.75pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">2</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、服务器分区方案</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt; TEXT-ALIGN: center" align="center"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">Oracle </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">数据库文件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p>
<table class="MsoNormalTable" style="MARGIN: auto auto auto 25.1pt; BORDER-COLLAPSE: collapse; mso-table-layout-alt: fixed; mso-padding-alt: 2.75pt 2.75pt 2.75pt 2.75pt" cellspacing="0" cellpadding="0" border="0">
<thead>
<tr style="page-break-inside: avoid">
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.3pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-top-alt: solid black .25pt; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="127">
<p class="WW-1" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span lang="EN-US" style="FONT-WEIGHT: normal; FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">RAC</font></span><span style="FONT-WEIGHT: normal; FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">节点名</span><span lang="EN-US" style="FONT-WEIGHT: normal; FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.35pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-top-alt: solid black .25pt; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="127">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">实例名</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.35pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-top-alt: solid black .25pt; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="127">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">数据库名</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.3pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-top-alt: solid black .25pt; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="127">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">$ORACLE_BASE<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 69.9pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-alt: solid black .25pt" valign="top" width="93">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件系统</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p></td></tr></thead>
<tbody>
<tr style="page-break-inside: avoid; mso-yfti-lastrow: yes">
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.3pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="127">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">dbrac<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.35pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="127">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">orcl1<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.35pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="127">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">orcl<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.3pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="127">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/home/oracle<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 69.9pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt; mso-border-right-alt: solid black .25pt" valign="top" width="93">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">ASM<o:p></o:p></font></font></span></p></td></tr></tbody></table></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt; TEXT-ALIGN: center" align="center"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">Oracle CRS </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">共享文件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p>
<table class="MsoNormalTable" style="MARGIN: auto auto auto 25.1pt; BORDER-COLLAPSE: collapse; mso-table-layout-alt: fixed; mso-padding-alt: 2.75pt 2.75pt 2.75pt 2.75pt" cellspacing="0" cellpadding="0" border="0">
<thead>
<tr style="page-break-inside: avoid">
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-top-alt: solid black .25pt; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="MsoBodyText" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件类型</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-top-alt: solid black .25pt; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="MsoBodyText" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件名</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-top-alt: solid black .25pt; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="MsoBodyText" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-top-alt: solid black .25pt; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="MsoBodyText" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">挂载点</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p></td>
<td style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 2.75pt; BORDER-TOP: black 1pt solid; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 67pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-alt: solid black .25pt" valign="top" width="89">
<p class="WW-1" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-WEIGHT: normal; FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件系统</span><span lang="EN-US" style="FONT-WEIGHT: normal; FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p></td></tr></thead>
<tbody>
<tr style="page-break-inside: avoid">
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oracle</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">集群注册表</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/u01/orcl/orcfile<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda8<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/u01<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 67pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt; mso-border-right-alt: solid black .25pt" valign="top" width="89">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">OCFS<o:p></o:p></font></font></span></p></td></tr>
<tr style="page-break-inside: avoid; mso-yfti-lastrow: yes">
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">CRS</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">表决磁盘</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/u01/orcl/cssfile<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda8<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: #f0f0f0; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 95.85pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt" valign="top" width="128">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/u01<o:p></o:p></font></font></span></p></td>
<td style="BORDER-RIGHT: black 1pt solid; PADDING-RIGHT: 2.75pt; BORDER-TOP: #f0f0f0; PADDING-LEFT: 2.75pt; PADDING-BOTTOM: 2.75pt; BORDER-LEFT: black 1pt solid; WIDTH: 67pt; PADDING-TOP: 2.75pt; BORDER-BOTTOM: black 1pt solid; BACKGROUND-COLOR: transparent; mso-border-left-alt: solid black .25pt; mso-border-bottom-alt: solid black .25pt; mso-border-right-alt: solid black .25pt" valign="top" width="89">
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">OCFS<o:p></o:p></font></font></span></p></td></tr></tbody></table></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 20.75pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">3</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、所涉及软件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.25pt; TEXT-INDENT: -14.15pt; mso-list: l0 level1 lfo1; tab-stops: list 14.15pt"><font face="Times New Roman"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font color="#000000">1)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></span></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000">oracle 10g </font></span></font><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">数据库软件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">ship.db.lnx32.cpio.gz<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.25pt; TEXT-INDENT: -14.15pt; mso-list: l0 level1 lfo1; tab-stops: list 14.15pt"><font face="Times New Roman"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font color="#000000">2)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></span></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000">oracle 10g </font></span></font><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">集群服务软件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">ship.crs.lnx32.cpio.gz<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.25pt; TEXT-INDENT: -14.15pt; mso-list: l0 level1 lfo1; tab-stops: list 14.15pt"><font face="Times New Roman"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font color="#000000">3)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></span></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000">OCFS</font></span></font><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件系统支持</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">ocfs-2.4.21-EL-1.0.14-1.i686.rpm<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">ocfs-support-1.0.10-1.i386.rpm<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">ocfs-tools-1.0.10-1.i386.rpm<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.25pt; TEXT-INDENT: -14.15pt; mso-list: l0 level1 lfo1; tab-stops: list 14.15pt"><font face="Times New Roman"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font color="#000000">4)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></span></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000">ASMlib</font></span></font><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">驱动程序</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">oracleasm-2.4.21-EL-1.0.3-1.i686.rpm<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">oracleasm-support-1.0.3-1.i386.rpm<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">oracleasmlib-1.0.0-1.i386.rpm<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">以上软件包均可以从</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oracle</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">官方网站下载</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">WBEL linux</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">下载地址：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">http://www.whiteboxlinux.org/download.html<span style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp; </span><o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">三、基础操作</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">1</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、安装</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">linux<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">安装过程中一些需要注意的地方：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt; TEXT-INDENT: -14.15pt; mso-list: l1 level1 lfo2; tab-stops: list 14.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font face="Times New Roman"><font color="#000000">1)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></font></span></span><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">磁盘分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">:swap</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区大小建议是内存的</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">2</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">倍，这里是</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">2048MB,</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">划出一些系统必要的分区根分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/,var</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/var,usr</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/usr,home</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/home,</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">临时文件分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/tmp</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">。注意：这里不要把所有的硬盘空间划分进操作系统，留下一半给后面安装</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oarcle</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">集群磁盘使用，本文示例</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt; TEXT-INDENT: -14.15pt; mso-list: l1 level1 lfo2; tab-stops: list 14.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font face="Times New Roman"><font color="#000000">2)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></font></span></span><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件系统</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><span style="mso-spacerun: yes"><font face="Times New Roman">&nbsp;&nbsp;&nbsp;&nbsp; </font></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">容量</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><span style="mso-spacerun: yes"><font face="Times New Roman">&nbsp; </font></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">挂载点</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53.55pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda1<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1012M<span style="mso-spacerun: yes">&nbsp; </span>/<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53.55pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda2<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>7.7G<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>/home<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53.55pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda7<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1012M<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>/tmp<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53.55pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda3<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>5.8G<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>/usr<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53.55pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda5<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2.0G<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>/var<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt; TEXT-INDENT: -14.15pt; mso-list: l1 level1 lfo2; tab-stops: list 14.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font face="Times New Roman"><font color="#000000">3)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></font></span></span><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">组件选取：一定要选上</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">delvelopment tools</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">和</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">X-windows</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">两项，为了节省空间其他可以不要</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt; TEXT-INDENT: -14.15pt; mso-list: l1 level1 lfo2; tab-stops: list 14.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font face="Times New Roman"><font color="#000000">4)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></font></span></span><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">防火墙：最好不要</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt; TEXT-INDENT: -14.15pt; mso-list: l1 level1 lfo2; tab-stops: list 14.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font face="Times New Roman"><font color="#000000">5)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></font></span></span><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">网络设置：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">eth0<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">取消选中</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> [Configure using DHCP] </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">复选项</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">选中</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> [Activate on boot]<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">IP </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">地址：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">192.168.22.44<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">网络掩码：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> 255.255.255.0<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 53pt; TEXT-INDENT: -14.15pt; mso-list: l1 level1 lfo2; tab-stops: list 14.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font face="Times New Roman"><font color="#000000">6)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></font></span></span><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">主机名</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">:dbrac<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 23.45pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">2</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">.</font></span><span>安装完成后<em>检查必需的</em></span><span><font face="Times New Roman"><em> RPM</em> <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 23.45pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">3</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、必须安装以下程序包（或更高版本）：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 12.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">make-3.79.1<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">gcc-3.2.3-34<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">glibc-2.3.2-95.20<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">glibc-devel-2.3.2-95.20<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">glibc-headers-2.3.2-95.20<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">glibc-kernheaders-2.4-8.34<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">cpp-3.2.3-34<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">compat-db-4.0.14-5<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">compat-gcc-7.3-2.96.128<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">compat-gcc-c++-7.3-2.96.128<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">compat-libstdc++-7.3-2.96.128<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">compat-libstdc++-devel-7.3-2.96.128<o:p></o:p></font></span></p>
<p class="WW-2" style="MARGIN: 0cm 0cm 0pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: 'Times New Roman','serif'; mso-fareast-font-family: 宋体; mso-bidi-font-family: 'Courier New'; mso-bidi-font-size: 10.0pt"><font color="#000000">openmotif-2.2.2-16<o:p></o:p></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 40.2pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">setarch-1.3-1<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">四、设置</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 21.45pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">1</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、更改</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/etc/hosts<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">vi /etc/hosts<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">127.0.0.1<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>localhost.localdomain localhost<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">192.168.22.44<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>dbrac<span style="mso-tab-count: 1">&nbsp;&nbsp; </span>int-dbrac<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">192.168.22.244<span style="mso-tab-count: 1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>vip-dbrac<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">确保</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">RAC</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">节点名没有出现在回送地址中。</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">此处设置相当重要，不能跳过，一定按照此设置，</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">IP</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">和主机别名可以自己定</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oracle 10g RAC</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">中</span><span style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">使用了虚拟</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">IP(VIP)</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">技术，这是一个令人心动的高可用性、多机无缝切换的解决方案</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">,</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">但在单机模拟环境中仅仅是个形式而已，为了以后的顺利安装，不得不配置它</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">2</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、调整内核网络设置参数</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">编辑</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/etc/sysctl.conf</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">，增加下面的设置：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">vi /etc/sysctl.conf<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"># Default setting in bytes of the socket receive buffer<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">net.core.rmem_default=262144<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"># Default setting in bytes of the socket send buffer<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">net.core.wmem_default=262144<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"># Maximum socket receive buffer size which may be set by using<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"># the SO_RCVBUF socket option<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">net.core.rmem_max=262144<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"># Maximum socket send buffer size which may be set by using <o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"># the SO_SNDBUF socket option<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">net.core.wmem_max=262144<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">3</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、添加模块选项：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">将下列行添加到</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> /etc/modules.conf </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">中：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">options sbp2 sbp2_exclusive_login=0<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">4</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、创建</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">"oracle"</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">用户和目录</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">$su -<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">#groupadd dba<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">#useradd -g dba -m oracle<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">#passwd oracle<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 21.45pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">5</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、编辑</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">.bash_profile</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件，增加</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oracle</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">环境变量</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">$vi .bash_profile<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export PATH<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">unset USERNAME<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export LANG=zh_CN.EUC<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">ORACLE_BASE=/home/oracle;export ORACLE_BASE<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export ORACLE_HOME=$ORACLE_BASE/product/10.1.0/db_1<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export ORA_CRS_HOME=$ORACLE_BASE/product/10.1.0/crs_1<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export ORACLE_SID=rac1<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export NLS_LANG='SIMPLIFIED CHINESE_CHINA.ZHS16GBK'<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">PATH=$ORACLE_HOME/bin:/bin:/sbin:/usr/bin:/usr/ccs/bin:/usr/local/bin:/usr/ucb;export PATH<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">LD_LIBRARY_PATH=$ORACLE_HOME/lib:$ORACLE_HOME/network/lib:$ORACLE_HOME/oracm/lib:/usr/local/lib:/usr/lib;export LD_LIBRARY_PATH<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export ORACLE_TERM=xterm<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib:$ORACLE_HOME/rdbms/jlib:$ORACLE_HOME/network/jlib<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export THREADS_FLAG=native<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export TEMP=/tmp<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export TMPDIR=/tmp<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 38.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">export LD_ASSUME_KERNEL=2.4.1<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 21.55pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">6</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、创建</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">CRS</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区和数据文件分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 51.65pt; TEXT-INDENT: -14.15pt; mso-list: l2 level1 lfo3; tab-stops: list 14.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font face="Times New Roman"><font color="#000000">1)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></font></span></span><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">先建立</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">CRS</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区挂载点</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.9pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">mkdir /u01<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.9pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">chown oracle:dba /u01<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 51.65pt; TEXT-INDENT: -14.15pt; mso-list: l2 level1 lfo3; tab-stops: list 14.15pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt"><span style="mso-list: Ignore"><font face="Times New Roman"><font color="#000000">2)<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp; </span></font></font></span></span><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">接着创建</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">CRS</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区和共享数据文件分区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">fdisk /dev/hda<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">CRS</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区只要</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">500M</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">就够了，剩下的全部划分给数据文件分区，这里为数据文件只分了</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">1</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">个区</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/dev/hda9<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">CRS</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">分区为</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/dev/hda8<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">[root@dbrac root]# fdisk /dev/hda<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">The number of cylinders for this disk is set to 4997.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">[root@dbrac root]# fdisk /dev/hda<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">The number of cylinders for this disk is set to 4997.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">There is nothing wrong with that, but this is larger than 1024,<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">and could in certain setups cause problems with:<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">1) software that runs at boot time (e.g., old versions of LILO)<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">2) booting and partitioning software from other OSs<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"><span style="mso-spacerun: yes">&nbsp;&nbsp; </span>(e.g., DOS FDISK, OS/2 FDISK)<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Command (m for help): p<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Disk /dev/hda: 41.1 GB, 41109061120 bytes<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">255 heads, 63 sectors/track, 4997 cylinders<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Units = cylinders of 16065 * 512 = 8225280 bytes<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"><span style="mso-spacerun: yes">&nbsp;&nbsp; </span>Device Boot<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp; </span>Start<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>End<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp; </span>Blocks<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>Id<span style="mso-spacerun: yes">&nbsp; </span>System<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda1<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>*<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>131<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>1052226<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda2<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>132<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1151<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>8193150<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda3<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1152<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1916<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>6144862+<span style="mso-spacerun: yes">&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda4<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1917<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>4998<span style="mso-spacerun: yes">&nbsp; </span>24756165<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp; </span>f<span style="mso-spacerun: yes">&nbsp; </span>Win95 Ext'd (LBA)<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda5<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1917<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2177<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>2096451<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda6 <span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>2178<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2438<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>2096451<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>82<span style="mso-spacerun: yes">&nbsp; </span>Linux swap<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda7<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2439<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2569<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>1052226<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Command (m for help): n<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">First cylinder (2570-4998, default 2570): <o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Using default value 2570<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Last cylinder or +size or +sizeM or +sizeK (2570-4998, default 4998): +500M<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Command (m for help): n<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">First cylinder (2632-4998, default 2632): <o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Using default value 2632<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Last cylinder or +size or +sizeM or +sizeK (2632-4998, default 4998): +15000M<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Command (m for help): p<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Disk /dev/hda: 41.1 GB, 41109061120 bytes<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">255 heads, 63 sectors/track, 4997 cylinders<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Units = cylinders of 16065 * 512 = 8225280 bytes<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman"><span style="mso-spacerun: yes">&nbsp;&nbsp; </span>Device Boot<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp; </span>Start<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>End<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp; </span>Blocks<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>Id<span style="mso-spacerun: yes">&nbsp; </span>System<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda1<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>*<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>131<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>1052226<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda2<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>132<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1151<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>8193150<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda3<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1152<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1916<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>6144862+<span style="mso-spacerun: yes">&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda4<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1917<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>4998<span style="mso-spacerun: yes">&nbsp; </span>24756165<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp; </span>f<span style="mso-spacerun: yes">&nbsp; </span>Win95 Ext'd (LBA)<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda5<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>1917<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2177<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>2096451<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda6<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2178<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2438<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>2096451<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>82<span style="mso-spacerun: yes">&nbsp; </span>Linux swap<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda7 <span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>2439<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2569<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>1052226<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda8<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2570<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2631<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp; </span>497983+<span style="mso-spacerun: yes">&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">/dev/hda9<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2632<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>4456<span style="mso-spacerun: yes">&nbsp; </span>14659281<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>83<span style="mso-spacerun: yes">&nbsp; </span>Linux<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Command (m for help): w<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">The partition table has been altered!<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Calling ioctl() to re-read partition table.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">WARNING: Re-reading the partition table failed with error 16: </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">设备或资源忙</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">.<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">The kernel still uses the old table.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">The new table will be used at the next reboot.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 52.25pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Syncing disks.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 21.55pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">7</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、编辑</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/etc/sysctl.conf</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">，增加下面</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">2</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">行以设置系统共享内存大小和文件句柄</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">kernel.shmmax=2147483648<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">kernel.sem=250 32000 100 128<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">本文涉及到的</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">linux</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">操作系统的内核参数默认设置大多符合</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oracle</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">安装所需，不需要做更大的改动</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 21.45pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">8</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、配置</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> hangcheck-timer </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">内核模块</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">在</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/etc/modules.conf</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">中增加下面一行</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">options hangcheck-timer hangcheck_tick=30 hangcheck_margin=180<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">为了确保系统每次重新启动的时候都能自动加载</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">hangcheck-timer </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">模块，需要在</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">/etc/rc.local</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件中增加下面一行</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">echo "modprobe hangcheck-timer" &gt;&gt; /etc/rc.local<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">重启系统并检查</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">hangcheck-timer</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">模块是否已经加载</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">[root@dbrac root]# lsmod | grep hangcheck-timer<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 36.85pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">hangcheck-timer<span style="mso-spacerun: yes">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2616<span style="mso-spacerun: yes">&nbsp;&nbsp; </span>0<span style="mso-spacerun: yes">&nbsp; </span>(unused)<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 21.55pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">9</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、配置</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> RAC </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">节点以进行远程访问</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><span style="mso-spacerun: yes"><font face="Times New Roman">&nbsp;&nbsp;&nbsp; </font></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">在</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> RAC </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">节点上运行</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> Oracle Universal Installer </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">时，它将使用</span><span style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> </font></span><span class="WW-"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 12.0pt"><font face="Courier New">rsh</font></span></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">rcp</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">或</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">scp</font></span><span class="WW-"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Courier New'; mso-hansi-font-family: 'Courier New'; mso-bidi-font-size: 12.0pt">命令</span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">将</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> Oracle </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">软件复制到</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> RAC </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">集群中的所有其他节点。虽然是单机模拟，但仍然要配置，无法跳过，从</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oracle 10g</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">开始已经支持</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">ssh</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">协议，本文将首先尝试使用它</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">使用</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">oracle</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">用户创建</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">ssh</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-bidi-font-weight: bold; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">公共密匙：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">[oracle@dbrac oracle]$ ssh-keygen -t dsa<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Generating public/private dsa key pair.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Enter file in which to save the key (/home/oracle/.ssh/id_dsa): <o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Enter passphrase (empty for no passphrase): <o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Enter same passphrase again: <o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Your identification has been saved in /home/oracle/.ssh/id_dsa.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Your public key has been saved in /home/oracle/.ssh/id_dsa.pub.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">The key fingerprint is:<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt"><font face="Times New Roman"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-bidi-font-weight: bold; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000">2d:09:9a:c0:40:c7:99:46:ea:43:0d:22:4b:d0:a0:26 </font></span><span lang="EN-US"><a href="mailto:oracle@dbra"><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000080">oracle@dbra</font></span></a><a href="mailto:oracle@dbrac"><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000080">c</font></span></a></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">复制公匙到其他节点（这里是单机）</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">[oracle@dbrac oracle]$ cp -v .ssh/id_dsa.pub .ssh/authorized_keys<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">测试密匙是否生效</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">[oracle@dbrac oracle]$ ssh dbrac<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">The authenticity of host 'dbrac (192.168.22.44)' can't be established.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">RSA key fingerprint is e7:ff:ce:5e:92:ac:c4:96:a8:ca:3e:20:2e:5c:75:ae.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Are you sure you want to continue connecting (yes/no)? yes<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">Warning: Permanently added 'dbrac,192.168.22.44' (RSA) to the list of known hosts.<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font color="#000000"><font face="Times New Roman">[oracle@dbrac oracle]$<o:p></o:p></font></font></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 37.5pt; tab-stops: 139.3pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">无需密码即可登陆表示密匙已经生效</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 22.1pt; tab-stops: 123.9pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">10</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">、安装和配置</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> OCFS<o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 44.85pt; tab-stops: 146.65pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">OCFS</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">是</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">Oracle </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">集群文件系统</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> (OCFS)</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">，由</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> Oracle </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">开发，用于消除数据库管理员和系统管理员管理原始设备这一负担，它提供了与通常的文件系统相同的功能和用法。尽量不要在</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">OCFS</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件系统上使用</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">linux</font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">二进制文件系统操作命令</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 44.85pt; tab-stops: 146.65pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">在目前的版本１种支持以下文件类型：</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 59pt; TEXT-INDENT: -14.15pt; mso-list: l3 level1 lfo4; tab-stops: list 14.15pt left 160.8pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 9pt; FONT-FAMILY: Symbol; mso-fareast-font-family: Symbol; mso-bidi-font-family: Symbol"><span style="mso-list: Ignore">·<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">Oracle </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">数据库文件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 59pt; TEXT-INDENT: -14.15pt; mso-list: l3 level1 lfo4; tab-stops: list 14.15pt left 160.8pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 9pt; FONT-FAMILY: Symbol; mso-fareast-font-family: Symbol; mso-bidi-font-family: Symbol"><span style="mso-list: Ignore">·<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">联机重做日志文件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 59pt; TEXT-INDENT: -14.15pt; mso-list: l3 level1 lfo4; tab-stops: list 14.15pt left 160.8pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 9pt; FONT-FAMILY: Symbol; mso-fareast-font-family: Symbol; mso-bidi-font-family: Symbol"><span style="mso-list: Ignore">·<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">归档重做日志文件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 59pt; TEXT-INDENT: -14.15pt; mso-list: l3 level1 lfo4; tab-stops: list 14.15pt left 160.8pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 9pt; FONT-FAMILY: Symbol; mso-fareast-font-family: Symbol; mso-bidi-font-family: Symbol"><span style="mso-list: Ignore">·<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">控制文件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 59pt; TEXT-INDENT: -14.15pt; mso-list: l3 level1 lfo4; tab-stops: list 14.15pt left 160.8pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 9pt; FONT-FAMILY: Symbol; mso-fareast-font-family: Symbol; mso-bidi-font-family: Symbol"><span style="mso-list: Ignore">·<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">服务器参数文件</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> (SPFILE) <o:p></o:p></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 59pt; TEXT-INDENT: -14.15pt; mso-list: l3 level1 lfo4; tab-stops: list 14.15pt left 160.8pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 9pt; FONT-FAMILY: Symbol; mso-fareast-font-family: Symbol; mso-bidi-font-family: Symbol"><span style="mso-list: Ignore">·<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">Oracle </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">集群注册表</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> (OCR) </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">文件</span><span style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman"> <span lang="EN-US"><o:p></o:p></span></font></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 59pt; TEXT-INDENT: -14.15pt; mso-list: l3 level1 lfo4; tab-stops: list 14.15pt left 160.8pt"><font color="#000000"><span lang="EN-US" style="FONT-SIZE: 9pt; FONT-FAMILY: Symbol; mso-fareast-font-family: Symbol; mso-bidi-font-family: Symbol"><span style="mso-list: Ignore">·<span style="FONT: 7pt 'Times New Roman'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><font face="Times New Roman">CRS </font></span><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">表决磁盘。</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 44.85pt; tab-stops: 146.65pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p><font face="Times New Roman" color="#000000">&nbsp;</font></o:p></span></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 44.85pt; tab-stops: 146.65pt"><font color="#000000"><span style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; mso-ascii-font-family: 'Times New Roman'; mso-hansi-font-family: 'Times New Roman'; mso-bidi-font-size: 9.0pt">安装和配置</span><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 宋体; mso-bidi-font-size: 9.0pt"><o:p></o:p></span></font></p>
<p class="WW-0" style="MARGIN: 0cm 0cm 6pt 59pt; TEXT-INDENT: -14.15pt; mso-list: l4 level1 lfo5; tab-stops: list 14.15pt left 160.8pt"><span lang="EN-US" style="FONT-SIZE: 10.5pt; mso-fareast-font-family: 'Times 