Wednesday 27 February 2019

Oracle Database: Open Wallet Automatically After Starting The Database.

create one trigger which will open the wallet automatically immediately after database opened:


CREATE or replace TRIGGER OPEN_WALLET
AFTER STARTUP ON DATABASE
BEGIN
execute immediate ‘ALTER SYSTEM SET ENCRYPTION WALLET OPEN identified by “xxxxx”’;
END;
/

Tuesday 26 February 2019

Oracle Database 18c: Check latest applied patches queyr DBA_REGISTRY_SQLPATCH

Check latest applied patches queyr DBA_REGISTRY_SQLPATCH



Upgrading oracle 18.4 to 18.5 opatchauto: Prerequisite check "CheckApplicable" failed

Issue:
[Feb 27, 2019 10:13:52 AM] [INFO]   Patch 28864593:
                                    Copy Action: Source File "/oracle/PATCHES/28828717/28864593/files/bin/ocrcheck.bin" does not exists or is not readable
                                    'oracle.has.crs, 18.0.0.0.0': Cannot copy file from 'ocrcheck.bin' to '/grid/app/18.3/bin/ocrcheck.bin'
                                    Copy Action: Source File "/oracle/PATCHES/28828717/28864593/files/bin/ocrconfig.bin" does not exists or is not readable
                                    'oracle.has.crs, 18.0.0.0.0': Cannot copy file from 'ocrconfig.bin' to '/grid/app/18.3/bin/ocrconfig.bin'
[Feb 27, 2019 10:13:52 AM] [INFO]   Prerequisite check "CheckApplicable" failed.
                                    The details are:


Solution:
Owner of the patch file should be grid home owner, extract the patch with grid user or change file ownership to the user.

Upgrading oracle 18.4 to 18.5 Prerequisite check "CheckActiveFilesAndExecutables" failed.

I faced this issue: 
Following executables are active : libclntsh.so.18.1
                                    /oracle/app/product/18.3/lib/libclntsh.so.18.1
                                    /oracle/app/product/18.3/lib/libsqlplus.so
[Feb 26, 2019 2:47:28 PM] [SEVERE]  OUI-67073:UtilSession failed: Prerequisite check "CheckActiveFilesAndExecutables" failed.



                                  The details are:


                                    Following executables are active :
                                    /grid/app/18.3/lib/libclntsh.so.18.1
                                    /grid/app/18.3/lib/libasmclntsh18.so
                                    /grid/app/18.3/lib/libskgxp18.so
                                    /grid/app/18.3/bin/oracle


Solution:
1- Stop the oracle emagent.
2- Stop the CRS using "crsctl stop crs -f"
3- Re-run the patch using opatchauto resume


Friday 15 February 2019

Convert from VirtualBox to VmWare Workstation




Convert from VirtualBox to VmWare Workstation



Export the ova from virtualbox

Open virtualbox, make sure guest you want to export is not running.
Highlight guest, file--> Export Appliance
Select OVF 1.0 and check 'Write Manifest'

rename the file to .zip or .rar and extartct it.




Convert the vmdk file(s):
Open a cmd prompt and navigate into your vmware folder to find the vmware-vdiskmanager.exe
In my case it was in 'c:\program files (x86)\vmware\vmware workstation' folder.
use the vdiskmanager.exe utility to convert the existing vmdk file(s) to a format that vmware likes better...


run this:
vmware-vdiskmanager -r "c:\OVF\Oracle DB Developer VM-disk001.vmdk" -t 2 c:\OVF\VM-disk0001.vmdk
vmware-vdiskmanager -r "c:\OVF\Oracle DB Developer VM-disk002.vmdk" -t 2 c:\OVF\VM-disk0002.vmdk
vmware-vdiskmanager -r "c:\OVF\Oracle DB Developer VM-disk003.vmdk" -t 2 c:\OVF\VM-disk0003.vmdk


Where sourcedisk is in the extracted ova from virtualbox and targetdisk is the location of where you want the export to happen.
I used the same filename for source and target, not sure if this matters or not.
I did get a warning each time I did this but it did not cause any problems for me.
VixDiskLib: Invalid configuration file parameter.  Failed to read configuration file.


After converting the disk:

Create a new virtual machine, advanced and use existing hard disk
point to the converted disk(I selected the larger vmdk file, not the 'flat' version that was 1k)
Make that disk SATA instead of SCSI(SCSI caused bluescreen when it tries to boot in my scenario).
Select 'Convert' rather than 'Keep existing format'


Now launch the VmWare Workstation and start up your image...

Number of Visitors