Upgrade

Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 4

SQL> SELECT * FROM v$timezone_file;

FILENAME
VERSION
-------------------- ---------timezlrg_4.dat
4
GRS0240818
$ ls -lrt
total 8
drwxr-s--drwxr-s---

2 HBOLAPU1 dba
2 HBOLAPU1 dba

4096 Mar 27 2011 upgrade_11.2.0.1


256 Jun 11 18:00 GRS0240818

/data/oracle/HBOLAPU1/admin/UPGRADES
SELECT name,description from SYS.V$PARAMETER WHERE name
LIKE '\_%' ESCAPE '\'

SQL> set feedback on


set verify on
select sys_nc_oid$ from kottd$ where sys_nc_oid$ not in (select oid$ from obj$ w
here type#=13); SQL> SQL>
no rows selected
SQL> delete from kottd$ where sys_nc_oid$ not in
(select oid$ from obj$ where type#=13); 2
0 rows deleted.
SQL> purge dba_recyclebin;
DBA Recyclebin purged.
PL/SQL procedure successfully completed.
COMP_TIMESTAMP UTLRP_END 2012-06-11 18:19:58
1 row selected.
DOC> The following query reports the number of objects that have compiled
DOC> with errors (objects that compile with errors have status set to 3 in
DOC> obj$). If the number is higher than expected, please examine the error
DOC> messages reported with each object (using SHOW ERRORS) to see if they
DOC> point to system misconfiguration or resource constraints that must be
DOC> fixed before attempting to recompile these objects.
DOC>#
18
1 row selected.
DOC>
DOC>
DOC>
DOC>
DOC>

The following query reports the number of errors caught during


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

DOC>#
5
1 row selected.
PL/SQL procedure successfully completed.
PL/SQL procedure successfully completed.
SPOOL PRE_UPGRADE_DB_LINKS.log
SELECT 'CREATE '||DECODE(U.NAME,'PUBLIC','public ')||'DATABASE LINK '||CHR(10)
||DECODE(U.NAME,'PUBLIC',Null, 'SYS','',U.NAME||'.')|| L.NAME||chr(10)
||'CONNECT TO ' || L.USERID || ' IDENTIFIED BY "'||L.PASSWORD||'" USING '''||L.H
OST||''''
||chr(10)||';' TEXT
FROM SYS.LINK$ L, SYS.USER$ U
WHERE L.OWNER# = U.USER#;
SPOOL OFF
SQL> select TZ_VERSION from registry$database;
4
1 row selected.

SQL> spool TimeZone_Info.log


SQL> set serveroutput on
SQL> @utltzuv2.sql
Query sys.sys_tzuv2_temptab and sys.sys_tzuv2_va_temptab tables to see if any TI
MESTAMP WITH TIME ZO
NE data are affected when upgrading from the current time zone version 4 to a ne
wer version of 11.
PL/SQL procedure successfully completed.
SQL> spool off
SQL> EXEC DBMS_STATS.GATHER_DICTIONARY_STATS;
PL/SQL procedure successfully completed.

set verify off


set space 0 line 120 pages 1000
set heading off
set feedback off
spool analyze.sql
SELECT 'Analyze cluster "'||cluster_name||'" validate structure cascade;'
FROM dba_clusters
WHERE owner='SYS'
UNION
SELECT 'Analyze table "'||table_name||'" validate structure cascade;'
FROM dba_tables

WHERE owner='SYS'
AND partitioned='NO'
AND (iot_type='IOT' OR iot_type is NULL)
UNION
SELECT 'Analyze table "'||table_name||'" validate structure cascade into invalid
_rows;'
FROM dba_tables
WHERE owner='SYS'
AND partitioned='YES';
spool off
set verify on
set heading on
set feedback on
set echo on
@$ORACLE_HOME/rdbms/admin/utlvalid.sql
SQL> SELECT distinct(trunc(last_refresh))
FROM dba_snapshot_refresh_times; 2
(TRUNC(LA
--------24-MAY-10
31-AUG-10
08-JUL-04
02-SEP-11
15-APR-10
09-MAR-12
10-NOV-11
04-MAR-05
26-AUG-09
13-APR-10
10-APR-12
11-JUN-12
24-NOV-10
02-MAR-12
14-NOV-11
21-APR-10
27-MAR-12
17-JUL-08
08-JUN-11
20-MAR-12
25-AUG-09
10-JAN-12
09-JUL-10
08-NOV-11
11-NOV-11
20-AUG-09
21-APR-04
03-MAR-12
13-MAR-09
15-NOV-11
30 rows selected.
SQL> SELECT * FROM v$recover_file;

no rows selected
SQL> SELECT * FROM v$backup WHERE status!='NOT ACTIVE';
no rows selected
SQL> select * from dba_2pc_pending;
no rows selected
USERNAME
-----------------------------SYSTEM
SYS

DEFAULT_TABLESPACE
-----------------------------SYSTEM
SYSTEM

SQL>
SQL> SELECT name FROM v$controlfile;
NAME
-------------------------------------------------------------------------------/data/oracle/HBOLAPU1/redo01/control01.ctl
/data/oracle/HBOLAPU1/redo02/control02.ctl

sqlplus "/ as sysdba" <<EOF


set echo on
spool upgrade.log
@?/rdbms/admin/catupgrd.sql
spool off
exit;
EOF

You might also like