Skip to main content

AUDIT VAULT add extra data to EVENTDATA using vm disk

 




check lsblk


on root 


[root@oracle19ctest ~]# lsblk

NAME        MAJ:MIN RM  SIZE RO TYPE MOUNTPOINTS

sda           8:0    0   60G  0 disk

├─sda1        8:1    0    1G  0 part /boot

└─sda2        8:2    0   59G  0 part

  ├─ol-root 252:0    0 39.6G  0 lvm  /

  └─ol-home 252:1    0 19.4G  0 lvm  /home

sdb           8:16   0   20G  0 disk

└─sdb1        8:17   0   20G  0 part

sdc           8:32   0   20G  0 disk

└─sdc1        8:33   0   20G  0 part

sdd           8:48   0   20G  0 disk

└─sdd1        8:49   0   20G  0 part

sr0          11:0    1 1024M  0 rom

[root@oracle19ctest ~]#


/sbin/parted /dev/sdb


(parted) mklabel gpt

(parted) print


Model: ATA VBOX HARDDISK (scsi)

Disk /dev/sdb: 107GB

Sector size (logical/physical): 512B/512B

Partition Table: gpt


Number Start End Size File system Name Flags


(parted)


---


(parted) mkpart primary ext3

Start? 0GB

End? 35GB

(parted)


print - to print the current configuration.


quit 


/usr/sbin/oracleasm createdisk -v EVENTDATA2 /dev/sdb1

Disk "EVENTDATA2" does not exist or is not instantiated

Writing disk header: done

Instantiating disk: done


go to su - grid 


login to sqlasm


sqlplus / as sysasm


set lin 300

select GROUP_NUMBER,NAME,TOTAL_MB,FREE_MB from V$ASM_DISKGROUP;


example data: 


GROUP_NUMBER NAME        TOTAL_MB FREE_MB

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

1            EVENTDATA   63718    62557

2            RECOVERY    95597    91924

3            SYSTEMDATA  63734    60577


check ASM_DISK allocation


column MOUNT_STATUS format a12

column HEADER_STATUS format a12

column MODE_STATUS format a10

column STATE format a10

column TOTAL_MB format 999999

column FREE_MB format 999999

column NAME format a20

column PATH format a40

column LABEL format a10

set linesize 250


SELECT MOUNT_STATUS,HEADER_STATUS,MODE_STATUS,STATE,TOTAL_MB,FREE_MB,NAME,PATH,LABEL FROM V$ASM_DISK;


MOUNT_STAT HEADER_STATUS  MODE_STATUS   STATE   TOTAL_MB FREE_MB  NAME             PATH                             LABEL

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

CLOSED     PROVISIONED    ONLINE        NORMAL  0        0                         /dev/oracleasm/disks/RECOVERY2

CLOSED     PROVISIONED    ONLINE        NORMAL  0        0                         /dev/oracleasm/disks/SYSTEMDATA2

CLOSED     PROVISIONED    ONLINE        NORMAL  0        0                         /dev/oracleasm/disks/EVENTDATA2

CACHED     MEMBER         ONLINE        NORMAL  63734    60577    SYSTEMDATA_0000  /dev/oracleasm/disks/SYSTEMDATA1

CACHED     MEMBER         ONLINE        NORMAL  63718    62557    EVENTDATA_0000   /dev/oracleasm/disks/EVENTDATA1

CACHED     MEMBER         ONLINE        NORMAL  95597    91924    RECOVERY_0000    /dev/oracleasm/disks/RECOVERY1

6 rows selected.


--- add EVENTDATA to ASM ---


SQL> ALTER DISKGROUP EVENTDATA add disk 'ORCL:EVENTDATA2';

Diskgroup altered.


check again if its added. 


SQL> select GROUP_NUMBER,NAME,TOTAL_MB,FREE_MB from V$ASM_DISKGROUP;


GROUP_NUMBER NAME       TOTAL_MB FREE_MB

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

1            EVENTDATA  97096    95933

2            RECOVERY   131239   127564

3            SYSTEMDATA 97112    93953

Comments

Popular posts from this blog

Warning: long redo log write elapsed times detected, the LG* process tracefiles have more details

Warning: long redo log write elapsed times detected, the LG* process tracefiles have more details This warning means LGWR / LGnn background processes are taking too long to write redo to the online redo logs. It is usually related to one of these: - Slow storage / high I/O latency on redo log disks - Redo logs placed on busy disks together with datafiles, FRA, archive logs, backups, or OS files - Too many commits from the application, causing frequent LGWR flushes - Redo log size too small, causing frequent log switches - CPU scheduling issue, where LGWR is not getting CPU quickly - Data Guard synchronous transport delay, if using SYNC/AFFIRM - In newer 19c RU versions, especially around 19.28, this warning can appear more visibly because of diagnostic changes, so first confirm whether there is a real performance impact before changing anything. - Oracle’s own wait-event documentation says log file sync is the foreground wait for redo write confirmation after commit, and log file paral...

Convert TIMESTAMP to SCN and SCN to TIMESTAMP in Oracle

  Convert TIMESTAMP to SCN and SCN to TIMESTAMP in Oracle In many recovery scenario we need to know our SCN and timestamps. We can convert this by using the following function SCN_TO_TIMESTAMP TIMESTAMP_TO_SCN We can use this function with help of dual functions. Example of using this function as follows: 1. Convert the SCN to Timestamp SQL> select scn_to_timestamp(2011955) from dual; SCN_TO_TIMESTAMP(2011955) ----------------------------------------------------- 05-SEP-18 12.46.20.000000000 PM 2. Convert the Timestamp to SCN SQL> select timestamp_to_scn(to_timestamp('05-09-2018 12:46:21','dd-mm-yyyy hh24:mi:ss')) scn from dual; SCN ---------- 2011955

How To Enable Flash Recovery Area In Oracle Database

  The flash recovery area(FRA) is an Oracle-managed destination( either FILE SYSTEM or ASM ) for centralized backup and recovery files. It simplifies the backup management. The following recovery-related files are stored in the flash recovery area: — Current control file — Online redo logs — Archived redo logs — Flashback logs — Control file auto backups — Datafile and control file copies — Backup pieces — Foreign archived redo log Below are the steps for enabling  flash  recovery area. DB_RECOVERY_FILE_DEST_SIZE   and  DB_RECOVERY_FILE_DEST   initial parameters are required for enabling FRA. DB_RECOVERY_FILE_DEST_SIZE   -> It is the disk quota size for the flash recovery area. DB_RECOVERY_FILE_DEST   – > This initialization parameter is a valid destination for the Flash Recovery Area. It can be a directory, file system, or ASM disk group. NOTE  : DB_RECOVERY_FILE_DEST_SIZE must be set before DB_RECOVERY_FILE_DEST. 1. Check whether FRA ...