<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Oracle Home</title>
	<atom:link href="http://www.oraclehome.com.br/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.oraclehome.com.br</link>
	<description>A casa do Oracle Brasil</description>
	<lastBuildDate>Mon, 14 May 2012 16:47:42 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Aplicando Patch Set 10.2.0.5 (8202632) no Banco de Dados Oracle 10.2.0.1 non-RAC</title>
		<link>http://www.oraclehome.com.br/2012/05/14/aplicando-patch-set-10-2-0-5-8202632-no-banco-de-dados-oracle-10-2-0-1-non-rac/</link>
		<comments>http://www.oraclehome.com.br/2012/05/14/aplicando-patch-set-10-2-0-5-8202632-no-banco-de-dados-oracle-10-2-0-1-non-rac/#comments</comments>
		<pubDate>Mon, 14 May 2012 15:40:37 +0000</pubDate>
		<dc:creator>Maycon Tomiasi</dc:creator>
				<category><![CDATA[Instalação]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Segurança]]></category>
		<category><![CDATA[10.2.0.1]]></category>
		<category><![CDATA[10.2.0.5]]></category>
		<category><![CDATA[8202632]]></category>
		<category><![CDATA[8350262]]></category>
		<category><![CDATA[aplicando]]></category>
		<category><![CDATA[banco]]></category>
		<category><![CDATA[banco de dados]]></category>
		<category><![CDATA[base]]></category>
		<category><![CDATA[catupgrd.sql]]></category>
		<category><![CDATA[dados]]></category>
		<category><![CDATA[data]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[enterprise]]></category>
		<category><![CDATA[Enterprise Manager]]></category>
		<category><![CDATA[instance]]></category>
		<category><![CDATA[manager]]></category>
		<category><![CDATA[non-RAC]]></category>
		<category><![CDATA[Patch]]></category>
		<category><![CDATA[Set]]></category>
		<category><![CDATA[single]]></category>
		<category><![CDATA[single instance]]></category>
		<category><![CDATA[utlrp.sql]]></category>
		<category><![CDATA[utlu102i.sql]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2640</guid>
		<description><![CDATA[Este artigo tem como objetivo mostrar como aplicar o patch set 10.2.0.5 (patch 8202632) para o Banco de Dados 10.2.0.1. Estou utilizando o Sistema Operacional Enterprise Linux 5.7 32 Bits, então devemos fazer o download do patch para o banco de dados Oracle deste sistema operacional. OBS: Para fazer o download é necessário obter as [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">Este artigo tem como objetivo mostrar como aplicar o patch set 10.2.0.5 (patch 8202632) para o Banco de Dados 10.2.0.1.<br />
Estou utilizando o Sistema Operacional Enterprise Linux 5.7 32 Bits, então devemos fazer o download do patch para o banco de dados Oracle deste sistema operacional.<br />
OBS: Para fazer o download é necessário obter as credenciais do Suporte da Oracle.<br />
Download do Patch <a href="https://updates.oracle.com/Orion/PatchDetails/handle_plat_lang_change?plat_lang=226P&amp;patch_file=&amp;file_id=&amp;password_required=&amp;password_required_readme=&amp;merged_trans=&amp;aru=12540824&amp;patch_num=8202632&amp;patch_num_id=1253975&amp;default_release=80102050&amp;default_plat_lang=46P&amp;default_compatible_with=&amp;patch_password=&amp;orderby=&amp;direction=&amp;no_header=0&amp;sortcolpressed=&amp;tab_number=" target="_blank">8202632</a></p>
<div id="attachment_2650" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/download.jpg"><img class="size-thumbnail wp-image-2650" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/download-150x150.jpg" alt="Download Patch Set 10.2.0.5" width="150" height="150" /></a><p class="wp-caption-text">Download Patch Set 10.2.0.5</p></div>
<p>Após fazer o download do Patch em questão, basta descompactar o mesmo no servidor de Banco de Dados.<br />
OBS: Sempre antes de aplicar o Patch no Banco de Dados, fazer o backup do seu Produto Oracle. Ao aplicar o mesmo, certificar se todos os serviços Oracle esteja baixados.<br />
<span id="more-2640"></span><br />
No caso, os serviços estão todos baixados (Listener, Banco de Dados, Enterprise Manager).</p>
<p>Vamos acessar o diretório do produto Oracle e vamos realizar o Backup do mesmo.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle oraprd01]$ tar -zvcf backup_oracle_home.tar.gz app/
app/
app/oracle/
app/oracle/product/
.
.
.
app/oracle/scritps/backup/bkp_mensal.rcv
app/oracle/scritps/backup/bkp_manutencao_rman.sh
[oracle@serveroracle oraprd01]$ ls -l
total 646196
drwxrwxr-x 3 oracle dba           4096 Mar 29 11:10 app
-rw-r--r-- 1 oracle oinstall 661030969 Apr 17 16:03 backup_oracle_home.tar.gz
drwxrwxr-x 2 oracle dba          16384 Mar 13 15:17 lost+found
[oracle@serveroracle oraprd01]$
</pre>
<p>Vamos aplicar o Patch já descompactado no servidor.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle ~]$ /orabackup/Disk1/./runInstaller
Starting Oracle Universal Installer...

Checking installer requirements...

Checking operating system version: must be redhat-3, SuSE-9, SuSE-10, redhat-4, redhat-5, redhat-6, UnitedLinux-1.0, asianux-1, asianux-2, asianux-3, enterprise-4, enterprise-5 or SuSE-11
                                      Passed

All installer requirements met.

Preparing to launch Oracle Universal Installer from /tmp/OraInstall2012-04-17_04-04-29PM. Please wait ...[oracle@serveroracle ~]$ Oracle Universal Installer, Version 10.2.0.5.0 Production
Copyright (C) 1999, 2010, Oracle. All rights reserved.

[oracle@serveroracle ~]$
</pre>
<p>Seguir as imagens abaixo para a instalação passo à passo do Patch.</p>
<div id="attachment_2655" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/1.jpg"><img class="size-thumbnail wp-image-2655" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/1-150x150.jpg" alt="Tela Inicial de Instalação do Patch Set 10.2.0.5" width="150" height="150" /></a><p class="wp-caption-text">Tela Inicial de Instalação do Patch Set 10.2.0.5</p></div>
<div id="attachment_2658" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/2.jpg"><img class="size-thumbnail wp-image-2658" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/2-150x150.jpg" alt="Instalar no atual Oracle Home." width="150" height="150" /></a><p class="wp-caption-text">Instalar no atual Oracle Home.</p></div>
<div id="attachment_2666" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/3.jpg"><img class="size-thumbnail wp-image-2666" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/3-150x150.jpg" alt="Tela de Credenciais para o Suporte Oracle" width="150" height="150" /></a><p class="wp-caption-text">Tela de Credenciais para o Suporte Oracle</p></div>
<div id="attachment_2668" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/4.jpg"><img class="size-thumbnail wp-image-2668" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/4-150x150.jpg" alt="Tela de Aviso das Credenciais do Suporte da Oracle" width="150" height="150" /></a><p class="wp-caption-text">Tela de Aviso das Credenciais do Suporte da Oracle</p></div>
<div id="attachment_2669" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/5.jpg"><img class="size-thumbnail wp-image-2669" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/5-150x150.jpg" alt="Tela de checagem dos Pré-Requisitos para a Instalação do Patch Set." width="150" height="150" /></a><p class="wp-caption-text">Tela de checagem dos Pré-Requisitos para a Instalação do Patch Set.</p></div>
<div id="attachment_2671" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/8.jpg"><img class="size-thumbnail wp-image-2671" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/8-150x150.jpg" alt="Tela do Sumário do Patch a ser Instalado." width="150" height="150" /></a><p class="wp-caption-text">Tela do Sumário do Patch a ser Instalado.</p></div>
<div id="attachment_2675" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/9.jpg"><img class="size-thumbnail wp-image-2675" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/9-150x150.jpg" alt="Tela de Progresso de Instalação do Patch" width="150" height="150" /></a><p class="wp-caption-text">Tela de Progresso de Instalação do Patch</p></div>
<div id="attachment_2676" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/10.jpg"><img class="size-thumbnail wp-image-2676" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/10-150x150.jpg" alt="Tela para rodar o Script para permissão do usuário &quot;root&quot;. Copie o endereço e coloque num terminal com o usuário &quot;root&quot;." width="150" height="150" /></a><p class="wp-caption-text">Tela para rodar o Script para permissão do usuário &quot;root&quot;. Copie o endereço e coloque num terminal com o usuário &quot;root&quot;.</p></div>
<p>Com o usuário root, vamos executar o script da imagem acima.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle ~]$ su -
Password:
[root@serveroracle ~]# /oraprd01/app/oracle/product/10.2.0/db_1/root.sh
Running Oracle 10g root.sh script...

The following environment variables are set as:
    ORACLE_OWNER= oracle
    ORACLE_HOME=  /oraprd01/app/oracle/product/10.2.0/db_1

Enter the full pathname of the local bin directory: [/usr/local/bin]:
The file &quot;dbhome&quot; already exists in /usr/local/bin.  Overwrite it? (y/n)
[n]: y
   Copying dbhome to /usr/local/bin ...
The file &quot;oraenv&quot; already exists in /usr/local/bin.  Overwrite it? (y/n)
[n]: y
   Copying oraenv to /usr/local/bin ...
The file &quot;coraenv&quot; already exists in /usr/local/bin.  Overwrite it? (y/n)
[n]: y
   Copying coraenv to /usr/local/bin ...

Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root.sh script.
Now product-specific root actions will be performed.
[root@serveroracle ~]# exit
logout
[oracle@serveroracle ~]$
</pre>
<div id="attachment_2677" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/11.jpg"><img class="size-thumbnail wp-image-2677" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/11-150x150.jpg" alt="Tela de finalização a instalação do Patch. Clique em  Exit." width="150" height="150" /></a><p class="wp-caption-text">Tela de finalização a instalação do Patch. Clique em Exit.</p></div>
<div id="attachment_2679" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/12.jpg"><img class="size-thumbnail wp-image-2679" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/12-150x150.jpg" alt="Tela de finalização de instalação do Patch." width="150" height="150" /></a><p class="wp-caption-text">Tela de finalização de instalação do Patch.</p></div>
<p>Após executar o script da permissão do usuário &#8220;root&#8221;, com o usuário oracle, vamos iniciar os serviços do Banco de Dados Oracle.<br />
OBS: Seguir o README.html do Patch para aplicar o mesmo.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle ~]$ lsnrctl start

LSNRCTL for Linux: Version 10.2.0.5.0 - Production on 17-APR-2012 16:14:02

Copyright (c) 1991, 2010, Oracle.  All rights reserved.

Starting /oraprd01/app/oracle/product/10.2.0/db_1/bin/tnslsnr: please wait...

TNSLSNR for Linux: Version 10.2.0.5.0 - Production
System parameter file is /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
Log messages written to /oraprd01/app/oracle/product/10.2.0/db_1/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=serveroracle.localdomain)(PORT=1521)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=serveroracle.localdomain)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 10.2.0.5.0 - Production
Start Date                17-APR-2012 16:14:02
Uptime                    0 days 0 hr. 0 min. 0 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
Listener Log File         /oraprd01/app/oracle/product/10.2.0/db_1/network/log/listener.log
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=serveroracle.localdomain)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))
Services Summary...
Service &quot;PLSExtProc&quot; has 1 instance(s).
  Instance &quot;PLSExtProc&quot;, status UNKNOWN, has 1 handler(s) for this service...
Service &quot;orcl&quot; has 1 instance(s).
  Instance &quot;orcl&quot;, status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully
[oracle@serveroracle ~]$ sqlplus sys/*********** as sysdba

SQL*Plus: Release 10.2.0.5.0 - Production on Tue Apr 17 16:16:09 2012

Copyright (c) 1982, 2010, Oracle.  All Rights Reserved.

Connected to an idle instance.

SQL&gt; startup upgrade
ORACLE instance started.

Total System Global Area 1073741824 bytes
Fixed Size                  1277796 bytes
Variable Size             390070428 bytes
Database Buffers          679477248 bytes
Redo Buffers                2916352 bytes
Database mounted.
Database opened.
SQL&gt;
</pre>
<p>Seguindo o documento do Patch, vamos aplicar o mesmo executando o primeiro script &#8220;utlu102i.sql&#8221; (Descreve a informação da Atualização).<br />
OBS: Seguindo o Documento o mesmo solicita executar um spool para verificação após executar o script mencionado.</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; SPOOL upgrade_info.log
SQL&gt; @$ORACLE_HOME/rdbms/admin/utlu102i.sql
Oracle Database 10.2 Upgrade Information Utility    04-17-2012 16:17:23
.
**********************************************************************
Database:
**********************************************************************
--&gt; name:       ORCL
--&gt; version:    10.2.0.1.0
--&gt; compatible: 10.2.0.1.0
--&gt; blocksize:  8192
.
**********************************************************************
Tablespaces: [make adjustments in the current environment]
**********************************************************************
--&gt; SYSTEM tablespace is adequate for the upgrade.
.... minimum required size: 448 MB
.... AUTOEXTEND additional space required: 8 MB
--&gt; UNDOTBS1 tablespace is adequate for the upgrade.
.... minimum required size: 402 MB
.... AUTOEXTEND additional space required: 102 MB
--&gt; SYSAUX tablespace is adequate for the upgrade.
.... minimum required size: 206 MB
.... AUTOEXTEND additional space required: 6 MB
--&gt; TEMP tablespace is adequate for the upgrade.
.... minimum required size: 58 MB
.... AUTOEXTEND additional space required: 38 MB
.
**********************************************************************
Update Parameters: [Update Oracle Database 10.2 init.ora or spfile]
**********************************************************************
-- No update parameter changes are required.
.
**********************************************************************
Renamed Parameters: [Update Oracle Database 10.2 init.ora or spfile]
**********************************************************************
-- No renamed parameters found. No changes are required.
.
**********************************************************************
Obsolete/Deprecated Parameters: [Update Oracle Database 10.2 init.ora or spfile]
**********************************************************************
-- No obsolete parameters found. No changes are required
.
**********************************************************************
Components: [The following database components will be upgraded or installed]
**********************************************************************
--&gt; Oracle Catalog Views         [upgrade]  VALID
--&gt; Oracle Packages and Types    [upgrade]  VALID
--&gt; JServer JAVA Virtual Machine [upgrade]  VALID
--&gt; Oracle XDK for Java          [upgrade]  VALID
--&gt; Oracle Java Packages         [upgrade]  VALID
--&gt; Oracle XML Database          [upgrade]  VALID
--&gt; Oracle Workspace Manager     [upgrade]  VALID
--&gt; Oracle interMedia            [upgrade]  VALID
--&gt; Expression Filter            [upgrade]  VALID
--&gt; EM Repository                [upgrade]  VALID
--&gt; Rule Manager                 [upgrade]  VALID
.

PL/SQL procedure successfully completed.

SQL&gt; SPOOL OFF
</pre>
<p>Vamos executar o script &#8220;catupgrd.sql&#8221; para aplicar o Patch no Banco de Dados (Dicionário de Dados).</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; SPOOL patch.log
SQL&gt; @?/rdbms/admin/catupgrd.sql
DOC&gt;######################################################################
DOC&gt;######################################################################
DOC&gt;    The following statement will cause an &quot;ORA-01722: invalid number&quot;
DOC&gt;    error if the user running this script is not SYS.  Disconnect
DOC&gt;    and reconnect with AS SYSDBA.
DOC&gt;######################################################################
DOC&gt;######################################################################
DOC&gt;#

no rows selected

DOC&gt;######################################################################
DOC&gt;######################################################################
DOC&gt;    The following statement will cause an &quot;ORA-01722: invalid number&quot;
DOC&gt;    error if the database server version is not correct for this script.
DOC&gt;    Shutdown ABORT and use a different script or a different server.
DOC&gt;######################################################################
DOC&gt;######################################################################
DOC&gt;#

no rows selected

.
.
.

Total Upgrade Time: 00:18:38
DOC&gt;#######################################################################
DOC&gt;#######################################################################
DOC&gt;
DOC&gt;   The above PL/SQL lists the SERVER components in the upgraded
DOC&gt;   database, along with their current version and status.
DOC&gt;
DOC&gt;   Please review the status and version columns and look for
DOC&gt;   any errors in the spool log file.  If there are errors in the spool
DOC&gt;   file, or any components are not VALID or not the current version,
DOC&gt;   consult the Oracle Database Upgrade Guide for troubleshooting
DOC&gt;   recommendations.
DOC&gt;
DOC&gt;   Next shutdown immediate, restart for normal operation, and then
DOC&gt;   run utlrp.sql to recompile any invalid application objects.
DOC&gt;
DOC&gt;#######################################################################
DOC&gt;#######################################################################
DOC&gt;#
SQL&gt;
SQL&gt; spool off
</pre>
<p>Após a execução do script &#8220;catupgrd.sql&#8221;, vamos reiniciar o Banco de Dados.</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL&gt; startup
ORACLE instance started.

Total System Global Area 1073741824 bytes
Fixed Size                  1277796 bytes
Variable Size             415236252 bytes
Database Buffers          654311424 bytes
Redo Buffers                2916352 bytes
Database mounted.
Database opened.
SQL&gt;
</pre>
<p>Vamos executar o script &#8220;utlrp.sql&#8221; e recompilar os possíveis objetos inválidos pós aplicação do Patch no Dicionário de Dados.</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; @?/rdbms/admin/utlrp.sql

TIMESTAMP
--------------------------------------------------------------------------------
COMP_TIMESTAMP UTLRP_BGN  2012-04-17 16:40:48
DOC&gt;   The following PL/SQL block invokes UTL_RECOMP to recompile invalid
DOC&gt;   objects in the database. Recompilation time is proportional to the
DOC&gt;   number of invalid objects in the database, so this command may take
DOC&gt;   a long time to execute on a database with a large number of invalid
DOC&gt;   objects.
DOC&gt;
DOC&gt;   Use the following queries to track recompilation progress:
DOC&gt;
DOC&gt;   1. Query returning the number of invalid objects remaining. This
DOC&gt;      number should decrease with time.
DOC&gt;         SELECT COUNT(*) FROM obj$ WHERE status IN (4, 5, 6);
DOC&gt;
DOC&gt;   2. Query returning the number of objects compiled so far. This number
DOC&gt;      should increase with time.
DOC&gt;         SELECT COUNT(*) FROM UTL_RECOMP_COMPILED;
DOC&gt;
DOC&gt;   This script automatically chooses serial or parallel recompilation
DOC&gt;   based on the number of CPUs available (parameter cpu_count) multiplied
DOC&gt;   by the number of threads per CPU (parameter parallel_threads_per_cpu).
DOC&gt;   On RAC, this number is added across all RAC nodes.
DOC&gt;
DOC&gt;   UTL_RECOMP uses DBMS_SCHEDULER to create jobs for parallel
DOC&gt;   recompilation. Jobs are created without instance affinity so that they
DOC&gt;   can migrate across RAC nodes. Use the following queries to verify
DOC&gt;   whether UTL_RECOMP jobs are being created and run correctly:
DOC&gt;
DOC&gt;   1. Query showing jobs created by UTL_RECOMP
DOC&gt;         SELECT job_name FROM dba_scheduler_jobs
DOC&gt;            WHERE job_name like 'UTL_RECOMP_SLAVE_%';
DOC&gt;
DOC&gt;   2. Query showing UTL_RECOMP jobs that are running
DOC&gt;         SELECT job_name FROM dba_scheduler_running_jobs
DOC&gt;            WHERE job_name like 'UTL_RECOMP_SLAVE_%';
DOC&gt;#

TIMESTAMP
--------------------------------------------------------------------------------
COMP_TIMESTAMP UTLRP_END  2012-04-17 16:41:33
DOC&gt; The following query reports the number of objects that have compiled
DOC&gt; with errors (objects that compile with errors have status set to 3 in
DOC&gt; obj$). If the number is higher than expected, please examine the error
DOC&gt; messages reported with each object (using SHOW ERRORS) to see if they
DOC&gt; point to system misconfiguration or resource constraints that must be
DOC&gt; fixed before attempting to recompile these objects.
DOC&gt;#

OBJECTS WITH ERRORS
-------------------
                  0
DOC&gt; The following query reports the number of errors caught during
DOC&gt; recompilation. If this number is non-zero, please query the error
DOC&gt; messages in the table UTL_RECOMP_ERRORS to see if any of these errors
DOC&gt; are due to misconfiguration or resource constraints that must be
DOC&gt; fixed before objects can compile successfully.
DOC&gt;#

ERRORS DURING RECOMPILATION
---------------------------
                          0
SQL&gt;
</pre>
<p>Vamos verificar o registro após aplicação do Patch Set 10.2.0.5.</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; col COMP_NAME for a35
SQL&gt; select VERSION, STATUS, MODIFIED, STARTUP, COMP_NAME from dba_registry;

VERSION                        STATUS      MODIFIED             STARTUP  COMP_NAME
------------------------------ ----------- -------------------- -------- -----------------------------------
10.2.0.5.0                     VALID       17-APR-2012 16:35:28          Oracle Enterprise Manager
10.2.0.5.0                     VALID       17-APR-2012 16:41:35          Oracle interMedia
10.2.0.5.0                     VALID       17-APR-2012 16:41:34          Oracle XML Database
10.2.0.5.0                     VALID       17-APR-2012 16:41:34          Oracle Expression Filter
10.2.0.5.0                     VALID       17-APR-2012 16:41:35          Oracle Rule Manager
10.2.0.5.0                     VALID       17-APR-2012 16:41:33          Oracle Workspace Manager
10.2.0.5.0                     VALID       17-APR-2012 16:41:33          Oracle Database Catalog Views
10.2.0.5.0                     VALID       17-APR-2012 16:41:33          Oracle Database Packages and Types
10.2.0.5.0                     VALID       17-APR-2012 16:41:34          JServer JAVA Virtual Machine
10.2.0.5.0                     VALID       17-APR-2012 16:41:34          Oracle XDK
10.2.0.5.0                     VALID       17-APR-2012 16:41:34          Oracle Database Java Packages
SQL&gt; !
</pre>
<p>Vamos inciar o Enterprise Manager.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle ~]$ emctl start dbconsole
TZ set to Brazil/East
Oracle Enterprise Manager 10g Database Control Release 10.2.0.5.0
Copyright (c) 1996, 2010 Oracle Corporation.  All rights reserved.

http://serveroracle.localdomain:1158/em/console/aboutApplication

Starting Oracle Enterprise Manager 10g Database Control .......................... started.
------------------------------------------------------------------
Logs are generated in directory /oraprd01/app/oracle/product/10.2.0/db_1/serveroracle.localdomain_orcl/sysman/log
[oracle@serveroracle ~]$ emctl status agent
TZ set to Brazil/East
Oracle Enterprise Manager 10g Database Control Release 10.2.0.5.0
Copyright (c) 1996, 2010 Oracle Corporation.  All rights reserved.
---------------------------------------------------------------
Agent Version     : 10.1.0.6.0
OMS Version       : 10.1.0.6.0
Protocol Version  : 10.1.0.2.0
Agent Home        : /oraprd01/app/oracle/product/10.2.0/db_1/serveroracle.localdomain_orcl
Agent binaries    : /oraprd01/app/oracle/product/10.2.0/db_1
Agent Process ID  : 11833
Parent Process ID : 9626
Agent URL         : http://serveroracle.localdomain:3938/emd/main
Started at        : 2012-04-17 16:51:04
Started by user   : oracle
Last Reload       : 2012-04-17 16:51:04
Last successful upload                       : (none)
Last attempted upload                        : (none)
Total Megabytes of XML files uploaded so far :     0.00
Number of XML files pending upload           :       16
Size of XML files pending upload(MB)         :     4.40
Available disk space on upload filesystem    :    71.39%
---------------------------------------------------------------
Agent is Running and Ready
[oracle@serveroracle ~]$
</pre>
<div id="attachment_2682" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/13.jpg"><img class="size-thumbnail wp-image-2682" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/13-150x150.jpg" alt="Tela do Enterprise Manager após aplicar o Patch" width="150" height="150" /></a><p class="wp-caption-text">Tela do Enterprise Manager após aplicar o Patch</p></div>
<p>Como podemos perceber na imagem acima, o Enterprise Manager está mostrando o Banco de Dados 10.2.0.1.<br />
Para ajuste deste, devemos reconfigurar o Enterprise Manager (dbconsole).<br />
Vamos baixar o serviço do Enterpise Manager e reconfigurar o mesmo.<br />
Para reconfigurar o Enterprise Manager acesse o artigo do Anderson Graf <a href="http://www.oraclehome.com.br/2011/09/06/recriando-repositorio-do-oracle-enterprise-manager/" target="_blank">Recriando repositório do Oracle Enterprise Manager</a>.</p>
<p>Vamos seguir o artigo acima.<br />
A configuração pode não ser completada, pois ao subir o serviço do Enterprise Manager o mesmo pode ocorrer um erro de certificado SSL.<br />
Caso haja erro ao recriar o repositório do Enterprise Manager, verifique o status do serviço do mesmo conforme abaixo.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle ~]$ emctl status dbconsole
TZ set to Brazil/East
Oracle Enterprise Manager 10g Database Control Release 10.2.0.5.0
Copyright (c) 1996, 2010 Oracle Corporation.  All rights reserved.

https://serveroracle.localdomain:1158/em/console/aboutApplication

Oracle Enterprise Manager 10g is not running.
------------------------------------------------------------------
Logs are generated in directory /oraprd01/app/oracle/product/10.2.0/db_1/serveroracle.localdomain_orcl/sysman/log
[oracle@serveroracle ~]$ emctl status agent
TZ set to Brazil/East
Oracle Enterprise Manager 10g Database Control Release 10.2.0.5.0
Copyright (c) 1996, 2010 Oracle Corporation.  All rights reserved.
---------------------------------------------------------------
Agent is Not Running
[oracle@serveroracle ~]$
</pre>
<p>Para solicionar este, devemos aplicar o Patch 8350262 para o Enterpise Manager.<br />
Para aplicar o mesmo, vamos seguir o artigo <a href="http://www.oraclehome.com.br/2011/09/23/aplicacao-do-patch-8350262-para-correcao-do-enterprise-manager/" target="_blank">Aplicação do Patch 8350262 para Correção do Enterprise Manager.</a>.<br />
Seguindo o artigo acima, vamos aplicar o Patch para o Enterprise Manager.</p>
<p>Após aplicado o Patch 8350262 para o Enterprise Manager, vamos verificar o status do serviço do mesmo.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 8350262]$ emctl status dbconsole
TZ set to Brazil/East
Oracle Enterprise Manager 10g Database Control Release 10.2.0.5.0
Copyright (c) 1996, 2010 Oracle Corporation.  All rights reserved.

https://serveroracle.localdomain:1158/em/console/aboutApplication

Oracle Enterprise Manager 10g is running.
------------------------------------------------------------------
Logs are generated in directory /oraprd01/app/oracle/product/10.2.0/db_1/serveroracle.localdomain_orcl/sysman/log
[oracle@serveroracle 8350262]$ emctl status agent
TZ set to Brazil/East
Oracle Enterprise Manager 10g Database Control Release 10.2.0.5.0
Copyright (c) 1996, 2010 Oracle Corporation.  All rights reserved.
---------------------------------------------------------------
Agent Version     : 10.1.0.6.0
OMS Version       : 10.1.0.6.0
Protocol Version  : 10.1.0.2.0
Agent Home        : /oraprd01/app/oracle/product/10.2.0/db_1/serveroracle.localdomain_orcl
Agent binaries    : /oraprd01/app/oracle/product/10.2.0/db_1
Agent Process ID  : 31928
Parent Process ID : 29766
Agent URL         : https://serveroracle.localdomain:3938/emd/main
Started at        : 2012-04-17 17:30:02
Started by user   : oracle
Last Reload       : 2012-04-17 17:30:02
Last successful upload                       : 2012-04-17 17:30:36
Total Megabytes of XML files uploaded so far :     4.00
Number of XML files pending upload           :        0
Size of XML files pending upload(MB)         :     0.00
Available disk space on upload filesystem    :    71.29%
---------------------------------------------------------------
Agent is Running and Ready
[oracle@serveroracle 8350262]$
</pre>
<div id="attachment_2683" class="wp-caption alignnone" style="width: 160px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/04/14.jpg"><img class="size-thumbnail wp-image-2683" src="http://www.oraclehome.com.br/wp-content/uploads/2012/04/14-150x150.jpg" alt="Tela do Enterprise Manager após aplicado Patch para o mesmo e recriado o repositório do mesmo" width="150" height="150" /></a><p class="wp-caption-text">Tela do Enterprise Manager após aplicado Patch para o mesmo e recriado o repositório do mesmo</p></div>
<p>Pronto aplicamos o Patch Set 10.2.0.5 (8202632) no Banco de Dados 10.2.0.1.<br />
Mais informações sobre o Patch Set acessar o <a href="https://support.oracle.com" target="_blank">Suporte da Oracle</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/05/14/aplicando-patch-set-10-2-0-5-8202632-no-banco-de-dados-oracle-10-2-0-1-non-rac/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Execução paralela de instruções SQL: Parallel Query, DML e DDL</title>
		<link>http://www.oraclehome.com.br/2012/05/07/execucao-paralela-de-instrucoes-sql-parallel-query-dml-e-ddl/</link>
		<comments>http://www.oraclehome.com.br/2012/05/07/execucao-paralela-de-instrucoes-sql-parallel-query-dml-e-ddl/#comments</comments>
		<pubDate>Mon, 07 May 2012 12:28:45 +0000</pubDate>
		<dc:creator>Anderson Graf</dc:creator>
				<category><![CDATA[Alta disponibilidade]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Performance]]></category>
		<category><![CDATA[alter index]]></category>
		<category><![CDATA[alter table]]></category>
		<category><![CDATA[create index]]></category>
		<category><![CDATA[create table]]></category>
		<category><![CDATA[ddl]]></category>
		<category><![CDATA[degree]]></category>
		<category><![CDATA[dml]]></category>
		<category><![CDATA[explain]]></category>
		<category><![CDATA[hint]]></category>
		<category><![CDATA[noparallel]]></category>
		<category><![CDATA[paralelismo]]></category>
		<category><![CDATA[parallel]]></category>
		<category><![CDATA[parameter]]></category>
		<category><![CDATA[PQO]]></category>
		<category><![CDATA[query]]></category>
		<category><![CDATA[sql]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2567</guid>
		<description><![CDATA[Varias vezes encontramos consultas, processos ou atualizações em massa provocando um alto índice de custos para o ambiente de banco de dados, apesar de varias otimizações serem aplicadas o custo ainda é extremamente alto o que acaba prejudicando varios processos e rotinas. Então.. o que podemos fazer para diminuir este impacto? Já pensou em paralelismo? [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">Varias vezes encontramos consultas, processos ou atualizações em massa provocando um alto índice de custos para o ambiente de banco de dados, apesar de varias otimizações serem aplicadas o custo ainda é extremamente alto o que acaba prejudicando varios processos e rotinas.</p>
<p style="text-align: justify;">Então.. o que podemos fazer para diminuir este impacto?</p>
<p style="text-align: justify;">Já pensou em paralelismo?</p>
<p style="text-align: justify;">O Paralelismo, disponibilizado na versão enterprise do Oracle database, oferece a ideia de se quebrar uma tarefa em partes para que, em vez de um único processo fazer todo o trabalho, muitos processos possam executar simultâniamente as partes e no final apresentar um resultado único em menos tempo do que o executado por um único processo.</p>
<p style="text-align: justify;"><span id="more-2567"></span><br />
A execução paralela proporcina melhorias no desempenho mediante a utilização otimizada dos recursos de hardware do servidor, ou seja, podemos utilizar todas as CPUs de um servidor em uma única atividade o que proporcionaria um ganho significativo no processo, por exemplo. Esta mesma distribuição pode ser realizada em um ambiente clusterizado(RAC), onde podemos utilizar, se necessário, os recursos de todos os nodes para uma única tarefa/processo.</p>
<p style="text-align: justify;">Contudo, quando implementado, devemos sempre ficar atentos ao consumo dos recursos do servidor como CPU, memória e discos, pois o paralelismo pode saturar completamente uma máquina, ficando então a cargo do DBA equilibrar cuidadosamente o número de pessoas que executam operações paralelas quanto o grau do paralelismo utilizado para que os recursos do servidor não sejam esgotados.</p>
<p style="text-align: justify;">Para a divisão e execução simultânia das varias partes de uma tarefa, o Oracle cria uma sessão &#8220;coordenador&#8221; que gerencia os processos escravos responsáveis pelas execuções paralelas e que ao termino recebe de cada escravo os resultados e reproduz uma saida combinada de forma a obtermos o mesmo resultado do que uma execução em serie, porem com o diferencial deste processo paralelo ter concluido muito mais rapidamente.</p>
<p style="text-align: justify;">O paralelismo pode ser especificado em 3 (três) diferentes níveis:</p>
<p><strong>Nível de instrução:</strong></p>
<p>Utilizando hints</p>
<p><strong>Nível de objeto:</strong></p>
<p>Especificando o grau de paralelismo na definição do objeto, tabela ou indice.</p>
<p><strong>Nível de instance:</strong></p>
<p>Ajustando as parâmetrizações da instance. (<span style="color: #ff0000;"><em>show parameter parallel</em></span>)</p>
<p style="text-align: justify;">Visto um básico histórico do funcionamento do paralelismo, vamos agora aprender sobre 3 tipos de paralelismo que são: Parallel Query, DML e DDL</p>
<p><span style="color: #ff0000;"><strong>Parallel Query:</strong></span></p>
<p style="text-align: justify;">O paralelismo de queries, também conhecida como PQO (Parallel Query Option), foi a primeira feature de execução paralela desenvolvida pela Oracle e disponibilizada já na versão 7.1 do Oracle database, sendo que hoje é a feature de paralelismo mais utilizada no SGBD Oracle.</p>
<p style="text-align: justify;">Seu principal objetivo é reduzir o tempo de execução de grandes consultas, porém antes de implementá-lo definitivamente devemos testar todas as consultas para garantir que elas vão se beneficiar do paralelismo.</p>
<p style="text-align: justify;">Para habilitar ou desabilitar o paralelismo podemos alterar uma tabela ou indice informando o grau de paralelismo ou atraves da utilização de hints conforme exemplos abaixo:</p>
<p style="text-align: justify;"><em>Para habilitar/utilizar o paralelismo:</em></p>
<div style="text-align: justify;">-&gt; Nível de objeto</div>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; alter table teste1 parallel (degree 4);

Table altered.

SQL&gt; alter table teste1 parallel 4;

Table altered.
</pre>
<p>-&gt; Nível de instrução:</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; select /*+ PARALLEL(teste1,4,1) */ count(*) from teste1;

  COUNT(*)
----------
   1250000
</pre>
<p style="text-align: justify;">Sintaxe:</p>
<p style="text-align: justify;"><span style="color: #3366ff;">select /*+ PARALLEL(table_alias, degree, nodes) */ * from table_name</span></p>
<p style="text-align: justify;"><em>Para visualizar o paralelismo configurado sobre a tabela/indice:</em></p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; select degree from user_tables where table_name='TESTE1';

DEGREE
----------
         4
</pre>
<p><em>Para desabilitar o paralelismo:</em></p>
<p>-&gt; Nível de objeto</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; alter table teste1 NOPARALLEL;

Table altered.

SQL&gt; select degree from user_tables where table_name='TESTE1';

DEGREE
----------
         1
</pre>
<p>-&gt; Nível de instrução:</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; select /*+ NOPARALLEL(teste1) */ count(*) from teste1;

  COUNT(*)
----------
   1250000
</pre>
<p style="text-align: justify;">Vamos realizar agora um explain da query para verificar como fica sem e com paralelismo:</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; explain plan for
  2  select count(*) from teste1
  3  /

Explained.

SQL&gt; SELECT * FROM TABLE(dbms_xplan.display);

PLAN_TABLE_OUTPUT
---------------------------------------------------------------------
Plan hash value: 3242138447

---------------------------------------------------------------------
| Id  | Operation          | Name   | Rows  | Cost (%CPU)| Time     |
---------------------------------------------------------------------
|   0 | SELECT STATEMENT   |        |     1 |   553   (2)| 00:00:07 |
|   1 |  SORT AGGREGATE    |        |     1 |            |          |
|   2 |   TABLE ACCESS FULL| TESTE1 |  1598K|   553   (2)| 00:00:07 |
---------------------------------------------------------------------

SQL&gt; explain plan for
  2  select /*+ PARALLEL(teste1,4,1) */ count(*) from teste1
  3  /

Explained.

SQL&gt; SELECT * FROM TABLE(dbms_xplan.display);

PLAN_TABLE_OUTPUT
--------------------------------------------------------------------------------------------------------
Plan hash value: 721361025

--------------------------------------------------------------------------------------------------------
| Id  | Operation              | Name     | Rows  | Cost (%CPU)| Time     |    TQ  |IN-OUT| PQ Distrib |
--------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT       |          |     1 |   153   (2)| 00:00:02 |        |      |            |
|   1 |  SORT AGGREGATE        |          |     1 |            |          |        |      |            |
|   2 |   PX COORDINATOR       |          |       |            |          |        |      |            |
|   3 |    PX SEND QC (RANDOM) | :TQ10000 |     1 |            |          |  Q1,00 | P-&gt;S | QC (RAND)  |
|   4 |     SORT AGGREGATE     |          |     1 |            |          |  Q1,00 | PCWP |            |
|   5 |      PX BLOCK ITERATOR |          |  1598K|   153   (2)| 00:00:02 |  Q1,00 | PCWC |            |
|   6 |       TABLE ACCESS FULL| TESTE1   |  1598K|   153   (2)| 00:00:02 |  Q1,00 | PCWP |            |
--------------------------------------------------------------------------------------------------------
</pre>
<p>Note que quando executado uma instrução em paralelo temos como evidência as operações PX.</p>
<p><span style="color: #ff0000;"><strong>Parallel DML:</strong></span></p>
<p style="text-align: justify;">As operações de DML (Data Manipulation Language) INSERT, UPDATE e DELETE também podem ser paralizadas e proporcionar grandes ganhos em tempo/custo, contudo quando a paralelização de DML é acionada o Oracle verifica algumas &#8220;regras&#8221;/restrições para apontar se a paralelização é válida ou não.</p>
<p style="text-align: justify;">Abaixo podemos ver as regras aplicadas, NOTE que UPDATE e DELETE possuem o mesmo escopo de verificação.</p>
<p><em>Para UPDATE e DELETE:</em></p>
<p>- A paralelização pode ocorrer em tabelas particionadas, mas somente quando várias partições estão envolvidos;</p>
<p>- Não pode ser paralizado o UPDATE e DELETE em uma tabela não particionada ou quando as operações afetam apenas uma única partição.</p>
<p><em>Para operações de INSERT:</em></p>
<p>- O INSERT padrão utilizando a cláusula VALUES não pode ser paralelizado, apenas pode ser paralelizado as declarações INSERT&#8230;SELECT.</p>
<p><em>Vamos demonstrar um exemplo com e sem paralelismo:</em></p>
<p>-&gt; INSERT&#8230;SELECT sem paralelismo:</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; set autotrace traceonly explain;
SQL&gt; insert into teste1 select * from teste1;

1250000 rows created.

Execution Plan
----------------------------------------------------------
Plan hash value: 110554063

-----------------------------------------------------------------------------------
| Id  | Operation                | Name   | Rows  | Bytes | Cost (%CPU)| Time     |
-----------------------------------------------------------------------------------
|   0 | INSERT STATEMENT         |        |  1250K|  4882K|   551   (2)| 00:00:07 |
|   1 |  LOAD TABLE CONVENTIONAL | TESTE1 |       |       |            |          |
|   2 |   TABLE ACCESS FULL      | TESTE1 |  1250K|  4882K|   551   (2)| 00:00:07 |
-----------------------------------------------------------------------------------
</pre>
<p>-&gt; INSERT&#8230;SELECT com paralelismo:</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; alter session enable parallel dml;

Session altered.

SQL&gt; explain plan for
  2  insert /*+ parallel (teste1,4,1) */ into teste1 select * from teste1;

Explained.

SQL&gt; SELECT * FROM TABLE(dbms_xplan.display);

Execution Plan
----------------------------------------------------------
Plan hash value: 1222195891

-----------------------------------------------------------------------------------------------------------------
| Id  | Operation               | Name     | Rows  | Bytes | Cost (%CPU)| Time     |    TQ  |IN-OUT| PQ Distrib |
-----------------------------------------------------------------------------------------------------------------
|   0 | INSERT STATEMENT        |          |  1250K|  4882K|    29   (2)| 00:00:02 |        |      |            |
|   1 |  PX COORDINATOR         |          |       |       |            |          |        |      |            |
|   2 |   PX SEND QC (RANDOM)   | :TQ10001 |  1250K|  4882K|    29   (2)| 00:00:02 |  Q1,01 | P-&gt;S | QC (RAND)  |
|   3 |    LOAD AS SELECT       | TESTE1   |       |       |            |          |  Q1,01 | PCWP |            |
|   4 |     PX RECEIVE          |          |  1250K|  4882K|    29   (2)| 00:00:02 |  Q1,01 | PCWP |            |
|   5 |      PX SEND ROUND-ROBIN| :TQ10000 |  1250K|  4882K|    29   (2)| 00:00:02 |        | S-&gt;P | RND-ROBIN  |
|   6 |       TABLE ACCESS FULL | TESTE1   |  1250K|  4882K|    29   (2)| 00:00:02 |        |      |            |
-----------------------------------------------------------------------------------------------------------------

13 rows selected.

SQL&gt; commit;

Commit complete.

SQL&gt; alter session disable parallel dml;

Session altered.
</pre>
<p><span style="color: #ff0000;"><strong>Parallel DDL:</strong></span></p>
<p><span style="color: #000000;">O paralelismo em instruções DDL se aplicam a tabelas e indices, particionadas ou não.</span></p>
<p><em><span style="color: #000000;">-&gt; Para tabelas:</span></em></p>
<p>CREATE TABLE&#8230;AS SELECT</p>
<p>ALTER INDEX&#8230;REBUILD PARTITION</p>
<p>ALTER INDEX&#8230;SPLIT PARTITION</p>
<p><em>-&gt; Para indices:</em></p>
<p>CREATE INDEX</p>
<p>ALTER INDEX&#8230;REBUILD</p>
<p>ALTER INDEX&#8230;REBUILD PARTITION</p>
<p>ALTER INDEX&#8230;SPLIT PARTITION</p>
<p><span style="color: #0000ff;">Lembrando que tabelas com objetos/campos com LOB não permitem paralelismo DDL.</span></p>
<p><em>Exemplos de paralelismo com DDL:</em></p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; explain plan for
  2  create table teste_parallel parallel (degree 4)  as select * from teste1;

Explained.

SQL&gt; SELECT * FROM TABLE(dbms_xplan.display);

PLAN_TABLE_OUTPUT
----------------------------------------------------------------------------------------------------------------------
Plan hash value: 3992983551

----------------------------------------------------------------------------------------------------------------------
| Id  | Operation              | Name           | Rows  | Bytes | Cost (%CPU)| Time     |    TQ  |IN-OUT| PQ Distrib |
----------------------------------------------------------------------------------------------------------------------
|   0 | CREATE TABLE STATEMENT |                |    10M|    38M|  2388   (1)| 00:00:29 |        |      |            |
|   1 |  PX COORDINATOR        |                |       |       |            |          |        |      |            |
|   2 |   PX SEND QC (RANDOM)  | :TQ10000       |    10M|    38M|  1476   (1)| 00:00:18 |  Q1,00 | P-&gt;S | QC (RAND)  |
|   3 |    LOAD AS SELECT      | TESTE_PARALLEL |       |       |            |          |  Q1,00 | PCWP |            |
|   4 |     PX BLOCK ITERATOR  |                |    10M|    38M|  1476   (1)| 00:00:18 |  Q1,00 | PCWC |            |
|   5 |      TABLE ACCESS FULL | TESTE1         |    10M|    38M|  1476   (1)| 00:00:18 |  Q1,00 | PCWP |            |
----------------------------------------------------------------------------------------------------------------------
</pre>
<p>Agora observe se criarmos a tabela sem Paralelismo:</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; explain plan for
  2  create table teste_parallel  as select * from teste1;

Explained.

SQL&gt; SELECT * FROM TABLE(dbms_xplan.display);

PLAN_TABLE_OUTPUT
-----------------------------------------------------------------------------------------
Plan hash value: 3174501407

-----------------------------------------------------------------------------------------
| Id  | Operation              | Name           | Rows  | Bytes | Cost (%CPU)| Time     |
-----------------------------------------------------------------------------------------
|   0 | CREATE TABLE STATEMENT |                |    10M|    38M|  8967   (1)| 00:01:48 |
|   1 |  LOAD AS SELECT        | TESTE_PARALLEL |       |       |            |          |
|   2 |   TABLE ACCESS FULL    | TESTE1         |    10M|    38M|  5320   (1)| 00:01:04 |
-----------------------------------------------------------------------------------------
</pre>
<p>Vamos ver um indice, com e sem paralelismo:</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; explain plan for
  2  create index teste_idx01 on teste1(CD_TESTE) parallel (degree 4);

Explained.

SQL&gt; SELECT * FROM TABLE(dbms_xplan.display);

PLAN_TABLE_OUTPUT
---------------------------------------------------------------------------------------------------------------------
Plan hash value: 1444741105

---------------------------------------------------------------------------------------------------------------------
| Id  | Operation                | Name        | Rows  | Bytes | Cost (%CPU)| Time     |    TQ  |IN-OUT| PQ Distrib |
---------------------------------------------------------------------------------------------------------------------
|   0 | CREATE INDEX STATEMENT   |             |    10M|    38M|  2858   (1)| 00:00:35 |        |      |            |
|   1 |  PX COORDINATOR          |             |       |       |            |          |        |      |            |
|   2 |   PX SEND QC (ORDER)     | :TQ10001    |    10M|    38M|            |          |  Q1,01 | P-&gt;S | QC (ORDER) |
|   3 |    INDEX BUILD NON UNIQUE| TESTE_IDX01 |       |       |            |          |  Q1,01 | PCWP |            |
|   4 |     SORT CREATE INDEX    |             |    10M|    38M|            |          |  Q1,01 | PCWP |            |
|   5 |      PX RECEIVE          |             |    10M|    38M|  1476   (1)| 00:00:18 |  Q1,01 | PCWP |            |
|   6 |       PX SEND RANGE      | :TQ10000    |    10M|    38M|  1476   (1)| 00:00:18 |  Q1,00 | P-&gt;P | RANGE      |
|   7 |        PX BLOCK ITERATOR |             |    10M|    38M|  1476   (1)| 00:00:18 |  Q1,00 | PCWC |            |
|   8 |         TABLE ACCESS FULL| TESTE1      |    10M|    38M|  1476   (1)| 00:00:18 |  Q1,00 | PCWP |            |
---------------------------------------------------------------------------------------------------------------------
</pre>
<p>Sem paralelismo:</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; explain plan for
  2  create index teste_idx01 on teste1(CD_TESTE);

Explained.

SQL&gt; SELECT * FROM TABLE(dbms_xplan.display);

PLAN_TABLE_OUTPUT
--------------------------------------------------------------------------------------
Plan hash value: 3409988532

--------------------------------------------------------------------------------------
| Id  | Operation              | Name        | Rows  | Bytes | Cost (%CPU)| Time     |
--------------------------------------------------------------------------------------
|   0 | CREATE INDEX STATEMENT |             |    10M|    38M| 10846   (1)| 00:02:11 |
|   1 |  INDEX BUILD NON UNIQUE| TESTE_IDX01 |       |       |            |          |
|   2 |   SORT CREATE INDEX    |             |    10M|    38M|            |          |
|   3 |    TABLE ACCESS FULL   | TESTE1      |    10M|    38M|  5320   (1)| 00:01:04 |
--------------------------------------------------------------------------------------
</pre>
<p><em>Referências:</em></p>
<pre><a href="http://docs.oracle.com/cd/B10501_01/server.920/a96524/c20paral.htm">http://docs.oracle.com/cd/B10501_01/server.920/a96524/c20paral.htm</a>
<a href="http://www.oracle.com/technetwork/issue-archive/2010/o40parallel-092275.html">http://www.oracle.com/technetwork/issue-archive/2010/o40parallel-092275.html</a>
<a href="http://www.akadia.com/services/ora_parallel_processing.html#Parallel%20Recovery">http://www.akadia.com/services/ora_parallel_processing.html#Parallel%20Recovery</a></pre>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/05/07/execucao-paralela-de-instrucoes-sql-parallel-query-dml-e-ddl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Falha ao tentar instalar Banco de Dados Oracle 10.2.0.1 em Oracle Linux 5.7</title>
		<link>http://www.oraclehome.com.br/2012/04/05/falha-ao-tentar-instalar-banco-de-dados-oracle-10-2-0-1-em-oracle-linux-5-7/</link>
		<comments>http://www.oraclehome.com.br/2012/04/05/falha-ao-tentar-instalar-banco-de-dados-oracle-10-2-0-1-em-oracle-linux-5-7/#comments</comments>
		<pubDate>Thu, 05 Apr 2012 12:00:48 +0000</pubDate>
		<dc:creator>Maycon Tomiasi</dc:creator>
				<category><![CDATA[Erros]]></category>
		<category><![CDATA[Instalação]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Oracle Linux]]></category>
		<category><![CDATA[10g]]></category>
		<category><![CDATA[banco]]></category>
		<category><![CDATA[banco de dados]]></category>
		<category><![CDATA[base]]></category>
		<category><![CDATA[Checking operating system version]]></category>
		<category><![CDATA[dados]]></category>
		<category><![CDATA[data]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[falha]]></category>
		<category><![CDATA[ignoreSysPrereqs]]></category>
		<category><![CDATA[instalação]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[metalink]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[oracle linux 5]]></category>
		<category><![CDATA[redhat-5]]></category>
		<category><![CDATA[runInstaller]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2569</guid>
		<description><![CDATA[Este artigo tem como objetivo explicar e solucionar a Falha durante a instalação do Banco de Dados 10g no Oracle Linux 5.7. Durante a instalação ocorreu o seguinte erro: &#8220;Checking operating system version: must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1 or asianux-2 Failed &#60;&#60;&#60;&#60;&#8221; Segue evidência abaixo: O erro ocorreu pois ao checar a versão [...]]]></description>
			<content:encoded><![CDATA[<p>Este artigo tem como objetivo explicar e solucionar a Falha durante a instalação do Banco de Dados 10g no Oracle Linux 5.7.</p>
<p>Durante a instalação ocorreu o seguinte erro:<br />
&#8220;Checking operating system version: must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1 or asianux-2<br />
Failed &lt;&lt;&lt;&lt;&#8221;</p>
<p><span id="more-2569"></span><br />
Segue evidência abaixo:</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle database]$ ./runInstaller
Starting Oracle Universal Installer...

Checking installer requirements...

Checking operating system version: must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1 or asianux-2
                                      Failed &lt;&lt;&lt;&lt;

Exiting Oracle Universal Installer, log for this session can be found at /tmp/OraInstall2012-03-29_11-17-22AM/installActions2012-03-29_11-17-22AM.log
[oracle@serveroracle database]$
</pre>
<p>O erro ocorreu pois ao checar a versão do Sistema Operacional o Oracle Linux 5 não passou pela certificação. Isso acontece pois o instalador do Oracle 10g é antigo, ou seja, novos instaladores são já certificados.<br />
Observando os sistemas operacionais na mensagem acima &#8220;must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1 or asianux-2&#8243; não tem o redhat-5.</p>
<p>Há duas maneiras de solucionar este problema:<br />
- Adicionando o &#8220;redhat-5&#8243; no arquivo &#8220;oraparam.ini&#8221;;<br />
- Utilizar o comando &#8220;./runInstaller -ignoreSysPrereqs&#8221;. Veja no Metalink: [ID 419646.1]</p>
<p>Vou utilizar a primeira opção. Vamos adicionar o &#8220;redhat-5&#8243; no arquivo de instalação do Oracle.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle database]$ ls -l
total 28
drwxr-xr-x 9 oracle oinstall 4096 Oct 29  2007 doc
drwxr-xr-x 5 oracle oinstall 4096 Mar 29 11:19 install
drwxr-xr-x 2 oracle oinstall 4096 Oct 29  2007 response
-rwxr-xr-x 1 oracle oinstall 1327 Jul  2  2005 runInstaller
drwxr-xr-x 9 oracle oinstall 4096 Oct 29  2007 stage
-rwxr-xr-x 1 oracle oinstall 5213 Jul  2  2005 welcome.html
[oracle@serveroracle database]$
</pre>
<p>Vamos acessar o diretório &#8220;install/&#8221;.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle database]$ cd install/
[oracle@serveroracle install]$ ls -l
total 180
-rwxr-xr-x 1 oracle oinstall     28 Jul  2  2005 addLangs.sh
-rwxr-xr-x 1 oracle oinstall     76 Jul  2  2005 addNode.sh
drwxr-xr-x 2 oracle oinstall   4096 Oct 29  2007 images
-rwxr-xr-x 1 oracle oinstall  35634 Jul  2  2005 lsnodes
-rwxr-xr-x 1 oracle oinstall   2268 Jul  2  2005 oneclick.properties
-rwxr-xr-x 1 oracle oinstall   2387 Jul  2  2005 oraparam.ini
-rwxr-xr-x 1 oracle oinstall   6428 Jul  2  2005 oraparamsilent.ini
drwxr-xr-x 2 oracle oinstall   4096 Oct 29  2007 resource
drwxr-xr-x 2 oracle oinstall   4096 Oct 29  2007 response
-rwxr-xr-x 1 oracle oinstall 102612 Jul  2  2005 unzip
[oracle@serveroracle install]$
</pre>
<p>No arquivo &#8220;oraparam.ini&#8221; estão os parâmetros de inicialização para a instalação do Software Oracle no Linux.<br />
Vamos visualizar o mesmo.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle install]$ cat oraparam.ini
[Oracle]
DISTRIBUTION=TRUE
SOURCE=../stage/products.xml
LICENSE_LOCATION=
JRE_LOCATION=../stage/Components/oracle.swd.jre/1.4.2.8.0/1/DataFiles
JRE_MEMORY_OPTIONS=&quot; -mx150m&quot;
DEFAULT_HOME_LOCATION=oracle/product/10.2.0/db
DEFAULT_HOME_NAME=OraDb10g_home
NO_BROWSE=/net
NLS_ENABLED=TRUE
BOOTSTRAP=TRUE
PREREQ_CONFIG_LOCATION=../stage/prereq
OUI_VERSION=10.2.0.1.0
#SHOW_HOSTNAME=ALWAYS_SHOW shows the hostname panel always
#SHOW_HOSTNAME=NEVER_SHOW does not the hostname panel
#SHOW_HOSTNAME=CONDITION_SHOW shows the hostname panel on condition
SHOW_HOSTNAME=NEVER_SHOW
#THIN_JDBC_FILENAME is optional and defaults to classes12.jar
#The value specified for this should be packaged with OUI, and should
#be relative to &lt;OUI expanded stagedir&gt;/jlib/
THIN_JDBC_FILENAME=classes12.jar
#JRE_OSDPARAM is to set OS dependent param for JRE ( mainly for native VM in 1.3.1)
#JRE_OSDPARAM is optional and should be set to -native for the JRE's
#that support native VM ( mainly for Unix platforms ), in JRE 1.3.1
#For JRE 1.4.1 this should be set to empty or the type of VM that is
#supported client/server. The default value is -native in UNIX platforms
#that supports native VM
#Unix supporting native - JRE_OSDPARAM=&quot;-native&quot;
#Unix NOT supporting native and 1.4.1 - JRE_OSDPARAM=&quot;&quot;
JRE_OSDPARAM=&quot;&quot;
CLUSTERWARE={&quot;oracle.crs&quot;,&quot;10.1.0.2.0&quot;}
#RUN_OUICA specifies the batch script name that needs to be run
#The script is ouica.bat for win32, and ouica.sh for solaris.
#If the value is not specified, then the OUICA script is not run
RUN_OUICA=ouica.sh
SILENT_VARIABLE_VALIDATION=TRUE

[Certified Versions]
Linux=redhat-3,SuSE-9,redhat-4,UnitedLinux-1.0,asianux-1,asianux-2

[UnitedLinux-1.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-redhat-3.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-SuSE-9-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-redhat-4.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-asianux-1.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-asianux-2.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[IMAGES]
FILE1=images/rdbms_1.gif
FILE2=images/rdbms_2.gif
FILE3=images/rdbms_3.gif
FILE4=images/rdbms_4.gif
FILE5=images/rdbms_5.gif
FILE6=images/rdbms_6.gif
FILE7=images/rdbms_7.gif
FILE8=images/rdbms_8.gif

LICENSE_LOCATION=license.txt
[oracle@serveroracle install]$
</pre>
<p>Conforme acima, na linha abaixo de [Certified Versions] &#8220;Linux=redhat-3,SuSE-9,redhat-4,UnitedLinux-1.0,asianux-1,asianux-2&#8243; vamos adicionar o redhat-5 nesta.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle install]$ vi oraparam.ini
[oracle@serveroracle install]$ cat oraparam.ini
[Oracle]
DISTRIBUTION=TRUE
SOURCE=../stage/products.xml
LICENSE_LOCATION=
JRE_LOCATION=../stage/Components/oracle.swd.jre/1.4.2.8.0/1/DataFiles
JRE_MEMORY_OPTIONS=&quot; -mx150m&quot;
DEFAULT_HOME_LOCATION=oracle/product/10.2.0/db
DEFAULT_HOME_NAME=OraDb10g_home
NO_BROWSE=/net
NLS_ENABLED=TRUE
BOOTSTRAP=TRUE
PREREQ_CONFIG_LOCATION=../stage/prereq
OUI_VERSION=10.2.0.1.0
#SHOW_HOSTNAME=ALWAYS_SHOW shows the hostname panel always
#SHOW_HOSTNAME=NEVER_SHOW does not the hostname panel
#SHOW_HOSTNAME=CONDITION_SHOW shows the hostname panel on condition
SHOW_HOSTNAME=NEVER_SHOW
#THIN_JDBC_FILENAME is optional and defaults to classes12.jar
#The value specified for this should be packaged with OUI, and should
#be relative to &lt;OUI expanded stagedir&gt;/jlib/
THIN_JDBC_FILENAME=classes12.jar
#JRE_OSDPARAM is to set OS dependent param for JRE ( mainly for native VM in 1.3.1)
#JRE_OSDPARAM is optional and should be set to -native for the JRE's
#that support native VM ( mainly for Unix platforms ), in JRE 1.3.1
#For JRE 1.4.1 this should be set to empty or the type of VM that is
#supported client/server. The default value is -native in UNIX platforms
#that supports native VM
#Unix supporting native - JRE_OSDPARAM=&quot;-native&quot;
#Unix NOT supporting native and 1.4.1 - JRE_OSDPARAM=&quot;&quot;
JRE_OSDPARAM=&quot;&quot;
CLUSTERWARE={&quot;oracle.crs&quot;,&quot;10.1.0.2.0&quot;}
#RUN_OUICA specifies the batch script name that needs to be run
#The script is ouica.bat for win32, and ouica.sh for solaris.
#If the value is not specified, then the OUICA script is not run
RUN_OUICA=ouica.sh
SILENT_VARIABLE_VALIDATION=TRUE

[Certified Versions]
Linux=redhat-3,SuSE-9,redhat-4,UnitedLinux-1.0,asianux-1,asianux-2,redhat-5

[UnitedLinux-1.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-redhat-3.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-SuSE-9-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-redhat-4.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-asianux-1.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[Linux-asianux-2.0-optional]
TEMP_SPACE=80
SWAP_SPACE=150
MIN_DISPLAY_COLORS=256

[IMAGES]
FILE1=images/rdbms_1.gif
FILE2=images/rdbms_2.gif
FILE3=images/rdbms_3.gif
FILE4=images/rdbms_4.gif
FILE5=images/rdbms_5.gif
FILE6=images/rdbms_6.gif
FILE7=images/rdbms_7.gif
FILE8=images/rdbms_8.gif

LICENSE_LOCATION=license.txt
[oracle@serveroracle install]$
</pre>
<p>Após adicionarmos o redhat-5 na linha de certificação das versões dos sistemas operacionais, vamos executar novamente o &#8220;./runInstaller&#8221;.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle database]$ ./runInstaller
Starting Oracle Universal Installer...

Checking installer requirements...

Checking operating system version: must be redhat-3, SuSE-9, redhat-4, UnitedLinux-1.0, asianux-1, asianux-2 or redhat-5
                                      Passed

All installer requirements met.

Preparing to launch Oracle Universal Installer from /tmp/OraInstall2012-03-29_11-21-25AM. Please wait ...[oracle@serveroracle database]$
</pre>
<p>Pronto solucionamos o problema, agora basta continuar a instalação.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/04/05/falha-ao-tentar-instalar-banco-de-dados-oracle-10-2-0-1-em-oracle-linux-5-7/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>1º GUOB 2012</title>
		<link>http://www.oraclehome.com.br/2012/03/31/1o-guob-2012/</link>
		<comments>http://www.oraclehome.com.br/2012/03/31/1o-guob-2012/#comments</comments>
		<pubDate>Sat, 31 Mar 2012 18:55:55 +0000</pubDate>
		<dc:creator>Leandro Lana</dc:creator>
				<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Anderson Graf]]></category>
		<category><![CDATA[buffer cache]]></category>
		<category><![CDATA[Craig Shallahamer]]></category>
		<category><![CDATA[David Siqueira]]></category>
		<category><![CDATA[GOUB 2012]]></category>
		<category><![CDATA[Leandro Lana]]></category>
		<category><![CDATA[Rafael Stoever]]></category>
		<category><![CDATA[Rodrigo Almeida]]></category>
		<category><![CDATA[Rodrigo Mufalani]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2538</guid>
		<description><![CDATA[Conforme a muito tempo estavamos publicando via twitter, blogs pessoais e até mesmo aqui no oraclehome. Participamos do 1º encontro de 2012 do Grupo de Usuários Oracle (GUOB), que foi realizado no ultimo final de semana 24/03/2012 em São Paulo que contou com a presença do performance man Craig A. Shallahamer. Infelizmente perdemos a metade [...]]]></description>
			<content:encoded><![CDATA[<p>Conforme a muito tempo estavamos publicando via twitter, blogs pessoais e até mesmo aqui no oraclehome. Participamos do 1º encontro de 2012 do Grupo de Usuários Oracle (GUOB), que foi realizado no ultimo final de semana 24/03/2012 em São Paulo que contou com a presença do performance man Craig A. Shallahamer.</p>
<p><span id="more-2538"></span></p>
<p>Infelizmente perdemos a metade da primeira palestra, logística de Blumenau até São Paulo é meio complicada! Mas não vamos nos atentar a detalhes extra campo, vamos ao que nos interessa.</p>
<p>A primeira palestra conduzida por Craig, apesar de pegarmos pela metade devido os problemas citados acima, conseguimos ainda ver bastante conteúdo novo sobre o tema “Unit of work time based performance analysis” que nos dará pelo menos alguns meses de estudo para conhecermos mais sobre o assunto.</p>
<p>Para quem tiver interesse pode baixar o material desta palestra <a href="https://resources.orapub.com/SearchResults.asp?Search=guob+uowtba"> Clique aqui </a></p>
<p>O segundo palestrante, Flávio Rangel pela <a href="http://www.fusionsolutions.com.br/">Fusion Solution</a> aprentou a ferramenta Forms-up que permite a migração de forms/reports em pouco tempo de trabalho e sem demandar de um alto investimento. Ocorreram alguns erros tecnicos, mas isso esta sujeito a ocorrer em apresentações ao vivo.</p>
<p><strong>Vale lembrar que a ferramenta Forms-up é 100% brasileira!</strong></p>
<p>A terceira palestra foi conduzida pelo Kleuber Matta da <a href="http://www.quest.com/">Quest</a> Software que mostrou uma grade de softwares desenvolidos para administração de monitoramento de banco de dados, em especial o Foglight, simplesmente fantástico tanto pela facilidade quanto pela quantidade de informações que o mesmo traz de forma rápida e precisa.</p>
<p>Na quarta e ultima palestra, volta a cena o Craig com o tema “Introduction to Oracle Buffer Cache Internals”. Foi uma palestra muito tecnica e explicou a vida de um buffer chain, como funciona a lista de LRU e MRU, muito bom para quem esta começando no mundo oracle. Fóra que o Craig é uma figura, vivia fazendo piadinhas na palestra e isso divertiu muita gente.</p>
<p>Para quem tiver interesse pode baixar o material desta palestra <a href="https://resources.orapub.com/SearchResults.asp?Search=guob+buffer"> Clique aqui </a></p>
<p>Não podemos deixar de comentar também que o evento teve grande foco na confratermização entre os participantes do eventos afim de trocar contatos e experiências profissionais sobre o mundo Oracle.</p>
<p>Tivemos a participação neste eventos de alguns membros do programa Oracle ACE como David Siqueira, Rodrigo Almeida e Rodrigo Mufalani.</p>
<p>Pelo Oracle Home tivemos a participação dos administradores Anderson Graf, Leandro Lana e Rafael Stoever.</p>
<p>Abaixo temos a agenda dos próximos eventos de 2012, contamos com sua presença! Para ajudar a comunidade a crescer ainda mais.</p>
<table border="0">
<tbody>
<tr>
<td style="text-align: center;"> Junho/2012</td>
<td style="text-align: center;">2º Encontro do GUOB 2012</td>
<td style="text-align: center;">Brasilia</td>
</tr>
<tr>
<td style="text-align: center;">11/08/2012</td>
<td style="text-align: center;">GUOB Tech Day 2012</td>
<td style="text-align: center;">Hotel Blue Tree Morumbi &#8211; São Paulo</td>
</tr>
<tr>
<td style="text-align: center;">Outubro/2012</td>
<td style="text-align: center;">3º Encontro do GUOB 2012</td>
<td style="text-align: center;">Rio de Janeiro</td>
</tr>
<tr>
<td style="text-align: center;">22/11/2012</td>
<td style="text-align: center;">4º Encontro do GUOB 2012</td>
<td style="text-align: center;">Porto Alegre</td>
</tr>
<tr>
<td style="text-align: center;">Dezembro/2012</td>
<td style="text-align: center;"> Oracle Open World Latin America</td>
<td style="text-align: center;">São Paulo</td>
</tr>
</tbody>
</table>
<p>As datas podem sofrer alterações.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/03/31/1o-guob-2012/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>SYS_CONTEXT &#8216;USERENV&#8217;</title>
		<link>http://www.oraclehome.com.br/2012/03/29/sys_context-userenv/</link>
		<comments>http://www.oraclehome.com.br/2012/03/29/sys_context-userenv/#comments</comments>
		<pubDate>Thu, 29 Mar 2012 12:00:20 +0000</pubDate>
		<dc:creator>Leandro Lana</dc:creator>
				<category><![CDATA[Literatura]]></category>
		<category><![CDATA[PL/SQL]]></category>
		<category><![CDATA[audit]]></category>
		<category><![CDATA[debug]]></category>
		<category><![CDATA[function]]></category>
		<category><![CDATA[host]]></category>
		<category><![CDATA[showenv]]></category>
		<category><![CDATA[sid]]></category>
		<category><![CDATA[sys_context]]></category>
		<category><![CDATA[userenv]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2548</guid>
		<description><![CDATA[Bom dia. Para muitos esse é um tópico batido, e muitos já saberão a fundo do mesmo. Porem não custa escrever para quem não conhece utilizar. Aqui no www.oraclehome.com.br já tivemos um post do nosso ADM Anderson Graf que utilizou o sys_context para pegar o seu sid. Clique aqui para ver o post do Anderson. &#160; [...]]]></description>
			<content:encoded><![CDATA[<p>Bom dia.</p>
<p>Para muitos esse é um tópico batido, e muitos já saberão a fundo do mesmo. Porem não custa escrever para quem não conhece utilizar.</p>
<p>Aqui no www.oraclehome.com.br já tivemos um post do nosso ADM Anderson Graf que utilizou o sys_context para pegar o seu sid. <a href="http://www.oraclehome.com.br/2011/09/04/identificando-meu-session-id/">Clique aqui </a>para ver o post do Anderson.</p>
<p>&nbsp;</p>
<p><span id="more-2548"></span></p>
<p>Bom pessoal o sys_context foi criado para coletar informações próprias.</p>
<p>Observe a syntaxe.</p>
<pre class="brush: sql; title: ; notranslate">
select sys_context('USERENV','SID') &quot;SID&quot; from dual;
</pre>
<p>Este select irá retornar o sid da seção que esta executando. Porem temos varias outras possibilidades para o sys_context.</p>
<p>Observe o select abaixo:</p>
<pre class="brush: sql; title: ; notranslate">
SELECT
  SYS_CONTEXT( 'USERENV', 'ACTION' ) action,
  SYS_CONTEXT( 'USERENV', 'AUTHENTICATION_METHOD' ) authentication_method,
  SYS_CONTEXT( 'USERENV', 'BG_JOB_ID' ) bg_job_id,
  SYS_CONTEXT( 'USERENV', 'CLIENT_IDENTIFIER' ) client_identifier,
  SYS_CONTEXT( 'USERENV', 'CLIENT_INFO' ) client_info,
  SYS_CONTEXT( 'USERENV', 'CURRENT_SCHEMAID' ) current_schemaid,
  SYS_CONTEXT( 'USERENV', 'CURRENT_SCHEMA' ) current_schema,
  SYS_CONTEXT( 'USERENV', 'CURRENT_USER' ) current_user,
  SYS_CONTEXT( 'USERENV', 'DB_DOMAIN' ) db_domain,
  SYS_CONTEXT( 'USERENV', 'DB_NAME' ) db_name,
  SYS_CONTEXT( 'USERENV', 'DB_UNIQUE_NAME' ) db_unique_name,
  SYS_CONTEXT( 'USERENV', 'HOST' ) host,
  SYS_CONTEXT( 'USERENV', 'INSTANCE' ) instance,
  SYS_CONTEXT( 'USERENV', 'INSTANCE_NAME' ) instance_name,
  SYS_CONTEXT( 'USERENV', 'IP_ADDRESS' ) ip_address,
  SYS_CONTEXT( 'USERENV', 'ISDBA' ) isdba,
  SYS_CONTEXT( 'USERENV', 'LANG' ) lang,
  SYS_CONTEXT( 'USERENV', 'LANGUAGE' ) language,
  SYS_CONTEXT( 'USERENV', 'NETWORK_PROTOCOL' ) network_protocol,
  SYS_CONTEXT( 'USERENV', 'NLS_CALENDAR' ) nls_calendar,
  SYS_CONTEXT( 'USERENV', 'NLS_CURRENCY' ) nls_currency,
  SYS_CONTEXT( 'USERENV', 'OS_USER' ) os_user,
  SYS_CONTEXT( 'USERENV', 'SERVER_HOST' ) server_host,
  SYS_CONTEXT( 'USERENV', 'TERMINAL' ) terminal
FROM dual;
</pre>
<p>Então estes são todos os parâmetros que você pode coletar de si mesmo.<br />
Muitos vão me questionar. Pra que serve saber meu IP, ou meu host?<br />
Bom, para muitas coisas. Para debugar um pl/sql ou até mesmo para auditar informações de quem executou determinadas funções.</p>
<p>Também há como coletar estas informações através de funções.</p>
<pre class="brush: sql; title: ; notranslate">
DECLARE
   PROCEDURE showenv (str IN VARCHAR2) IS
   BEGIN
      DBMS_OUTPUT.PUT_LINE (
         str || '=' || SYS_CONTEXT ('USERENV', str));
   END;
BEGIN
   showenv ('NLS_CURRENCY');
   showenv ('NLS_CALENDAR');
   showenv ('NLS_DATE_FORMAT');
   showenv ('NLS_DATE_LANGUAGE');
   showenv ('NLS_SORT');
   showenv ('SESSION_USER');
   showenv ('CURRENT_USER');
   showenv ('CURRENT_SCHEMA');
   showenv ('CURRENT_SCHEMAID');
   showenv ('SESSION_USERID');
   showenv ('CURRENT_USERID');
   showenv ('IP_ADDRESS');
END;
/
</pre>
<p>Cada campo &#8220;showenv (&#8216;XXXXXXX&#8217;);&#8221;, pode ser adicionado uma linha daquelas la em cima onde já postei.<br />
Observe na Pratica.</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; set serveroutput on
SQL&gt; DECLARE
  2     PROCEDURE showenv (str IN VARCHAR2) IS
  3     BEGIN
  4        DBMS_OUTPUT.PUT_LINE (
  5           str || '=' || SYS_CONTEXT ('USERENV', str));
  6     END;
  7  BEGIN
  8     showenv ('NLS_CURRENCY');
  9     showenv ('NLS_CALENDAR');
 10     showenv ('NLS_DATE_FORMAT');
 11     showenv ('NLS_DATE_LANGUAGE');
 12     showenv ('NLS_SORT');
 13     showenv ('SESSION_USER');
 14     showenv ('CURRENT_USER');
 15     showenv ('CURRENT_SCHEMA');
 16     showenv ('CURRENT_SCHEMAID');
 17     showenv ('SESSION_USERID');
 18     showenv ('CURRENT_USERID');
 19     showenv ('IP_ADDRESS');
 20  END;
 21  /

NLS_CURRENCY=$
NLS_CALENDAR=GREGORIAN
NLS_DATE_FORMAT=DD-MON-RR
NLS_DATE_LANGUAGE=AMERICAN
NLS_SORT=BINARY
SESSION_USER=LANA
CURRENT_USER=LANA
CURRENT_SCHEMA=LANA
CURRENT_SCHEMAID=56
SESSION_USERID=56
CURRENT_USERID=56
IP_ADDRESS=192.168.10.198

PL/SQL procedure successfully completed
</pre>
<p>Qualquer duvida estou a disposição para responder seus comentários.</p>
<p>Ref: <a href="http://docstore.mik.ua/orelly/oracle/guide8i/ch08_04.htm#ch08-53171">docstore.mik.ua </a> e <a href="http://docs.oracle.com/cd/B19306_01/server.102/b14200/functions165.htm#i1038176"> docs.oracle.com </a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/03/29/sys_context-userenv/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Erro ao subir o ASM durante aplicação do Patch 12419392</title>
		<link>http://www.oraclehome.com.br/2012/03/27/erro-ao-subir-o-asm-durante-aplicacao-do-patch-12419392/</link>
		<comments>http://www.oraclehome.com.br/2012/03/27/erro-ao-subir-o-asm-durante-aplicacao-do-patch-12419392/#comments</comments>
		<pubDate>Tue, 27 Mar 2012 10:31:53 +0000</pubDate>
		<dc:creator>Maycon Tomiasi</dc:creator>
				<category><![CDATA[Erros]]></category>
		<category><![CDATA[Instalação]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[12419392]]></category>
		<category><![CDATA[aplicando]]></category>
		<category><![CDATA[asm]]></category>
		<category><![CDATA[banco]]></category>
		<category><![CDATA[banco de dados]]></category>
		<category><![CDATA[base]]></category>
		<category><![CDATA[dados]]></category>
		<category><![CDATA[data]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[erro]]></category>
		<category><![CDATA[Listener]]></category>
		<category><![CDATA[non-RAC]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[Patch]]></category>
		<category><![CDATA[Patch 12419392]]></category>
		<category><![CDATA[Patch PSU 10.2.0.5.4]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2517</guid>
		<description><![CDATA[Este artigo tem como objetivo explicar o motivo do erro após aplicar o Patch PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.0 ao subir a instância ASM. Estou usando um Banco de Dados Single Instance com ASM, ou seja, non-RAC. Após o Patch Aplicado continuei o processo de aplicação do Patch no Banco de [...]]]></description>
			<content:encoded><![CDATA[<p>Este artigo tem como objetivo explicar o motivo do erro após aplicar o Patch PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.0 ao subir a instância ASM.<br />
Estou usando um Banco de Dados Single Instance com ASM, ou seja, non-RAC.</p>
<p>Após o Patch Aplicado continuei o processo de aplicação do Patch no Banco de Dados. Subi os serviços do Banco de Dados e no momento de subir a instância ASM ocorreu o erro.</p>
<p><span id="more-2517"></span><br />
Subindo o Listener.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ lsnrctl start

LSNRCTL for Linux: Version 10.2.0.5.0 - Production on 15-MAR-2012 17:52:43

Copyright (c) 1991, 2010, Oracle.  All rights reserved.

Starting /oraprd01/app/oracle/product/10.2.0/db_1/bin/tnslsnr: please wait...

TNSLSNR for Linux: Version 10.2.0.5.0 - Production
System parameter file is /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
Log messages written to /oraprd01/app/oracle/product/10.2.0/db_1/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.56.104)(PORT=1521)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.56.104)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 10.2.0.5.0 - Production
Start Date                15-MAR-2012 17:52:43
Uptime                    0 days 0 hr. 0 min. 0 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
Listener Log File         /oraprd01/app/oracle/product/10.2.0/db_1/network/log/listener.log
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.56.104)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))
Services Summary...
Service &quot;PLSExtProc&quot; has 1 instance(s).
  Instance &quot;PLSExtProc&quot;, status UNKNOWN, has 1 handler(s) for this service...
Service &quot;dbprod&quot; has 1 instance(s).
  Instance &quot;dbprod&quot;, status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully
[oracle@serveroracle 12419392]$
</pre>
<p>Vamos subir a Instância ASM.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ export ORACLE_SID=+ASM
[oracle@serveroracle 12419392]$ sqlplus sys/***** as sysdba

SQL*Plus: Release 10.2.0.5.0 - Production on Thu Mar 15 17:53:01 2012

Copyright (c) 1982, 2010, Oracle.  All Rights Reserved.

Connected to an idle instance.

SQL&gt; startup mount
ORA-29701: unable to connect to Cluster Manager
SQL&gt; shutdown immediate
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux Error: 2: No such file or directory
SQL&gt; exit
Disconnected
[oracle@serveroracle 12419392]$
</pre>
<p>Ao tentar subir a Instância ASM, ocorreu um problema no Cluster Manager, no qual, não foi possível conectar ao mesmo.<br />
Para resolver o problema, devemos remover o css com o usuário &#8220;root&#8221; e acessar o diretório &#8220;$ORACLE_HOME/bin&#8221; e executar os seguintes comandos:<br />
- localconfig delete<br />
- localconfig add</p>
<p>Com estes comandos removerá o CSS e o configurará o mesmo novamente.<br />
Vamos executar os mesmos com o usuário &#8220;root&#8221;.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ su -
Password:
[root@serveroracle ~]# /oraprd01/app/oracle/product/10.2.0/db_1/bin/localconfig delete
Stopping CSSD.
Shutting down CSS daemon.
Shutdown request successfully issued.
Shutdown has begun. The daemons should exit soon.
[root@serveroracle ~]# /oraprd01/app/oracle/product/10.2.0/db_1/bin/localconfig add
Successfully accumulated necessary OCR keys.
Creating OCR keys for user 'root', privgrp 'root'..
Operation successful.
Configuration for local CSS has been initialized

Adding to inittab
Startup will be queued to init within 30 seconds.
Checking the status of new Oracle init process...
Expecting the CRS daemons to be up within 600 seconds.
CSS is active on these nodes.
        serveroracle
CSS is active on all nodes.
Oracle CSS service is installed and running under init(1M)
[root@serveroracle ~]# exit
logout
[oracle@serveroracle 12419392]$
</pre>
<p>Com o usuário Oracle vamos subir a instância ASM.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ sqlplus sys/***** as sysdba

SQL*Plus: Release 10.2.0.5.0 - Production on Thu Mar 15 17:55:10 2012

Copyright (c) 1982, 2010, Oracle.  All Rights Reserved.

Connected to an idle instance.

SQL&gt; startup mount
ASM instance started

Total System Global Area   83886080 bytes
Fixed Size                  1272120 bytes
Variable Size              57448136 bytes
ASM Cache                  25165824 bytes
ASM diskgroups mounted
SQL&gt; exit
Disconnected from Oracle Database 10g Release 10.2.0.5.0 - Production
[oracle@serveroracle 12419392]$
</pre>
<p>Pronto, basta subir o Banco de Dados e terminar o processo de aplicação do Patch 12419392.<br />
Veja o artigo da Aplicação do Patch 12419392 acessando <a href="http://www.oraclehome.com.br/2012/03/23/aplicando-patch-psu-10-2-0-5-4-no-banco-de-dados-oracle-10-2-0-5-0-non-rac/" target="_blank">Aplicando Patch PSU 10.2.0.5.4 no Banco de Dados Oracle 10.2.0.5.0 non-RAC</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/03/27/erro-ao-subir-o-asm-durante-aplicacao-do-patch-12419392/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Como adicionar novos discos SATA, via Oracle VirtualBox em seu ambiente Linux virtualizado ja existente.</title>
		<link>http://www.oraclehome.com.br/2012/03/26/como-adicionar-novos-discos-sata-via-oracle-virtualbox-em-seu-ambiente-linux-virtualizado-ja-existente/</link>
		<comments>http://www.oraclehome.com.br/2012/03/26/como-adicionar-novos-discos-sata-via-oracle-virtualbox-em-seu-ambiente-linux-virtualizado-ja-existente/#comments</comments>
		<pubDate>Mon, 26 Mar 2012 14:36:22 +0000</pubDate>
		<dc:creator>Jone Jarouj</dc:creator>
				<category><![CDATA[Oracle Linux]]></category>
		<category><![CDATA[Server e Storage Systems]]></category>
		<category><![CDATA[Virtual Box]]></category>
		<category><![CDATA[disco]]></category>
		<category><![CDATA[disk]]></category>
		<category><![CDATA[fdisk]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Maquina Virtual]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[Sata]]></category>
		<category><![CDATA[VirtualBox]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2470</guid>
		<description><![CDATA[O exemplo aqui mostrado foi feito em um SO RedHat Enterprise Linux 5 update 2. Caso voce tenha criado sua maquina virtual, com pouco espaço, eu necessite adicionar mais espaço devido ao crescimento do seu ambiente, a seguir, daremos passo a passo de como adicionar novos discos SATA ao seu ambiente Linux. Em sua janela [...]]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;">O exemplo aqui mostrado foi feito em um SO RedHat Enterprise Linux 5 update 2.</p>
<p style="text-align: justify;">Caso voce tenha criado sua maquina virtual, com pouco espaço, eu necessite adicionar mais espaço devido ao crescimento do seu ambiente, a seguir, daremos passo a passo de como adicionar novos discos SATA ao seu ambiente Linux.</p>
<p style="text-align: justify;">Em sua janela inicial do VirtualBox, selecione a maquina virtual que deseja adicionar disco e clique em <em>configurações</em>:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img1.jpg"><img class="alignnone size-medium wp-image-2471" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img1-300x117.jpg" alt="" width="300" height="117" /></a></p>
<p><span id="more-2470"></span></p>
<p>Na tela de configurações, vá em armazenamento:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img2.jpg"><img class="alignnone size-medium wp-image-2472" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img2-300x216.jpg" alt="" width="300" height="216" /></a></p>
<p>Voce pode escolher adicionar novos discos IDE ou novos discos SATA, aqui optado por adicionar um novo disco SATA:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img3.jpg"><img class="alignnone size-medium wp-image-2473" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img3-300x217.jpg" alt="" width="300" height="217" /></a></p>
<p>Iremos optar por <em>Criar novo disco</em>.</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img4.jpg"><img class="alignnone size-medium wp-image-2474" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img4-300x218.jpg" alt="" width="300" height="218" /></a></p>
<p>Optar pelo formato nativo do Oracle VirtualBox, VDI:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img5.jpg"><img class="alignnone size-medium wp-image-2475" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img5-300x218.jpg" alt="" width="300" height="218" /></a></p>
<p>Escolher <em>dinamicamente alocado</em>, pois desta forma, o disco que está sendo criado, só irá crescer conforme demanda e não será alocado todo seu tamanho no momento de sua criação.</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img6.jpg"><img class="alignnone size-medium wp-image-2476" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img6-300x218.jpg" alt="" width="300" height="218" /></a></p>
<p>Escolha a localização do seu novo disco e o tamanho do mesmo, aqui colocado 10 Giga, aproximadamente:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img7.jpg"><img class="alignnone size-medium wp-image-2477" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img7-300x217.jpg" alt="" width="300" height="217" /></a></p>
<p>Leia o resumo das suas escolhas e se estiver tudo ok, clique em <em>Criar</em>:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img8.jpg"><img class="alignnone size-medium wp-image-2478" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img8-300x219.jpg" alt="" width="300" height="219" /></a></p>
<p>Seu novo disco irá aparecer nas opções de Armazenamento/Controladora SATA com o nome que você o deu anteriormente:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img9.jpg"><img class="alignnone size-medium wp-image-2479" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img9-300x217.jpg" alt="" width="300" height="217" /></a></p>
<p style="text-align: justify;">Clique em Ok.</p>
<p style="text-align: justify;">Agora iremos iniciar a maquina virtual e formataremos o disco adicionado, pois o mesmo ao inicia-la, ainda não está pronto para uso.</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img10.jpg"><img class="alignnone size-medium wp-image-2480" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img10-300x250.jpg" alt="" width="300" height="250" /></a></p>
<p style="text-align: justify;">Logue no Linux com seu usuário/senha do root.</p>
<p style="text-align: justify;">Abra um terminal.</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img11.jpg"><img class="alignnone size-medium wp-image-2481" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img11-300x294.jpg" alt="" width="300" height="294" /></a></p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img12.jpg"><img class="alignnone size-medium wp-image-2482" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img12-300x190.jpg" alt="" width="300" height="190" /></a></p>
<p>Execute o comando fdisk –l:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img131.jpg"><img class="alignnone size-medium wp-image-2484" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img131-300x223.jpg" alt="" width="300" height="223" /></a></p>
<p style="text-align: justify;">Veja que há um dispositivo chamado /dev/sdb que não contem tabelas de partições validas que é justamente o disco que adicionamos.</p>
<p style="text-align: justify;">Iremos formata-lo no formato ext3:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img141.jpg"><img class="alignnone size-medium wp-image-2486" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img141-300x66.jpg" alt="" width="300" height="66" /></a></p>
<p>De um “y” e pressione Enter para iniciar a formatação:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img15.jpg"><img class="alignnone size-medium wp-image-2487" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img15-300x199.jpg" alt="" width="300" height="199" /></a></p>
<p>Após finalizar iremos monta-lo:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img16.jpg"><img class="alignnone size-medium wp-image-2488" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img16-300x115.jpg" alt="" width="300" height="115" /></a></p>
<p>Podemos acessa-lo normalmente neste momento:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img17.jpg"><img class="alignnone size-medium wp-image-2489" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img17-300x47.jpg" alt="" width="300" height="47" /></a></p>
<p style="text-align: justify;">Faltam duas coisas para finalizarmos o procedimento neste momento, dar-lhe as permissões necessárias, irei colocar 755 e faze-lo montar automaticamente no boot na maquina.</p>
<p style="text-align: justify;">Segue os procedimentos, então:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img18.jpg"><img class="alignnone size-medium wp-image-2490" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img18-300x62.jpg" alt="" width="300" height="62" /></a></p>
<p style="text-align: justify;">Com o comando vi, edite o arquivo /etc/fstab: [root@jonestby ~]# vi /etc/fstab</p>
<p style="text-align: justify;">Agora adicione o dispositivo, o diretório onde o mesmo será montado, o formato de arquivo formatado, configurações defaults para opções de montagem e 1 1 para verificar com o fsck no boot da maquina. Salve o arquivo.</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img19.jpg"><img class="alignnone size-medium wp-image-2491" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img19-300x66.jpg" alt="" width="300" height="66" /></a></p>
<p>Após isto vamos rebootar a maquina e testar a “montagem” automatica do nosso novo disco.</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img202.jpg"><img class="alignnone size-medium wp-image-2497" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img202-300x53.jpg" alt="" width="300" height="53" /></a></p>
<p>Logue no seu sistema novamente após reiniciar, abra o terminal e execute o comando df –h, para verificar se seu disco montou automaticamente:</p>
<p><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img21.jpg"><img class="alignnone size-medium wp-image-2494" src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Img21-300x178.jpg" alt="" width="300" height="178" /></a></p>
<p>Está ae, agora voce tem mais 10 Giga,  aproximadamente em seu Linux virtualizado via Oracle VirtualBox.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/03/26/como-adicionar-novos-discos-sata-via-oracle-virtualbox-em-seu-ambiente-linux-virtualizado-ja-existente/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Erro &#8220;Re-link fails on target &#8220;client_sharedlib&#8221;&quot; durante aplicação do Patch 12419392</title>
		<link>http://www.oraclehome.com.br/2012/03/26/erro-re-link-fails-on-target-client_sharedlib-durante-aplicacao-do-patch-12419392/</link>
		<comments>http://www.oraclehome.com.br/2012/03/26/erro-re-link-fails-on-target-client_sharedlib-durante-aplicacao-do-patch-12419392/#comments</comments>
		<pubDate>Mon, 26 Mar 2012 13:26:46 +0000</pubDate>
		<dc:creator>Maycon Tomiasi</dc:creator>
				<category><![CDATA[Erros]]></category>
		<category><![CDATA[Instalação]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[12419392]]></category>
		<category><![CDATA[arquivo]]></category>
		<category><![CDATA[banco]]></category>
		<category><![CDATA[banco de dados]]></category>
		<category><![CDATA[base]]></category>
		<category><![CDATA[dados]]></category>
		<category><![CDATA[data]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[Listener]]></category>
		<category><![CDATA[OPatch/opatch apply]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[Patch]]></category>
		<category><![CDATA[Re-link fails on target "client_sharedlib"]]></category>
		<category><![CDATA[shrept.lst]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2513</guid>
		<description><![CDATA[Este artigo tem como objetivo explicar o erro ocorrido &#8220;Re-link fails on target &#8220;client_sharedlib&#8221;.&#8221; durante aplicaçao do Patch PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.0 e como corrigir o mesmo. Estou usando um Banco de Dados Single Instance com ASM, ou seja, non-RAC. OBS: Sempre faz backup do produto Oracle antes aplicar qualquer [...]]]></description>
			<content:encoded><![CDATA[<p>Este artigo tem como objetivo explicar o erro ocorrido &#8220;Re-link fails on target &#8220;client_sharedlib&#8221;.&#8221; durante aplicaçao do Patch PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.0 e como corrigir o mesmo.<br />
Estou usando um Banco de Dados Single Instance com ASM, ou seja, non-RAC.<br />
OBS: Sempre faz backup do produto Oracle antes aplicar qualquer Patch da Oracle para voltar o mesmo caso a aplicação do Patch não ocorra com Sucesso.<br />
OBS: Para aplicar o Patch, deve-se certificar que todos os serviços do Banco de Dados esteja baixados (Listener, Banco de Dados, Enterprise Manager, ISQLPlus).</p>
<p><span id="more-2513"></span><br />
Vamos checar a versão do OPatch e verificar se nosso Banco de Dados está baixado.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ /oraprd01/app/oracle/product/10.2.0/db_1/OPatch/opatch version
Invoking OPatch 10.2.0.5.1

OPatch Version: 10.2.0.5.1

OPatch succeeded.
[oracle@serveroracle 12419392]$ lsnrctl status

LSNRCTL for Linux: Version 10.2.0.5.0 - Production on 15-MAR-2012 16:46:18

Copyright (c) 1991, 2010, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.56.104)(PORT=1521)))
TNS-12541: TNS:no listener
 TNS-12560: TNS:protocol adapter error
  TNS-00511: No listener
   Linux Error: 111: Connection refused
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC0)))
TNS-12541: TNS:no listener
 TNS-12560: TNS:protocol adapter error
  TNS-00511: No listener
   Linux Error: 2: No such file or directory
[oracle@serveroracle 12419392]$ ps -ef | grep pmon
oracle    8371  3654  0 16:46 pts/1    00:00:00 grep pmon
[oracle@serveroracle 12419392]$
</pre>
<p>Conforme checado a versão do OPatch e o status dos serviços do Banco de Dados Oracle, vamos aplicar o Patch 12419392.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ /oraprd01/app/oracle/product/10.2.0/db_1/OPatch/opatch apply
Invoking OPatch 10.2.0.5.1

Oracle Interim Patch Installer version 10.2.0.5.1
Copyright (c) 2010, Oracle Corporation.  All rights reserved.

Oracle Home       : /oraprd01/app/oracle/product/10.2.0/db_1
Central Inventory : /oraprd01/app/oracle/oraInventory
   from           : /etc/oraInst.loc
OPatch version    : 10.2.0.5.1
OUI version       : 10.2.0.5.0
OUI location      : /oraprd01/app/oracle/product/10.2.0/db_1/oui
Log file location : /oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/opatch/opatch2012-03-15_17-02-08PM.log

Patch history file: /oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/opatch/opatch_history.txt

ApplySession applying interim patch '12419392' to OH '/oraprd01/app/oracle/product/10.2.0/db_1'
Interim patch 12419392 is a superset of the patch(es) [  12419392 ] in the Oracle Home
OPatch will rollback the subset patches and apply the given patch.

Running prerequisite checks...
Patch 12419392: Optional component(s) missing : [ oracle.rdbms.dv, 10.2.0.5.0 ] , [ oracle.rdbms.dv.oc4j, 10.2.0.5.0 ]
Provide your email address to be informed of security issues, install and
initiate Oracle Configuration Manager. Easier for you if you use your My
Oracle Support Email address/User Name.
Visit http://www.oracle.com/support/policies.html for details.
Email address/User Name:

You have not provided an email address for notification of security issues.
Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]:  y

OPatch detected non-cluster Oracle Home from the inventory and will patch the local system only.

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/oraprd01/app/oracle/product/10.2.0/db_1')

Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files and inventory (not for auto-rollback) for the Oracle Home
Backing up files affected by the patch '12419392' for restore. This might take a while...
Backing up files affected by the patch '12419392' for restore. This might take a while...
ApplySession rolling back interim patch '12419392' from OH '/oraprd01/app/oracle/product/10.2.0/db_1'
Execution of 'sh /oraprd01/app/oracle/product/10.2.0/db_1/.patch_storage/12419392_May_25_2011_01_06_08/original_patch/custom/scripts/pre -rollback 12419392 ':

Return Code = 0

Patching component oracle.rdbms, 10.2.0.5.0...
Updating archive file &quot;/oraprd01/app/oracle/product/10.2.0/db_1/lib/libserver10.a&quot;  with &quot;lib/libserver10.a/kcbl.o&quot;
.
.
.
Patching component oracle.precomp.common, 10.2.0.5.0...

Patching component oracle.rdbms.rman, 10.2.0.5.0...
Running make for target ioracle
Running make for target iwrap
Running make for target client_sharedlib
Make failed to invoke &quot;/usr/bin/make -f ins_net_client.mk client_sharedlib ORACLE_HOME=/oraprd01/app/oracle/product/10.2.0/db_1&quot;....'genclntsh: genclntsh: Could not locate  /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/shrept.lst
make: *** [client_sharedlib] Error 1
'
Running make for target proc
Running make for target irman
Running make for target client_sharedlib
Make failed to invoke &quot;/usr/bin/make -f ins_rdbms.mk client_sharedlib ORACLE_HOME=/oraprd01/app/oracle/product/10.2.0/db_1&quot;....'genclntsh: genclntsh: Could not locate  /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/shrept.lst
make: *** [client_sharedlib] Error 1
'

The following make actions have failed :

Re-link fails on target &quot;client_sharedlib&quot;.
Re-link fails on target &quot;client_sharedlib&quot;.

Do you want to proceed? [y|n]
y
User Responded with: Y
ApplySession adding interim patch '12419392' to inventory

Verifying the update...
Inventory check OK: Patch ID 12419392 is registered in Oracle Home inventory with proper meta-data.
Files check OK: Files from Patch ID 12419392 are present in Oracle Home.

The local system has been patched and can be restarted.

--------------------------------------------------------------------------------
The following warnings have occurred during OPatch execution:
1) OUI-67620:Interim patch 12419392 is a superset of the patch(es) [  12419392 ] in the Oracle Home
2) OUI-67200:Make failed to invoke &quot;/usr/bin/make -f ins_net_client.mk client_sharedlib ORACLE_HOME=/oraprd01/app/oracle/product/10.2.0/db_1&quot;....'genclntsh: genclntsh: Could not locate  /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/shrept.lst
make: *** [client_sharedlib] Error 1
'
3) OUI-67200:Make failed to invoke &quot;/usr/bin/make -f ins_rdbms.mk client_sharedlib ORACLE_HOME=/oraprd01/app/oracle/product/10.2.0/db_1&quot;....'genclntsh: genclntsh: Could not locate  /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/shrept.lst
make: *** [client_sharedlib] Error 1
'
4) OUI-67124:Re-link fails on target &quot;client_sharedlib&quot;.
Re-link fails on target &quot;client_sharedlib&quot;.

--------------------------------------------------------------------------------
OPatch Session completed with warnings.

OPatch completed with warnings.
[oracle@serveroracle 12419392]$
</pre>
<p>Durante o processo de aplicação do Patch, ocorreu os erros acima ao invocar o &#8220;make&#8221; para o &#8220;client_sharedlib&#8221; que não conseguiu encontrar o arquivo &#8220;shrept.lst&#8221; no diretório &#8220;/oraprd01/app/oracle/product/10.2.0/db_1/network/admin/&#8221;.<br />
Vamos verificar se existe o arquivo.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ ls -l /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/shrept.lst
ls: /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/shrept.lst: No such file or directory
[oracle@serveroracle 12419392]$
</pre>
<p>Conforme acima, o arquivo não existe.<br />
Com o usuário &#8220;oracle&#8221; realizei uma cópia do arquivo &#8220;shrept.lst&#8221; de um outro servidor de Banco de Dados e fiz uma cópia do mesmo no meu servidor de Banco de Dados no diretório &#8220;/oraprd01/app/oracle/product/10.2.0/db_1/network/admin/&#8221;.<br />
Segue o arquivo abaixo:</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle admin]$ cat shrept.lst
# function entry points for genclntsh.sh

network : snaumihi_inithostinfo
network : snaumbg_gmt
network : naedpwd_encrypt
network : naumbsb_bld_singlebyte
network : ztapis
[oracle@serveroracle admin]$
</pre>
<p>Vamos entrar novamente no diretório do Patch e aplicar o mesmo.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ /oraprd01/app/oracle/product/10.2.0/db_1/OPatch/opatch apply
Invoking OPatch 10.2.0.5.1

Oracle Interim Patch Installer version 10.2.0.5.1
Copyright (c) 2010, Oracle Corporation.  All rights reserved.

Oracle Home       : /oraprd01/app/oracle/product/10.2.0/db_1
Central Inventory : /oraprd01/app/oracle/oraInventory
   from           : /etc/oraInst.loc
OPatch version    : 10.2.0.5.1
OUI version       : 10.2.0.5.0
OUI location      : /oraprd01/app/oracle/product/10.2.0/db_1/oui
Log file location : /oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/opatch/opatch2012-03-15_17-44-00PM.log

Patch history file: /oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/opatch/opatch_history.txt

ApplySession applying interim patch '12419392' to OH '/oraprd01/app/oracle/product/10.2.0/db_1'
Interim patch 12419392 is a superset of the patch(es) [  12419392 ] in the Oracle Home
OPatch will rollback the subset patches and apply the given patch.

Running prerequisite checks...
Patch 12419392: Optional component(s) missing : [ oracle.rdbms.dv, 10.2.0.5.0 ] , [ oracle.rdbms.dv.oc4j, 10.2.0.5.0 ]
Provide your email address to be informed of security issues, install and
initiate Oracle Configuration Manager. Easier for you if you use your My
Oracle Support Email address/User Name.
Visit http://www.oracle.com/support/policies.html for details.
Email address/User Name:

You have not provided an email address for notification of security issues.
Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]:  y

OPatch detected non-cluster Oracle Home from the inventory and will patch the local system only.

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/oraprd01/app/oracle/product/10.2.0/db_1')

Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files and inventory (not for auto-rollback) for the Oracle Home
Backing up files affected by the patch '12419392' for restore. This might take a while...
Backing up files affected by the patch '12419392' for restore. This might take a while...
ApplySession rolling back interim patch '12419392' from OH '/oraprd01/app/oracle/product/10.2.0/db_1'
Execution of 'sh /oraprd01/app/oracle/product/10.2.0/db_1/.patch_storage/12419392_May_25_2011_01_06_08/original_patch/custom/scripts/pre -rollback 12419392 ':

Return Code = 0

Patching component oracle.rdbms, 10.2.0.5.0...
Updating archive file &quot;/oraprd01/app/oracle/product/10.2.0/db_1/lib/libserver10.a&quot;  with &quot;lib/libserver10.a/kcbl.o&quot;
.
.
.
Patching component oracle.rdbms.rman, 10.2.0.5.0...
Running make for target ioracle
Running make for target iwrap
Running make for target client_sharedlib
Running make for target proc
Running make for target irman
Running make for target client_sharedlib
ApplySession adding interim patch '12419392' to inventory

Verifying the update...
Inventory check OK: Patch ID 12419392 is registered in Oracle Home inventory with proper meta-data.
Files check OK: Files from Patch ID 12419392 are present in Oracle Home.

The local system has been patched and can be restarted.

--------------------------------------------------------------------------------
The following warnings have occurred during OPatch execution:
1) OUI-67620:Interim patch 12419392 is a superset of the patch(es) [  12419392 ] in the Oracle Home
--------------------------------------------------------------------------------
OPatch Session completed with warnings.

OPatch completed with warnings.
[oracle@serveroracle 12419392]$
</pre>
<p>Pronto corrigimos o problema basta terminar o processo de aplicação do Patch 12419392 PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.<br />
Mais informações sobre aplicação do Patch acompanhar o arquivo README que vem junto no pacote do Patch 12419392.<br />
Veja o artigo da Aplicação do Patch 12419392 acessando <a href="http://www.oraclehome.com.br/2012/03/23/aplicando-patch-psu-10-2-0-5-4-no-banco-de-dados-oracle-10-2-0-5-0-non-rac/" target="_blank">Aplicando Patch PSU 10.2.0.5.4 no Banco de Dados Oracle 10.2.0.5.0 non-RAC</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/03/26/erro-re-link-fails-on-target-client_sharedlib-durante-aplicacao-do-patch-12419392/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Erro &#8220;OPatch failed with error code 73&#8243; durante aplicação do Patch 12419392.</title>
		<link>http://www.oraclehome.com.br/2012/03/26/erro-opatch-failed-with-error-code-73-durante-aplicacao-do-patch-12419392/</link>
		<comments>http://www.oraclehome.com.br/2012/03/26/erro-opatch-failed-with-error-code-73-durante-aplicacao-do-patch-12419392/#comments</comments>
		<pubDate>Mon, 26 Mar 2012 10:25:59 +0000</pubDate>
		<dc:creator>Maycon Tomiasi</dc:creator>
				<category><![CDATA[Erros]]></category>
		<category><![CDATA[Instalação]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[12419392]]></category>
		<category><![CDATA[aplicação]]></category>
		<category><![CDATA[banco]]></category>
		<category><![CDATA[banco de dados]]></category>
		<category><![CDATA[base]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[dados]]></category>
		<category><![CDATA[data]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[erro]]></category>
		<category><![CDATA[OPatch failed with error code 73]]></category>
		<category><![CDATA[OPtach]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[oracle_home]]></category>
		<category><![CDATA[Patch]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2508</guid>
		<description><![CDATA[Este artigo tem como objetivo explicar o erro ocorrido &#8220;OPatch failed with error code 73&#8243; durante aplicação do Patch PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.0 e corrigir o mesmo. Estou usando um Banco de Dados Single Instance com ASM, ou seja, non-RAC. Segue os passos que foi realizado para aplicar o Patch [...]]]></description>
			<content:encoded><![CDATA[<p>Este artigo tem como objetivo explicar o erro ocorrido &#8220;OPatch failed with error code 73&#8243; durante aplicação do Patch PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.0 e corrigir o mesmo.<br />
Estou usando um Banco de Dados Single Instance com ASM, ou seja, non-RAC.</p>
<p>Segue os passos que foi realizado para aplicar o Patch 12419392 quando houve o erro.</p>
<p><span id="more-2508"></span><br />
Vamos acessar o diretório do Patch 12419392.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle ~]$ cd 12419392/
[oracle@serveroracle 12419392]$ ls -l
total 64
drwxr-xr-x 3 oracle oinstall  4096 May 19  2011 custom
drwxr-xr-x 4 oracle oinstall  4096 May 19  2011 etc
drwxr-xr-x 9 oracle oinstall  4096 May 19  2011 files
-rw-r--r-- 1 oracle oinstall  2872 May 18  2011 patchmd.xml
-rw-rw-r-- 1 oracle oinstall 42226 Jul 19  2011 README.html
-rw-rw-r-- 1 oracle oinstall    21 May 25  2011 README.txt
[oracle@serveroracle 12419392]$
</pre>
<p>Ao entrar no diretório do Patch, vamos aplicar o Patch.<br />
OBS: Para aplicar o Patch, deve-se certificar que todos os serviços do Banco de Dados esteja baixados (Listener, Banco de Dados, Enterprise Manager, ISQLPlus).<br />
OBS: Sempre faz backup do produto Oracle antes aplicar qualquer Patch da Oracle para voltar o mesmo caso a aplicação do Patch não ocorra com Sucesso.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ /oraprd01/app/oracle/product/10.2.0/db_1/OPatch/opatch apply
Invoking OPatch 10.2.0.4.9

Oracle Interim Patch Installer version 10.2.0.4.9
Copyright (c) 2009, Oracle Corporation.  All rights reserved.

Oracle Home       : /oraprd01/app/oracle/product/10.2.0/db_1
Central Inventory : /oraprd01/app/oracle/oraInventory
   from           : /etc/oraInst.loc
OPatch version    : 10.2.0.4.9
OUI version       : 10.2.0.5.0
OUI location      : /oraprd01/app/oracle/product/10.2.0/db_1/oui
Log file location : /oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/opatch/opatch2012-03-15_16-01-20PM.log

Patch history file: /oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/opatch/opatch_history.txt

ApplySession applying interim patch '12419392' to OH '/oraprd01/app/oracle/product/10.2.0/db_1'
ApplySession failed: ApplySession failed to prepare the system.

Patch 12419392 requires OPatch version 10.2.0.5.0.
The OPatch version being used (10.2.0.4.9) doesn't meet the minimum version required by the patch(es). Please download latest OPatch from My Oracle Support.

System intact, OPatch will not attempt to restore the system

OPatch failed with error code 73
[oracle@serveroracle 12419392]$
</pre>
<p>O erro acima ocorreu pois nossa versão do OPatch é uma versão antiga para a aplicação do Patch 12419392 PSU 10.2.0.5.4.<br />
Devemos acessar o Metalink (Suporte Oracle) e baixar o Patch do OPtach na versão mais nova.<br />
Estou usando Oracle Enterprise Linux 5.7 32 Bits, então devemos baixar o OPatch para este Sistema Operacional.<br />
Ao acessar o metalink procure pelo [ID 274526.1] e Baixe o Opatch para a versão do Banco de Dados que estás usando, no meu caso, Linux x86.</p>
<div id="attachment_2412" class="wp-caption alignnone" style="width: 310px"><a href="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Download_OPtach.png"><img src="http://www.oraclehome.com.br/wp-content/uploads/2012/03/Download_OPtach-300x252.png" alt="Download OPtach" width="300" height="252" class="size-medium wp-image-2412" /></a><p class="wp-caption-text">Download OPtach</p></div>
<p>Após realizar o Download do OPtach recente, faz uma copia para o servidor de Banco de Dados e descompacta o mesmo no ORACLE_HOME conforme abaixo:</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle ~]$ ls -l p6880880_102000_LINUX.zip
-rw-r--r-- 1 oracle oinstall 27412455 Mar 15 16:37 p6880880_102000_LINUX.zip
[oracle@serveroracle ~]$ cp -p p6880880_102000_LINUX.zip /oraprd01/app/oracle/product/10.2.0/db_1/
[oracle@serveroracle ~]$ cd /oraprd01/app/oracle/product/10.2.0/db_1/&lt;a href=&quot;http://www.oraclehome.com.br/wp-content/uploads/2012/03/Download_OPtach.png&quot;&gt;&lt;img src=&quot;http://www.oraclehome.com.br/wp-content/uploads/2012/03/Download_OPtach-300x252.png&quot; alt=&quot;Download OPtach&quot; title=&quot;Download OPtach&quot; width=&quot;300&quot; height=&quot;252&quot; class=&quot;size-medium wp-image-2412&quot; /&gt;&lt;/a&gt;
[oracle@serveroracle db_1]$ unzip p6880880_102000_LINUX.zip
Archive:  p6880880_102000_LINUX.zip
 extracting: OPatch/ocm/ocm.zip
  inflating: OPatch/ocm/lib/osdt_jce.jar
  inflating: OPatch/ocm/lib/osdt_core3.jar
  inflating: OPatch/ocm/lib/emocmclnt-14.jar
replace OPatch/ocm/lib/emocmutl.jar? [y]es, [n]o, [A]ll, [N]one, [r]ename: A
  inflating: OPatch/ocm/lib/emocmutl.jar
  inflating: OPatch/ocm/bin/emocmrsp
  inflating: OPatch/ocm/ocm_platforms.txt
  inflating: OPatch/crs/patch112.pl
  inflating: OPatch/crs/crsdelete.pm
  inflating: OPatch/crs/crspatch.pm
  inflating: OPatch/crs/s_crsconfig_defs
  inflating: OPatch/crs/crsconfig_lib.pm
  inflating: OPatch/crs/oracss.pm
  inflating: OPatch/crs/auto_patch.pl
  inflating: OPatch/crs/s_crsconfig_lib.pm
  inflating: OPatch/opatch
  inflating: OPatch/opatchprereqs/opatch/runtime_prereq.xml
  inflating: OPatch/opatchprereqs/opatch/opatch_prereq.xml
  inflating: OPatch/opatchprereqs/opatch/rulemap.xml
  inflating: OPatch/opatchprereqs/prerequisite.properties
  inflating: OPatch/opatchprereqs/oui/knowledgesrc.xml
  inflating: OPatch/opatch.ini
  inflating: OPatch/emdpatch.pl
  inflating: OPatch/opatch.pl
  inflating: OPatch/jlib/opatchprereq.jar
  inflating: OPatch/jlib/opatchactions.jar
  inflating: OPatch/jlib/opatchutil.jar
  inflating: OPatch/jlib/opatchfmw.jar
  inflating: OPatch/jlib/opatchext.jar
  inflating: OPatch/jlib/opatch.jar
  inflating: OPatch/opatch.bat
  inflating: OPatch/docs/Prereq_Users_Guide.txt
  inflating: OPatch/docs/FAQ
  inflating: OPatch/docs/Users_Guide.txt
  inflating: OPatch/README.txt
[oracle@serveroracle db_1]$
</pre>
<p>Após descompactar o OPatch recente para o ORACLE_HOME vamos checar a versão do OPatch.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle db_1]$ /oraprd01/app/oracle/product/10.2.0/db_1/OPatch/opatch version
Invoking OPatch 10.2.0.5.1

OPatch Version: 10.2.0.5.1

OPatch succeeded.
</pre>
<p>Conforme checado a versão do OPatch, o mesmo é 10.2.0.5.1 o que é recomendável para aplicar o Patch 12419392 para o Banco de Dados 10.2.0.5.<br />
Veja o artigo da Aplicação do Patch 12419392 acessando <a href="http://www.oraclehome.com.br/2012/03/23/aplicando-patch-psu-10-2-0-5-4-no-banco-de-dados-oracle-10-2-0-5-0-non-rac/" target="_blank">Aplicando Patch PSU 10.2.0.5.4 no Banco de Dados Oracle 10.2.0.5.0 non-RAC</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/03/26/erro-opatch-failed-with-error-code-73-durante-aplicacao-do-patch-12419392/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Aplicando Patch PSU 10.2.0.5.4 no Banco de Dados Oracle 10.2.0.5.0 non-RAC</title>
		<link>http://www.oraclehome.com.br/2012/03/23/aplicando-patch-psu-10-2-0-5-4-no-banco-de-dados-oracle-10-2-0-5-0-non-rac/</link>
		<comments>http://www.oraclehome.com.br/2012/03/23/aplicando-patch-psu-10-2-0-5-4-no-banco-de-dados-oracle-10-2-0-5-0-non-rac/#comments</comments>
		<pubDate>Fri, 23 Mar 2012 12:52:17 +0000</pubDate>
		<dc:creator>Maycon Tomiasi</dc:creator>
				<category><![CDATA[Alta disponibilidade]]></category>
		<category><![CDATA[Instalação]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Oracle Database]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[Segurança]]></category>
		<category><![CDATA[10.2.0.5]]></category>
		<category><![CDATA[10.2.0.5.4]]></category>
		<category><![CDATA[12419392]]></category>
		<category><![CDATA[aplicação]]></category>
		<category><![CDATA[asm]]></category>
		<category><![CDATA[banco]]></category>
		<category><![CDATA[banco de dados]]></category>
		<category><![CDATA[base]]></category>
		<category><![CDATA[configuração]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[dados]]></category>
		<category><![CDATA[data]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[download]]></category>
		<category><![CDATA[instance]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[metalink]]></category>
		<category><![CDATA[opatch]]></category>
		<category><![CDATA[oracle]]></category>
		<category><![CDATA[p6880880]]></category>
		<category><![CDATA[Patch]]></category>
		<category><![CDATA[psu]]></category>
		<category><![CDATA[RPM]]></category>
		<category><![CDATA[single]]></category>
		<category><![CDATA[versão]]></category>

		<guid isPermaLink="false">http://www.oraclehome.com.br/?p=2395</guid>
		<description><![CDATA[Este artigo tem como objetivo explicar como aplicar o Patch PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.0. Estou usando um Banco de Dados Single Instance com ASM, ou seja, non-RAC. Primeiramente devemos baixar o Patch 12419392. Estou usando Oracle Enterprise Linux 5.7 32 Bits, então devemos baixar o Patch para este Sistema Operacional. [...]]]></description>
			<content:encoded><![CDATA[<p>Este artigo tem como objetivo explicar como aplicar o Patch PSU 10.2.0.5.4 para o Banco de Dados Oracle 10.2.0.5.0.<br />
Estou usando um Banco de Dados Single Instance com ASM, ou seja, non-RAC.</p>
<p>Primeiramente devemos baixar o Patch 12419392. Estou usando Oracle Enterprise Linux 5.7 32 Bits, então devemos baixar o Patch para este Sistema Operacional.<br />
Para baixar o Patch terás que obter as o suporte da Oracle.<br />
Ao baixar o Patch copia o mesmo para o servidor de Banco de Dados e descompacta o mesmo com &#8220;unzip&#8221;.</p>
<p><span id="more-2395"></span><br />
Segue abaixo os passos para aplicar o Patch PSU 10.2.0.5.4.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle ~]$ cd 12419392/
[oracle@serveroracle 12419392]$ ls -l
total 64
drwxr-xr-x 3 oracle oinstall  4096 May 19  2011 custom
drwxr-xr-x 4 oracle oinstall  4096 May 19  2011 etc
drwxr-xr-x 9 oracle oinstall  4096 May 19  2011 files
-rw-r--r-- 1 oracle oinstall  2872 May 18  2011 patchmd.xml
-rw-rw-r-- 1 oracle oinstall 42226 Jul 19  2011 README.html
-rw-rw-r-- 1 oracle oinstall    21 May 25  2011 README.txt
[oracle@serveroracle 12419392]$
</pre>
<p>Ao entrar no diretório do Patch, vamos aplicar o Patch.<br />
OBS: Para aplicar o Patch, deve-se certificar que todos os serviços do Banco de Dados esteja baixados (Listener, Banco de Dados, Enterprise Manager, ISQLPlus).<br />
OBS: Sempre faz backup do produto Oracle antes aplicar qualquer Patch da Oracle para voltar o mesmo caso a aplicação do Patch não ocorra com Sucesso.</p>
<p>Vamos verificar se está faltando algum pacote do Linux para a aplicação do Patch.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ rpm -q binutils gcc glibc glibc-headers glibc-kernheaders glibc-devel compat-libstdc++ cpp compat-gcc make compat-db compat-gcc-c++ compat-libstdc++ compat-libstdc++-devel openmotif openmotif21 setarch pdksh libaio libaio-devel
binutils-2.17.50.0.6-14.el5
gcc-4.1.2-51.el5
glibc-2.5-65
glibc-headers-2.5-65
package glibc-kernheaders is not installed
glibc-devel-2.5-65
package compat-libstdc++ is not installed
cpp-4.1.2-51.el5
package compat-gcc is not installed
make-3.81-3.el5
compat-db-4.2.52-5.1
package compat-gcc-c++ is not installed
package compat-libstdc++ is not installed
package compat-libstdc++-devel is not installed
openmotif-2.3.1-5.el5_5.1
package openmotif21 is not installed
setarch-2.0-1.1
package pdksh is not installed
libaio-0.3.106-5
package libaio-devel is not installed
[oracle@serveroracle 12419392]$
</pre>
<p>Com o usuário &#8220;root&#8221; vamos instalar alguns pacotes do Linux que não estão instalados.<br />
OBS: Estes são pacotes complementais para instalação e gerenciamento dos aplicativos.</p>
<p>Em um outro terminal com o usuário &#8220;root&#8221; vamos instalar os pacotes do Linux.</p>
<pre class="brush: bash; title: ; notranslate">
[root@serveroracle Server]# ls -l  glibc-headers-*
-rw-r--r-- 1 root root 618371 Jun 14  2011 glibc-headers-2.5-65.i386.rpm
[root@serveroracle Server]# rpm -ivh glibc-headers-2.5-65.i386.rpm
warning: glibc-headers-2.5-65.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
        package glibc-headers-2.5-65.i386 is already installed
[root@serveroracle Server]# ls -l glibc-devel-2.5-65*
-rw-r--r-- 1 root root 2143738 Jun 14  2011 glibc-devel-2.5-65.i386.rpm
[root@serveroracle Server]# rpm -ivh glibc-devel-2.5-65.i386.rpm
warning: glibc-devel-2.5-65.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
        package glibc-devel-2.5-65.i386 is already installed
[root@serveroracle Server]# ls -l cpp-4.1.2-51.el5*
-rw-r--r-- 1 root root 2779549 Jun 14  2011 cpp-4.1.2-51.el5.i386.rpm
[root@serveroracle Server]# rpm -ivh cpp-4.1.2-51.el5.i386.rpm
warning: cpp-4.1.2-51.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
        package cpp-4.1.2-51.el5.i386 is already installed
[root@serveroracle Server]# ls -l compat-gcc*
-rw-r--r-- 1 root root  4217682 Nov 17  2010 compat-gcc-34-3.4.6-4.1.i386.rpm
-rw-r--r-- 1 root root 11392445 Nov 17  2010 compat-gcc-34-c++-3.4.6-4.1.i386.rpm
-rw-r--r-- 1 root root  2171879 Nov 17  2010 compat-gcc-34-g77-3.4.6-4.1.i386.rpm
[root@serveroracle Server]# rpm -ivh compat-gcc-34-c++-3.4.6-4.1.i386.rpm
warning: compat-gcc-34-c++-3.4.6-4.1.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
        package compat-gcc-34-c++-3.4.6-4.1.i386 is already installed
[root@serveroracle Server]# ls -l make-3.81-3.el5*
-rw-r--r-- 1 root root 477805 Nov 17  2010 make-3.81-3.el5.i386.rpm
[root@serveroracle Server]# rpm -ivh make-3.81-3.el5.i386.rpm
warning: make-3.81-3.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
        package make-3.81-3.el5.i386 is already installed
        file /usr/bin/make from install of make-3.81-3.el5.i386 conflicts with file from package make-3.81-3.el5.i386
[root@serveroracle Server]# ls -l compat-libstdc++*
-rw-r--r-- 1 root root  92219 Nov 17  2010 compat-libstdc++-296-2.96-138.i386.rpm
-rw-r--r-- 1 root root 237144 Nov 17  2010 compat-libstdc++-33-3.2.3-61.i386.rpm
[root@serveroracle Server]# rpm -ivh compat-libstdc++-33-3.2.3-61.i386.rpm
warning: compat-libstdc++-33-3.2.3-61.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
        package compat-libstdc++-33-3.2.3-61.i386 is already installed
        file /usr/lib/libstdc++.so.5.0.7 from install of compat-libstdc++-33-3.2.3-61.i386 conflicts with file from package compat-libstdc++-33-3.2.3-61.i386
[root@serveroracle Server]# rpm -ivh compat-libstdc++-296-2.96-138.i386.rpm
warning: compat-libstdc++-296-2.96-138.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
        package compat-libstdc++-296-2.96-138.i386 is already installed
        file /usr/lib/libstdc++-3-libc6.2-2-2.10.0.so from install of compat-libstdc++-296-2.96-138.i386 conflicts with file from package compat-libstdc++-296-2.96-138.i386
[root@serveroracle Server]# ls -l openmotif*
-rw-r--r-- 1 root root 1374499 Nov 17  2010 openmotif22-2.2.3-18.i386.rpm
-rw-r--r-- 1 root root 1610158 Nov  3  2010 openmotif-2.3.1-5.el5_5.1.i386.rpm
-rw-r--r-- 1 root root 3102338 Nov  3  2010 openmotif-devel-2.3.1-5.el5_5.1.i386.rpm
[root@serveroracle Server]# rpm -ivh openmotif22-2.2.3-18.i386.rpm
warning: openmotif22-2.2.3-18.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
   1:openmotif22            ########################################### [100%]
[root@serveroracle Server]# ls -l pdksh*
-rw-r--r-- 1 root root 203568 Nov 17  2010 pdksh-5.2.14-36.el5.i386.rpm
[root@serveroracle Server]# rpm -ivh pdksh-5.2.14-36.el5.i386.rpm
warning: pdksh-5.2.14-36.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
   1:pdksh                  ########################################### [100%]
[root@serveroracle Server]# ls -l libaio-devel*
-rw-r--r-- 1 root root 11790 Nov 17  2010 libaio-devel-0.3.106-5.i386.rpm
[root@serveroracle Server]# rpm -ivh libaio-devel-0.3.106-5.i386.rpm
warning: libaio-devel-0.3.106-5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing...                ########################################### [100%]
   1:libaio-devel           ########################################### [100%]
[root@serveroracle Server]#
</pre>
<p>Vamos aplicar o Patch 12419392.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ /oraprd01/app/oracle/product/10.2.0/db_1/OPatch/opatch apply
Invoking OPatch 10.2.0.5.1

Oracle Interim Patch Installer version 10.2.0.5.1
Copyright (c) 2010, Oracle Corporation.  All rights reserved.

Oracle Home       : /oraprd01/app/oracle/product/10.2.0/db_1
Central Inventory : /oraprd01/app/oracle/oraInventory
   from           : /etc/oraInst.loc
OPatch version    : 10.2.0.5.1
OUI version       : 10.2.0.5.0
OUI location      : /oraprd01/app/oracle/product/10.2.0/db_1/oui
Log file location : /oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/opatch/opatch2012-03-15_17-44-00PM.log

Patch history file: /oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/opatch/opatch_history.txt

ApplySession applying interim patch '12419392' to OH '/oraprd01/app/oracle/product/10.2.0/db_1'
Interim patch 12419392 is a superset of the patch(es) [  12419392 ] in the Oracle Home
OPatch will rollback the subset patches and apply the given patch.

Running prerequisite checks...
Patch 12419392: Optional component(s) missing : [ oracle.rdbms.dv, 10.2.0.5.0 ] , [ oracle.rdbms.dv.oc4j, 10.2.0.5.0 ]
Provide your email address to be informed of security issues, install and
initiate Oracle Configuration Manager. Easier for you if you use your My
Oracle Support Email address/User Name.
Visit http://www.oracle.com/support/policies.html for details.
Email address/User Name:

You have not provided an email address for notification of security issues.
Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]:  y

OPatch detected non-cluster Oracle Home from the inventory and will patch the local system only.

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/oraprd01/app/oracle/product/10.2.0/db_1')

Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files and inventory (not for auto-rollback) for the Oracle Home
Backing up files affected by the patch '12419392' for restore. This might take a while...
Backing up files affected by the patch '12419392' for restore. This might take a while...
ApplySession rolling back interim patch '12419392' from OH '/oraprd01/app/oracle/product/10.2.0/db_1'
Execution of 'sh /oraprd01/app/oracle/product/10.2.0/db_1/.patch_storage/12419392_May_25_2011_01_06_08/original_patch/custom/scripts/pre -rollback 12419392 ':

Return Code = 0

Patching component oracle.rdbms, 10.2.0.5.0...
Updating archive file &quot;/oraprd01/app/oracle/product/10.2.0/db_1/lib/libserver10.a&quot;  with &quot;lib/libserver10.a/kcbl.o&quot;
.
.
.
Patching component oracle.rdbms.rman, 10.2.0.5.0...
Running make for target ioracle
Running make for target iwrap
Running make for target client_sharedlib
Running make for target proc
Running make for target irman
Running make for target client_sharedlib
ApplySession adding interim patch '12419392' to inventory

Verifying the update...
Inventory check OK: Patch ID 12419392 is registered in Oracle Home inventory with proper meta-data.
Files check OK: Files from Patch ID 12419392 are present in Oracle Home.

The local system has been patched and can be restarted.

--------------------------------------------------------------------------------
The following warnings have occurred during OPatch execution:
1) OUI-67620:Interim patch 12419392 is a superset of the patch(es) [  12419392 ] in the Oracle Home
--------------------------------------------------------------------------------
OPatch Session completed with warnings.

OPatch completed with warnings.
[oracle@serveroracle 12419392]$
</pre>
<p>Após o Patch Aplicado vamos continuar o processo de aplicação no Banco de Dados. Vamos subir os serviços do Banco de Dados.<br />
Subindo o Listener.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ lsnrctl start

LSNRCTL for Linux: Version 10.2.0.5.0 - Production on 15-MAR-2012 17:52:43

Copyright (c) 1991, 2010, Oracle.  All rights reserved.

Starting /oraprd01/app/oracle/product/10.2.0/db_1/bin/tnslsnr: please wait...

TNSLSNR for Linux: Version 10.2.0.5.0 - Production
System parameter file is /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
Log messages written to /oraprd01/app/oracle/product/10.2.0/db_1/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.56.104)(PORT=1521)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.56.104)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 10.2.0.5.0 - Production
Start Date                15-MAR-2012 17:52:43
Uptime                    0 days 0 hr. 0 min. 0 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /oraprd01/app/oracle/product/10.2.0/db_1/network/admin/listener.ora
Listener Log File         /oraprd01/app/oracle/product/10.2.0/db_1/network/log/listener.log
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.56.104)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))
Services Summary...
Service &quot;PLSExtProc&quot; has 1 instance(s).
  Instance &quot;PLSExtProc&quot;, status UNKNOWN, has 1 handler(s) for this service...
Service &quot;dbprod&quot; has 1 instance(s).
  Instance &quot;dbprod&quot;, status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully
[oracle@serveroracle 12419392]$
</pre>
<p>Vamos subir a Instância ASM.</p>
<pre class="brush: bash; title: ; notranslate">
[oracle@serveroracle 12419392]$ export ORACLE_SID=+ASM
[oracle@serveroracle 12419392]$ sqlplus sys/***** as sysdba

SQL*Plus: Release 10.2.0.5.0 - Production on Thu Mar 15 17:55:10 2012

Copyright (c) 1982, 2010, Oracle.  All Rights Reserved.

Connected to an idle instance.

SQL&gt; startup mount
ASM instance started

Total System Global Area   83886080 bytes
Fixed Size                  1272120 bytes
Variable Size              57448136 bytes
ASM Cache                  25165824 bytes
ASM diskgroups mounted
SQL&gt; exit
Disconnected from Oracle Database 10g Release 10.2.0.5.0 - Production
[oracle@serveroracle 12419392]$ export ORACLE_SID=dbprod
[oracle@serveroracle 12419392]$ sqlplus sys/***** as sysdba

SQL*Plus: Release 10.2.0.5.0 - Production on Thu Mar 15 17:55:57 2012

Copyright (c) 1982, 2010, Oracle.  All Rights Reserved.

Connected to an idle instance.

SQL&gt; startup
ORACLE instance started.

Total System Global Area 1073741824 bytes
Fixed Size                  1277824 bytes
Variable Size             541065344 bytes
Database Buffers          524288000 bytes
Redo Buffers                7110656 bytes
Database mounted.
Database opened.
SQL&gt;
</pre>
<p>Com o Banco de Dados aberto, vamos continuar a aplicar o Patch no Banco de Dados.</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; @$ORACLE_HOME/rdbms/admin/catbundle.sql psu apply

PL/SQL procedure successfully completed.

PL/SQL procedure successfully completed.

Generating apply and rollback scripts...
Check the following file for errors:
/oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/catbundle/catbundle_PSU_DBPROD_GENERATE_2012Mar15_18_12_45.log
Apply script: /oraprd01/app/oracle/product/10.2.0/db_1/rdbms/admin/catbundle_PSU_DBPROD_APPLY.sql
Rollback script: /oraprd01/app/oracle/product/10.2.0/db_1/rdbms/admin/catbundle_PSU_DBPROD_ROLLBACK.sql

PL/SQL procedure successfully completed.

Executing script file...

SQL&gt; COLUMN spool_file NEW_VALUE spool_file NOPRINT
SQL&gt; SELECT '/oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/catbundle/' || 'catbundle_PSU_' || name || '_APPLY_' || TO_CHAR(SYSDATE, 'YYYYMonDD_hh24_mi_ss', 'NLS_DATE_LANGUAGE=''AMERICAN''') || '.log' AS spool_file FROM v$database;

SQL&gt; SPOOL &amp;spool_file
SQL&gt; exec dbms_registry.set_session_namespace('SERVER')

PL/SQL procedure successfully completed.

SQL&gt; PROMPT Processing Oracle Enterprise Manager...
Processing Oracle Enterprise Manager...
SQL&gt; ALTER SESSION SET current_schema = SYSMAN;

Session altered.

SQL&gt; @?/sysman/admin/emdrep/sql/core/latest/ecm/ecm_util_pkgdef.sql
.
.
.
SQL&gt; SET TERMOUT on
SQL&gt; SET ECHO off

PL/SQL procedure successfully completed.

PL/SQL procedure successfully completed.

PL/SQL procedure successfully completed.

PL/SQL procedure successfully completed.

Session altered.

Updating registry...

1 row created.

Commit complete.

Check the following log file for errors:
/oraprd01/app/oracle/product/10.2.0/db_1/cfgtoollogs/catbundle/catbundle_PSU_DBPROD_APPLY_2012Mar15_18_12_46.log
SQL&gt;
</pre>
<p>Após rodar o &#8220;catbundle.sql&#8221; vamos rodar o &#8220;utlrp.sql&#8221; para recompilar os objetos.</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; @$ORACLE_HOME/rdbms/admin/utlrp.sql

TIMESTAMP
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
COMP_TIMESTAMP UTLRP_BGN  2012-03-15 18:20:24

DOC&gt;   The following PL/SQL block invokes UTL_RECOMP to recompile invalid
DOC&gt;   objects in the database. Recompilation time is proportional to the
DOC&gt;   number of invalid objects in the database, so this command may take
DOC&gt;   a long time to execute on a database with a large number of invalid
DOC&gt;   objects.
DOC&gt;
DOC&gt;   Use the following queries to track recompilation progress:
DOC&gt;
DOC&gt;   1. Query returning the number of invalid objects remaining. This
DOC&gt;      number should decrease with time.
DOC&gt;         SELECT COUNT(*) FROM obj$ WHERE status IN (4, 5, 6);
DOC&gt;
DOC&gt;   2. Query returning the number of objects compiled so far. This number
DOC&gt;      should increase with time.
DOC&gt;         SELECT COUNT(*) FROM UTL_RECOMP_COMPILED;
DOC&gt;
DOC&gt;   This script automatically chooses serial or parallel recompilation
DOC&gt;   based on the number of CPUs available (parameter cpu_count) multiplied
DOC&gt;   by the number of threads per CPU (parameter parallel_threads_per_cpu).
DOC&gt;   On RAC, this number is added across all RAC nodes.
DOC&gt;
DOC&gt;   UTL_RECOMP uses DBMS_SCHEDULER to create jobs for parallel
DOC&gt;   recompilation. Jobs are created without instance affinity so that they
DOC&gt;   can migrate across RAC nodes. Use the following queries to verify
DOC&gt;   whether UTL_RECOMP jobs are being created and run correctly:
DOC&gt;
DOC&gt;   1. Query showing jobs created by UTL_RECOMP
DOC&gt;         SELECT job_name FROM dba_scheduler_jobs
DOC&gt;            WHERE job_name like 'UTL_RECOMP_SLAVE_%';
DOC&gt;
DOC&gt;   2. Query showing UTL_RECOMP jobs that are running
DOC&gt;         SELECT job_name FROM dba_scheduler_running_jobs
DOC&gt;            WHERE job_name like 'UTL_RECOMP_SLAVE_%';
DOC&gt;#

PL/SQL procedure successfully completed.

TIMESTAMP
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
COMP_TIMESTAMP UTLRP_END  2012-03-15 18:20:30

PL/SQL procedure successfully completed.

DOC&gt; The following query reports the number of objects that have compiled
DOC&gt; with errors (objects that compile with errors have status set to 3 in
DOC&gt; obj$). If the number is higher than expected, please examine the error
DOC&gt; messages reported with each object (using SHOW ERRORS) to see if they
DOC&gt; point to system misconfiguration or resource constraints that must be
DOC&gt; fixed before attempting to recompile these objects.
DOC&gt;#

OBJECTS WITH ERRORS
-------------------
                  0

DOC&gt; The following query reports the number of errors caught during
DOC&gt; recompilation. If this number is non-zero, please query the error
DOC&gt; messages in the table UTL_RECOMP_ERRORS to see if any of these errors
DOC&gt; are due to misconfiguration or resource constraints that must be
DOC&gt; fixed before objects can compile successfully.
DOC&gt;#

ERRORS DURING RECOMPILATION
---------------------------
                          0

PL/SQL procedure successfully completed.

SQL&gt;
</pre>
<p>Vamos verificar se aplicamos o Patch PSU corretamente.</p>
<pre class="brush: sql; title: ; notranslate">
SQL&gt; col COMMENTS for a30
SQL&gt; select ACTION, NAMESPACE, VERSION, BUNDLE_SERIES, COMMENTS from dba_registry_history;

ACTION                         NAMESPACE                      VERSION                        BUNDLE_SERIES                  COMMENTS
------------------------------ ------------------------------ ------------------------------ ------------------------------ ------------------------------
APPLY                          SERVER                         10.2.0.5                       PSU                            PSU 10.2.0.5.4

SQL&gt;
</pre>
<p>Conforme informações no DBA_REGISTRY_HISTORY podemos concluir que aplicamos o Patch corretamente.<br />
Mais informações sobre aplicação do Patch acompanhar o arquivo README que vem junto no pacote do Patch 12419392.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.oraclehome.com.br/2012/03/23/aplicando-patch-psu-10-2-0-5-4-no-banco-de-dados-oracle-10-2-0-5-0-non-rac/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

