当前位置:Gxlcms >
数据库问题 >
Database time zone version is 18. It is older than current release time zone version 26
Database time zone version is 18. It is older than current release time zone version 26
时间:2021-07-01 10:21:17
帮助过:10人阅读
oracle@raca1 12.2.0]$ sqlplus
/ as sysdba
SQL*Plus: Release
12.2.
0.1.
0 Production
on Tue Apr
18 16:
15:
07 2017
Copyright (c) 1982,
2016, Oracle.
All rights reserved.
Connected to:
Oracle Database 12c Enterprise Edition Release
12.2.
0.1.
0 - 64
bit Production
SQL> set serveroutput
on
SQL> SELECT PROPERTY_NAME, SUBSTR(property_value,
1,
30) value
2 FROM DATABASE_PROPERTIES
3 WHERE PROPERTY_NAME
LIKE ‘DST_%‘
4 ORDER BY PROPERTY_NAME;
PROPERTY_NAME VALUE
--------------------------------------------------------------------------------
DST_PRIMARY_TT_VERSION
18
DST_SECONDARY_TT_VERSION 0
DST_UPGRADE_STATE NONE
SQL> purge dba_recyclebin;
DBA Recyclebin purged.
SQL> TRUNCATE TABLE SYS.DST$TRIGGER_TABLE;
Table truncated.
SQL> TRUNCATE TABLE sys.dst$affected_tables;
Table truncated.
SQL> TRUNCATE TABLE sys.dst$error_table;
Table truncated.
SQL> EXEC DBMS_APPLICATION_INFO.SET_CLIENT_INFO(
‘upg_tzv‘)
PL/SQL
procedure successfully completed.
SQL> alter session
set "_with_subquery"
=materialize;
Session altered.
SQL> alter session
set "_simple_view_merging"
=TRUE;
Session altered.
SQL> EXEC DBMS_DST.BEGIN_UPGRADE(
26);
BEGIN DBMS_DST.BEGIN_UPGRADE(
26);
END;
*
ERROR at line 1:
ORA-56926:
database must be
in UPGRADE mode
in order to start an upgrade window
ORA-06512: at "SYS.DBMS_SYS_ERROR", line
79
ORA-06512: at "SYS.DBMS_DST", line
1241
ORA-06512: at line
1
SQL> quit
Disconnected from Oracle
Database 12c Enterprise Edition Release
12.2.
0.1.
0 - 64
bit Production
[oracle@raca1 12.2.0]$ sqlplus
/ as sysdba
SQL*Plus: Release
12.2.
0.1.
0 Production
on Tue Apr
18 16:
24:
19 2017
Copyright (c) 1982,
2016, Oracle.
All rights reserved.
Connected to:
Oracle Database 12c Enterprise Edition Release
12.2.
0.1.
0 - 64
bit Production
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup mount
ORACLE instance started.
Total System Global Area 7.8920E
+10 bytes
Fixed Size 12169704 bytes
Variable Size 7516196376 bytes
Database Buffers
4.5366E
+10 bytes
Redo Buffers 256262144 bytes
In-Memory Area
2.5770E
+10 bytes
Database mounted.
SQL> alter database open upgrade;
Database altered.
SQL> EXEC DBMS_DST.BEGIN_UPGRADE(
26);
PL/SQL
procedure successfully completed.
SQL> SELECT * FROM sys.dst$error_table;
no rows selected
SQL> SELECT PROPERTY_NAME, SUBSTR(property_value,
1,
30) value
2 FROM DATABASE_PROPERTIES
3 WHERE PROPERTY_NAME
LIKE ‘DST_%‘
4 ORDER BY PROPERTY_NAME;
PROPERTY_NAME VALUE
-------------------------------------
DST_PRIMARY_TT_VERSION
26
DST_SECONDARY_TT_VERSION 18
DST_UPGRADE_STATE UPGRADE
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.
Total System Global Area 7.8920E
+10 bytes
Fixed Size 12169704 bytes
Variable Size 7516196376 bytes
Database Buffers
4.5366E
+10 bytes
Redo Buffers 256262144 bytes
In-Memory Area
2.5770E
+10 bytes
Database mounted.
Database opened.
SQL> SELECT OWNER, TABLE_NAME, UPGRADE_IN_PROGRESS
FROM ALL_TSTZ_TABLES
where UPGRADE_IN_PROGRESS
=‘YES‘;
OWNER TABLE_NAME UPG
------------------------- ----------------------------------- ---
GSMADMIN_INTERNAL AQ$_CHANGE_LOG_QUEUE_TABLE_S YES
APEX_040200 WWV_FLOW_DEBUG_MESSAGES2 YES
APEX_040200 WWV_FLOW_WORKSHEET_NOTIFY YES
APEX_040200 WWV_FLOW_FEEDBACK_FOLLOWUP YES
APEX_050000 WWV_FLOW_WORKSHEET_NOTIFY YES
IX AQ$_ORDERS_QUEUETABLE_S YES
IX AQ$_ORDERS_QUEUETABLE_L YES
GSMADMIN_INTERNAL AQ$_CHANGE_LOG_QUEUE_TABLE_L YES
APEX_050000 WWV_FLOW_FEEDBACK_FOLLOWUP YES
APEX_050000 WWV_FLOW_DEBUG_MESSAGES YES
IX AQ$_STREAMS_QUEUE_TABLE_L YES
APEX_040200 WWV_FLOW_DEBUG_MESSAGES YES
APEX_050000 WWV_FLOW_FEEDBACK YES
IX AQ$_STREAMS_QUEUE_TABLE_S YES
APEX_040200 WWV_FLOW_FEEDBACK YES
APEX_050000 WWV_FLOW_DEBUG_MESSAGES2 YES
SQL> alter session
set "_with_subquery"
=materialize;
Session altered.
SQL> alter session
set "_simple_view_merging"
=TRUE;
Session altered.
SQL> set serveroutput
on
SQL> VAR numfail
number
SQL> BEGIN
2 DBMS_DST.UPGRADE_DATABASE(:numfail,
3 parallel
=> TRUE,
4 log_errors
=> TRUE,
5 log_errors_table
=> ‘SYS.DST$ERROR_TABLE‘,
6 log_triggers_table
=> ‘SYS.DST$TRIGGER_TABLE‘,
7 error_on_overlap_time
=> FALSE,
8 error_on_nonexisting_time
=> FALSE);
9 DBMS_OUTPUT.PUT_LINE(
‘Failures:‘|| :numfail);
10 END;
11 /
Table list: "APEX_040200"."WWV_FLOW_FEEDBACK"
Number of failures:
0
Table list: "APEX_040200"."WWV_FLOW_DEBUG_MESSAGES2"
Number of failures:
0
Table list: "IX"."AQ$_STREAMS_QUEUE_TABLE_S"
Number of failures:
0
Table list: "IX"."AQ$_ORDERS_QUEUETABLE_S"
Number of failures:
0
Table list: "GSMADMIN_INTERNAL"."AQ$_CHANGE_LOG_QUEUE_TABLE_S"
Number of failures:
0
Table list: "APEX_040200"."WWV_FLOW_WORKSHEET_NOTIFY"
Number of failures:
0
Table list: "APEX_050000"."WWV_FLOW_WORKSHEET_NOTIFY"
Number of failures:
0
Table list: "APEX_050000"."WWV_FLOW_DEBUG_MESSAGES"
Number of failures:
0
Table list: "APEX_050000"."WWV_FLOW_DEBUG_MESSAGES2"
Number of failures:
0
Table list: "APEX_040200"."WWV_FLOW_DEBUG_MESSAGES"
Number of failures:
0
Table list: "APEX_040200"."WWV_FLOW_FEEDBACK_FOLLOWUP"
Number of failures:
0
Table list: "APEX_050000"."WWV_FLOW_FEEDBACK"
Number of failures:
0
Table list: "APEX_050000"."WWV_FLOW_FEEDBACK_FOLLOWUP"
Number of failures:
0
Table list: "IX"."AQ$_ORDERS_QUEUETABLE_L"
Number of failures:
0
Table list: "IX"."AQ$_STREAMS_QUEUE_TABLE_L"
Number of failures:
0
Table list: "GSMADMIN_INTERNAL"."AQ$_CHANGE_LOG_QUEUE_TABLE_L"
Number of failures:
0
Failures:0
PL/SQL
procedure successfully completed.
SQL> SELECT * FROM sys.dst$error_table;
no rows selected
SQL> VAR fail
number
SQL> BEGIN
2 DBMS_DST.END_UPGRADE(:fail);
3 DBMS_OUTPUT.PUT_LINE(
‘Failures:‘|| :fail);
4 END;
5 /
An upgrade window has been successfully ended.
Failures:0
PL/SQL
procedure successfully completed.
SQL> SELECT PROPERTY_NAME, SUBSTR(property_value,
1,
30) value
2 FROM DATABASE_PROPERTIES
3 WHERE PROPERTY_NAME
LIKE ‘DST_%‘
4 ORDER BY PROPERTY_NAME;
PROPERTY_NAME VALUE
--------------------------------------------------------------------------------
DST_PRIMARY_TT_VERSION
26
DST_SECONDARY_TT_VERSION 0
DST_UPGRADE_STATE NONE
SQL> SELECT * FROM v$timezone_file;
FILENAME VERSION CON_ID
-------------------- ---------- ----------
timezlrg_26.dat
26 0
Database time zone version is 18. It is older than current release time zone version 26
标签:connected ase ogr sel filename _id nbsp run selected