ORA-16006

ORA-16006: audit_trail destination incompatible with database open mode


SQL> ALTER DATABASE OPEN READ ONLY;
ALTER DATABASE OPEN READ ONLY
*
ERROR at line 1:
ORA-16006audit_trail destination incompatible with database open mode 


SQL> SHOW PARAMETER AUDIT_TRAIL

============================
audit_trail                   string           DB

Here need to change Audit_trail parameter DB to none.
SQL> ALTER SYSTEM SET audit_trail=none SCOPE=SPFILE;
System altered.

SQL> SHUTDOWN IMMEDIATE
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> STARTUP MOUNT
ORACLE instance started.
Database mounted.
SQL> ALTER DATABASE OPEN READ ONLY;
Database altered.

How to Enable & Disable a scheduled job in Oracle 11gr2


Here we are using package Name is (DBMS_SCHEDULER)


How to disable jobs

SQL> exec dbms_scheduler.disable(‘GATHER_STATS_JOB’);

PL/SQL procedure successfully completed.

How to check job status

SQL> select job_name, enabled from DBA_SCHEDULER_JOBS WHERE job_name = ‘GATHER_STATS_JOB’;

JOB_NAME ENABL
————————- —–
GATHER_STATS_JOB FALSE

How to Enable jobs

SQL> exec dbms_scheduler.enable(‘GATHER_STATS_JOB’);

PL/SQL procedure successfully completed.

How to check job status
SQL> select job_name, enabled from DBA_SCHEDULER_JOBS WHERE job_name = 'GATHER_STATS_JOB’;

JOB_NAME ENABL
————————- —–
GATHER_STATS_JOB TRUE

purchase order line locked by another user please requery and try again

In this case may be more than a user sharing the same session and updating the data,



Solution:-

1. Find Table lock.
login with apps and fire below commend 

SQL> select
   c.owner,
   c.object_name,
   c.object_type,
   b.sid,
   b.serial#,
   b.status,
   b.osuser,
   b.machine
from
   v$locked_object a ,
   v$session b,
   dba_objects c
where
   b.sid = a.session_id
and
   a.object_id = c.object_id;

OWNER                          OBJECT_NAME                           OBJECT_TYPE                                  SID    SERIAL# STATUS      OSUSER                  MACHINE
------------------------------ ------------------------------------- ------------------------------------- ---------- ---------- --------    ------------------------------ ----------------------------------------------------------------
APPLSYS                        FND_CONCURRENT_REQUESTS               TABLE                                         11         21 INACTIVE    applmgr                    sujeet.oracle.com
INV                            MTL_MWB_GTMP2                         TABLE                                        318      124               applmgr                   sujeet.oracle.com

SQL> SELECT B.Owner, B.Object_Name, A.Oracle_Username, A.OS_User_Name
FROM V$Locked_Object A, All_Objects B
WHERE A.Object_ID = B.Object_ID  2    3
  4  ;

OWNER                          OBJECT_NAME                           ORACLE_USERNAME OS_USER_NAME
------------------------------ ------------------------------------- --------------- ---------------
INV                            MTL_MWB_GTMP2                         APPS            applmgr
APPLSYS                        FND_CONCURRENT_REQUESTS               APPS            applmgr

2. After find table lock release it...

User below commend to release table lock.
 Here SID-11, Serial no-21.


SQL> alter system kill session '11,21';

System altered.

Retest issue. I hope issue resolve.


ORA-00059: Maximum Number Of DB_FILES Exceeded in 19C database

When I am adding datafile to my 19C database facing the below error. SQL> alter tablespace DATA  add datafile '/u01/data/data15.dbf&#...