Swamped by audit files
Seeing massive numbers of .aud files on many of the server I am working on.
Uwe has beaten me to it :
https://uhesse.com/2015/07/24/audit_sys_operations-defaults-to-true-in-oracle-12c/
Many of the audit files relate to the dbms_stats job. Wondering if there is a way to somehow filter what oracle decides to audit; seems to be all or nothing.
Going to investigate purging using the link below, rather than manually deleting the files at the o/s level.
https://aprakash.wordpress.com/2012/01/20/use-dbms_audit_mgmt-for-purging-audit-files-at-os-level/
See also :
https://www.durham.computer/search?q=clearing
Cloning a pluggable database
Not going to reinvent the wheel, all the information you need here :
https://oracle-base.com/articles/12c/multitenant-hot-clone-remote-pdb-or-non-cdb-12cr2
Some quick notes:
34 MDS5FA1 READ WRITE NO
39 MDS5FA1_20190626 MOUNTED
47 MDS5FA1_2JUN019 MOUNTED
Session altered.
34 MDS5FA1 READ WRITE NO
34 MDS5FA1 MOUNTED
39 MDS5FA1_20190626 MOUNTED
47 MDS5FA1_2JUN2019 MOUNTED
-- Use read only so no worries about date changes.
https://oracle-base.com/articles/12c/multitenant-hot-clone-remote-pdb-or-non-cdb-12cr2
Some quick notes:
SQL>
select con_id, name, open_mode, RESTRICTED from v$pdbs where NAME like
'MDS5FA%';
CON_ID NAME
OPEN_MODE RES
----------
------------------------------ ---------- ---34 MDS5FA1 READ WRITE NO
39 MDS5FA1_20190626 MOUNTED
47 MDS5FA1_2JUN019 MOUNTED
SQL>
alter session set container = MDS5FA1;
Session altered.
SQL>
show pdbs;
CON_ID
CON_NAME OPEN MODE RESTRICTED
----------
------------------------------ ---------- ----------34 MDS5FA1 READ WRITE NO
SQL>
shutdown immediate;
Pluggable
Database closed.
SQL>
alter session set container = CDB$ROOT;
Session
altered.
SQL>
select con_id, name, open_mode, RESTRICTED from v$pdbs where NAME like
'MDS5FA%';
CON_ID NAME
OPEN_MODE RES
----------
------------------------------ ---------- ---34 MDS5FA1 MOUNTED
39 MDS5FA1_20190626 MOUNTED
47 MDS5FA1_2JUN2019 MOUNTED
-- Use read only so no worries about date changes.
SQL>
alter pluggable database MDS5FA1 open read only force;
Pluggable
database altered.
SQL>
create pluggable database MDS5FA1_10JUN2019 from MDS5FA1;
RAC Crib Sheet
Some
quick notes on RAC cluster commands.
Also see: http://www.dba-oracle.com/real_application_clusters_rac_grid/srvctl.htm
prsodb01:
CRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online
**************************************************************
prsodb02:
CRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online
**************************************************************
Name Target State Server State details
-------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA.dg
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
ora.FRA.dg
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
ora.LISTENER.lsnr
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
ora.asm
ONLINE ONLINE prsodb01 Started,STABLE
ONLINE ONLINE prsodb02 Started,STABLE
ora.net1.network
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
ora.ons
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
--------------------------------------------------------------------------------
ora.LISTENER_SCAN1.lsnr
1 ONLINE ONLINE prsodb01 STABLE
ora.prsodb01.vip
1 ONLINE ONLINE prsodb01 STABLE
ora.prsodb02.vip
1 ONLINE ONLINE prsodb02 STABLE
ora.cvu
1 ONLINE ONLINE prsodb02 STABLE
ora.oc4j
1 OFFLINE OFFLINE STABLE
ora.patches.db
1 OFFLINE OFFLINE Instance Shutdown,ST
ABLE
2 OFFLINE OFFLINE Instance Shutdown,ST
ABLE
ora.preprod.db
1 ONLINE ONLINE prsodb01 Open,STABLE
2 ONLINE ONLINE prsodb02 Open,STABLE
ora.preprod.preprod_lmsstp.scc.local.svc
1 ONLINE ONLINE prsodb01 STABLE
2 ONLINE ONLINE prsodb02 STABLE
ora.rpap_gdc2.db
1 OFFLINE OFFLINE Instance Shutdown,ST
ABLE
2 OFFLINE OFFLINE Instance Shutdown,ST
ABLE
ora.scan1.vip
1 ONLINE ONLINE prsodb01 STABLE
ora.sit.db
1 ONLINE ONLINE prsodb01 Open,STABLE
2 ONLINE OFFLINE STABLE
ora.sit.osmm.scc.local.svc
1 ONLINE ONLINE prsodb01 STABLE
--------------------------------------------------------------------------------
STATE=ONLINE
NAME=prsodb02
STATE=ONLINE
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online
CRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online
[oracle@PRSODB01 ~]$ srvctl status database -db SIT
Instance sit1 is running on node prsodb01
Instance sit2 is not running on node prsodb02
Instance preprod2 is running on node prsodb02
Subnet IPv4: 192.168.98.0/255.255.255.192/eth0, static
Subnet IPv6:
VIP exists: network number 1, hosting node prsodb01
VIP Name: prsodb01-vip.scc.local
VIP IPv4 Address: 192.168.98.31
VIP IPv6 Address:
VIP exists: network number 1, hosting node prsodb02
VIP Name: prsodb02-vip.scc.local
VIP IPv4 Address: 192.168.98.32
VIP IPv6 Address:
ONS exists: Local port 6100, remote port 6200, EM port 2016
Network: 1, Owner: grid
Home:
End points: TCP:1800
Password file: +DATA/orapwASM
ASM listener: LISTENER
[oracle@PRSODB01 ~]$ srvctl –help
Also see: http://www.dba-oracle.com/real_application_clusters_rac_grid/srvctl.htm
[grid@PRSODB01 ~]$ crsctl check
cluster -all
**************************************************************prsodb01:
CRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online
**************************************************************
prsodb02:
CRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online
**************************************************************
Example of RAC Cluster |
[grid@PRSODB01 ~]$ crsctl status
resource -t
--------------------------------------------------------------------------------Name Target State Server State details
-------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA.dg
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
ora.FRA.dg
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
ora.LISTENER.lsnr
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
ora.asm
ONLINE ONLINE prsodb01 Started,STABLE
ONLINE ONLINE prsodb02 Started,STABLE
ora.net1.network
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
ora.ons
ONLINE ONLINE prsodb01 STABLE
ONLINE ONLINE prsodb02 STABLE
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------ora.LISTENER_SCAN1.lsnr
1 ONLINE ONLINE prsodb01 STABLE
ora.prsodb01.vip
1 ONLINE ONLINE prsodb01 STABLE
ora.prsodb02.vip
1 ONLINE ONLINE prsodb02 STABLE
ora.cvu
1 ONLINE ONLINE prsodb02 STABLE
ora.oc4j
1 OFFLINE OFFLINE STABLE
ora.patches.db
1 OFFLINE OFFLINE Instance Shutdown,ST
ABLE
2 OFFLINE OFFLINE Instance Shutdown,ST
ABLE
ora.preprod.db
1 ONLINE ONLINE prsodb01 Open,STABLE
2 ONLINE ONLINE prsodb02 Open,STABLE
ora.preprod.preprod_lmsstp.scc.local.svc
1 ONLINE ONLINE prsodb01 STABLE
2 ONLINE ONLINE prsodb02 STABLE
ora.rpap_gdc2.db
1 OFFLINE OFFLINE Instance Shutdown,ST
ABLE
2 OFFLINE OFFLINE Instance Shutdown,ST
ABLE
ora.scan1.vip
1 ONLINE ONLINE prsodb01 STABLE
ora.sit.db
1 ONLINE ONLINE prsodb01 Open,STABLE
2 ONLINE OFFLINE STABLE
ora.sit.osmm.scc.local.svc
1 ONLINE ONLINE prsodb01 STABLE
--------------------------------------------------------------------------------
[grid@PRSODB01 ~]$ crsctl status
server
NAME=prsodb01STATE=ONLINE
NAME=prsodb02
STATE=ONLINE
[grid@PRSODB01 ~]$ crsctl check
cluster
CRS-4537: Cluster Ready Services is onlineCRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online
[grid@PRSODB01 ~]$ crsctl check
crs
CRS-4638: Oracle High Availability Services is onlineCRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online
[grid@PRSODB01 ~]$ crsctl query
crs softwareversion
Oracle Clusterware version on node [prsodb01] is [12.1.0.1.0][oracle@PRSODB01 ~]$ srvctl status database -db SIT
Instance sit1 is running on node prsodb01
Instance sit2 is not running on node prsodb02
[oracle@PRSODB01 ~]$ srvctl status
database -db PREPROD
Instance preprod1 is running on node prsodb01Instance preprod2 is running on node prsodb02
[oracle@PRSODB01 ~]$ srvctl config
nodeapps
Network 1 existsSubnet IPv4: 192.168.98.0/255.255.255.192/eth0, static
Subnet IPv6:
VIP exists: network number 1, hosting node prsodb01
VIP Name: prsodb01-vip.scc.local
VIP IPv4 Address: 192.168.98.31
VIP IPv6 Address:
VIP exists: network number 1, hosting node prsodb02
VIP Name: prsodb02-vip.scc.local
VIP IPv4 Address: 192.168.98.32
VIP IPv6 Address:
ONS exists: Local port 6100, remote port 6200, EM port 2016
[oracle@PRSODB01 ~]$ srvctl config
listener
Name: LISTENERNetwork: 1, Owner: grid
Home:
End points: TCP:1800
[oracle@PRSODB01 ~]$ srvctl config
asm
ASM home: /u01/app/12.1.0.1/gridPassword file: +DATA/orapwASM
ASM listener: LISTENER
[oracle@PRSODB01 ~]$ srvctl status
asm
ASM is running on prsodb01,prsodb02[oracle@PRSODB01 ~]$ srvctl –help
-output removed for brevity but for reference included the command.
Check RAC
related service status.
srvctl
status -d DATABASE_UNIQUE_NAME
srvctl
status nodeapps
srvctl
status diskgroup -g DISKGROUP_NAME -a
srvctl
status listener
srvctl
status asm
Use config option can
configure the related service. However, if we don’t provide any parameters, it
would show the detail for the service.
srvctl config -d DATABASE_UNIQUE_NAME
srvctl
config nodeapps
srvctl
config listener
srvctl config asm
crsctl
status resource -t
crsctl
status server
crsctl
check cluster
crsctl
check crs
crsctl
query css votedisk
crsctl
querry crs activeversion
crsctl
query crs releaseversion
crsctl
query crs softwareversion
Read more at :
Subscribe to:
Posts (Atom)