Monday, January 26, 2009

oraenv and LD_LIBRARY_PATH


Environment: UNIX
After using oraenv to set the Oracle environment variables, you get the following error when creating a database by running scripts:
create or replace java system
begin if initjvmaux.startstep('CREATE_JAVA_SYSTEM') then
*
ERROR at line 1:
ORA-29516: Aurora assertion failure: Assertion failure at eox.c:317
Uncaught exception Root of all Java exceptions: java.lang.UnsatisfiedLinkError
oracle.aurora.rdbms.Schema.lookupNumber
ORA-06512: at "SYS.INITJVMAUX", line 23
ORA-06512: at line 5
A probable reason is that you hit a bug in oraenv: oraenv sets ORACLE_HOME and ORACLE_SID, but does not set the LD_LIBRARY_PATH.
The solution is to add the following to oraenv file before “Put new ORACLE_HOME in path ...”:
case "$LD_LIBRARY_PATH" in
*$OLDHOME/lib*) LD_LIBRARY_PATH=`echo $LD_LIBRARY_PATH | \
sed "s;$OLDHOME/lib;$ORACLE_HOME/lib;g"` ;;
*$ORACLE_HOME/lib*) ;;
"") LD_LIBRARY_PATH=$ORACLE_HOME/lib ;;
*) LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH ;;
esac
export LD_LIBRARY_PATH


More Oracle DBA tips, please visit Oracle DBA Tips  

Thursday, January 22, 2009

ORA-01516

Thank you for visiting Spatial DBA - Oracle and ArcSDE.

Please visit Oracle DBA Tips (http://www.oracledbatips.com) for more Oracle DBA Tips.

====================================================================






ORA-01516: nonexistent log file, datafile, or tempfile "string"
Cause: An attempt was made to use ALTER DATABASE to rename a log file, datafile, or tempfile; or to change attributes of a datafile or tempfile (e.g., resize, autoextend, online/offline, etc.); or to re-create a datafile. The attempt failed because the specified file is not known to the database 's control file or is not of a type supported by the request.
Action: Specify the name or number of an existing file of the correct type, as appropriate. Check the relevant V$ table for a list of possible files.
alert.log:
Thu Jan 22 07:14:33 2009
alter database datafile '/u01/oracle_data/mydb/temp01.dbf' resize 1000M
Thu Jan 22 07:14:33 2009
ORA-1516 signalled during:
alter database datafile '/u01/oracle_data/mydb/temp01.dbf' resize 1000M
...
Solution:
Use correct syntax:
SQL>alter database tempfile '/u01/oracle_data/mydb/temp01.dbf ' resize 100M;
All Oracle errors in the blog can be found at: Oracle errors
All ESRI ArcSDE errors in the blog can found at: ArcSDE Errors
Last updated: August 4, 2009

Tuesday, January 20, 2009

V$DELETED_OBJECT

V$DELETED_OBJECT displays information about deleted archived logs, datafile copies and backup pieces from the control file. The only purpose of this view is to optimize the recovery catalog resync operation. When an archived log, datafile copy, or backup piece is deleted, the corresponding record is marked deleted.

Column

Datatype

Description

RECID

NUMBER

Deleted object record ID

STAMP

NUMBER

Deleted object record stamp

TYPE

VARCHAR2(26)

Identifies the type of deleted object:

  • ARCHIVED LOG
  • BACKUP PIECE
  • DATAFILE COPY
  • PROXY COPY
  • BACKUP PIECE AVAILABLE
  • BACKUP PIECE EXPIRED
  • PROXY COPY AVAILABLE
  • PROXY COPY EXPIRED
  • BACKUP PIECE UNAVAILABLE
  • PROXY COPY UNAVAILABLE
  • DATAFILE COPY AVAILABLE
  • DATAFILE COPY EXPIRED
  • DATAFILE COPY UNAVAILABLE
  • ARCHIVED LOG AVAILABLE
  • ARCHIVED LOG EXPIRED
  • ARCHIVED LOG UNAVAILABLE
  • BACKUP SET KEEP OPTIONS
  • BACKUP SET KEEP UNTIL
  • PROXY COPY KEEP OPTIONS
  • PROXY COPY KEEP UNTIL
  • DATAFILE COPY KEEP OPTIONS
  • DATAFILE COPY KEEP UNTIL
  • DATAFILE RENAME ON RESTORE

OBJECT_RECID

NUMBER

Record ID of the deleted object

OBJECT_STAMP

NUMBER

Record timestamp of the deleted object

OBJECT_DATA

NUMBER

Displays additional internal information related to this deleted object. For internal Oracle use only.

SET_STAMP

NUMBER

Set stamp of the deleted object

SET_COUNT

NUMBER

Set count of the deleted object

Note:

1. There is a bug in 10.2.0.4 and 11.1.0.6 that RMAN resync takes long time when v$deleted_object contains too many rows. The bug will be resolved in 10.2.0.5 (server patch set), 11.1.0.7 (server patch set) and 11.2.

Oracle data dictionary views

Oracle dynamic performance views

V$DBFILE

V$DBFILE displays all datafiles making up the database. This view is retained for historical compatibility. Use of V$DATAFILE is recommended instead.

Column

Datatype

Description

FILE#

NUMBER

File identifier

NAME

VARCHAR2(513)

Name of the file

Note:

SQL> select * from V$DBFILE;

FILE# NAME

---------- ------------------------------------------------------------

1 /u02/oracle_data/mydb/system01.dbf

2 /u02/oracle_data/mydb/undotbs01.dbf

3 /u02/oracle_data/mydb/undotbs02.dbf

4 /u02/oracle_data/mydb/cwmlite01.dbf

5 /u02/oracle_data/mydb/drsys01.dbf

6 /u02/oracle_data/mydb/odm01.dbf

7 /u02/oracle_data/mydb/tools01.dbf

8 /u02/oracle_data/mydb/users01.dbf

9 /u02/oracle_data/mydb/xdb01.dbf

10 /u02/oracle_data/mydb/prod_anal01.dbf

11 /u02/oracle_data/mydb/atlas01.dbf

Oracle data dictionary views

Oracle dynamic performance views

Monday, January 19, 2009

V$OBSOLETE_PARAMETER

V$OBSOLETE_PARAMETER displays information about obsolete initialization parameters. If any row of the view contains TRUE in the ISSPECIFIED column, then you should examine why.

Column

Datatype

Description

NAME

VARCHAR2(64)

Name of the parameter

ISSPECIFIED

VARCHAR2(5)

Indicates whether the parameter was specified in the parameter file (TRUE) or not (FALSE)

Note:

1. Obsolete parameters in Oracle 10gR2:

SQL> select NAME from V$OBSOLETE_PARAMETER order by NAME;

NAME

----------------------------------------------------------------

_average_dirties_half_life

_compatible_no_recovery

_db_no_mount_lock

_kspptbl_mem_usage

_lm_direct_sends

_lm_multiple_receivers

_lm_statistics

_oracle_trace_events

_oracle_trace_facility_version

_plsql_conditional_compilation

_seq_process_cache_const

allow_partial_sn_results

always_anti_join

always_semi_join

arch_io_slaves

b_tree_bitmap_plans

backup_disk_io_slaves

cache_size_threshold

cleanup_rollback_entries

close_cached_open_cursors

complex_view_merging

db_block_checkpoint_batch

db_block_lru_extended_statistics

db_block_lru_latches

db_block_lru_statistics

db_block_max_dirty_target

db_file_simultaneous_writes

dblink_encrypt_login

delayed_logging_block_cleanouts

discrete_transactions_enabled

distributed_recovery_connection_hold_time

distributed_transactions

enqueue_resources

fast_full_scan_enabled

freeze_DB_for_fast_instance_recovery

gc_defer_time

gc_latches

gc_lck_procs

gc_releasable_locks

gc_rollback_locks

hash_join_enabled

hash_multiblock_io_count

instance_nodeset

job_queue_interval

job_queue_keep_connections

large_pool_min_alloc

lgwr_io_slaves

lm_locks

lm_procs

lm_procs

lm_ress

lock_sga_areas

log_block_checksum

log_files

log_parallelism

log_simultaneous_copies

log_small_entry_max_size

max_rollback_segments

max_transaction_branches

mts_circuits

mts_dispatchers

mts_listener_address

mts_max_dispatchers

mts_max_servers

mts_multiple_listeners

mts_servers

mts_service

mts_sessions

ogms_home

ops_admin_group

ops_interconnects

optimizer_max_permutations

optimizer_percent_parallel

optimizer_search_limit

oracle_trace_collection_name

oracle_trace_collection_path

oracle_trace_collection_size

oracle_trace_enable

oracle_trace_facility_name

oracle_trace_facility_path

parallel_broadcast_enabled

parallel_default_max_instances

parallel_min_message_pool

parallel_server_idle_time

parallel_transaction_resource_timeout

partition_view_enabled

plsql_native_c_compiler

plsql_native_linker

plsql_native_make_file_name

plsql_native_make_utility

push_join_predicate

row_cache_cursors

row_locking

sequence_cache_entries

sequence_cache_hash_buckets

serializable

shared_pool_reserved_min_alloc

snapshot_refresh_interval

snapshot_refresh_keep_connections

snapshot_refresh_processes

sort_direct_writes

sort_multiblock_read_count

sort_read_fac

sort_spacemap_size

sort_write_buffer_size

sort_write_buffers

spin_count

standby_preserves_names

temporary_table_locks

text_enable

transaction_auditing

undo_suppress_errors

use_ism

113 rows selected.

2. ORA-32004 is usually related obsolete and/or deprecated parameters when attempting to start a database: ORA-32004: obsolete and/or deprecated parameter(s) specified. The parameter initialization file should be checked to see that none of the specified parameters match a parameter name stored in the V$OBSOLETE_PARAMETER view of that same database.

Oracle data dictionary views

Oracle dynamic performance views