Thursday, December 29, 2016

WegLogic 12c silent installation on SUN Solaris


WebLogic 12c(12.1.3) on Solaris SPARC 64 bit fails with the error below:


java -jar fmw_12.1.3.0.0_wls.jar -silent -responseFile wls.rsp
Launcher log file is /var/tmp/OraInstall2016-12-29_10-33-15AM/launcher2016-12-29_10-33-15AM.log.
Extracting files...............................
Starting Oracle Universal Installer

Checking if CPU speed is above 300 MHz.   Actual 1415 MHz    Passed
Checking swap space: must be greater than 512 MB.   Actual 17934 MB    Passed
Checking if this platform requires a 64-bit JVM.   Actual 64    Passed
Checking temp space: must be greater than 300 MB.   Actual 56261 MB    Passed

Preparing to launch the Oracle Universal Installer from /var/tmp/OraInstall2016-12-29_10-33-15AM
Log: /var/tmp/OraInstall2016-12-29_10-33-15AM/install2016-12-29_10-33-15AM.log
Copyright (c) 1996, 2014, Oracle and/or its affiliates. All rights reserved.
Reading response file..
Starting check : CertifiedVersions
Expected result: One of 5.10,5.11
Actual Result: 5.10
Check complete. The overall result of this check is: Passed
CertifiedVersions Check: Success.
Starting check : CheckJDKVersion
Expected result: 1.7.0_15
Actual Result: 1.7.0_79
Check complete. The overall result of this check is: Passed
CheckJDKVersion Check: Success.
Validations are enabled for this session.
Verifying data......
[VALIDATION] [ERROR]:INST-07546: Unable to find install type Fusion Middleware Infrastructure
[VALIDATION] [SUGGESTION]:Provide a valid install type
installation Failed. Exiting installation due to data validation failure.



Solution:

Changed  "INSTALL_TYPE" parameter in response file.
< INSTALL_TYPE=Fusion Middleware Infrastructure
---
> INSTALL_TYPE=WebLogic Server

 




Launcher log file is /var/tmp/OraInstall2016-12-29_11-14-20AM/launcher2016-12-29_11-14-20AM.log.
Extracting files...............................
Starting Oracle Universal Installer

Checking if CPU speed is above 300 MHz.   Actual 1415 MHz    Passed
Checking swap space: must be greater than 512 MB.   Actual 17923 MB    Passed
Checking if this platform requires a 64-bit JVM.   Actual 64    Passed
Checking temp space: must be greater than 300 MB.   Actual 55245 MB    Passed


Preparing to launch the Oracle Universal Installer from /var/tmp/OraInstall2016-12-29_11-14-20AM
Log: /var/tmp/OraInstall2016-12-29_11-14-20AM/install2016-12-29_11-14-20AM.log
Copyright (c) 1996, 2014, Oracle and/or its affiliates. All rights reserved.
Reading response file..
Starting check : CertifiedVersions
Expected result: One of 5.10,5.11
Actual Result: 5.10
Check complete. The overall result of this check is: Passed
CertifiedVersions Check: Success.
Starting check : CheckJDKVersion
Expected result: 1.7.0_15
Actual Result: 1.7.0_79
Check complete. The overall result of this check is: Passed
CheckJDKVersion Check: Success.
Validations are enabled for this session.
Verifying data......
Copying Files...
You can find the log of this install session at:
 /var/tmp/OraInstall2016-12-29_11-14-20AM/install2016-12-29_11-14-20AM.log
-----------20%----------40%----------60%----------80%--------100%

The installation of Oracle Fusion Middleware 12c WebLogic Server and Coherence 12.1.3.0.0 completed successfully.
Logs successfully copied to /var/opt/oracle/oraInventory/logs.

 



source:
http://www.kernelbytes.com/silent-mode-installation-weblogic12c/
https://docs.oracle.com/middleware/1213/core/OUIRF/toc.htm


Wednesday, December 28, 2016

RMAN Technical Reference

RMAN backup, delete, reporting, charting, compression, encryption, authentication, such as crosschek control that I created a technical reference for quick access. I want to share with you. I will be updating this document periodically. I tried to classify the commands in RMAN to recover under the general headings. Hope to be useful.
Backup Reporting Operations
Backup need report:
RMAN>report need backup;
Obsolete backup report:
RMAN>report obsolete;
Back-up Operations
Backing Up whole database:
RMAN>backup database;
or
RMAN> backup incremental level 0 database;
Backing Up whole database with archive log files:
RMAN>backup database plus archivelog;
Backing Up Controlfile :
RMAN>backup as copy current controlfıle;
Backing Up whole database with archive log files and deleting arhived log files:
RMAN>backup database plus archivelog delete input;
Backing Up a Tablespace:
RMAN>backup as backupset
format '/backup/df_%d_%s.bck'
tablespace users;
Backing Up a datafile:
RMAN>backup datafile 5;
Backing Up changed blocks (Differential Incremental Backup):
RMAN> backup incremental level 1 database;
Backing Up all blocks after last full backup (Cumulative Incremental Backup):
RMAN>backup incremental level 1 cumulative database;
Image Copy Backup:
RMAN>backup as copy database;
Backup Deletion Operations
Deleting a backup by sequence number:
RMAN>delete backuppiece 101;
Deleting a backup by file name:
RMAN>DELETE CONTROLFILECOPY '/tmp/control01.ctl';
Deleting arhive log files:
RMAN>DELETE NOPROMPT ARCHIVELOG UNTIL SEQUENCE = 300;
RMAN>DELETE NOPROMPT ARCHIVELOG ALL;
Note:NOPROMPT, During the backup deletion , it will not ask the  Yes / No  question  confirmation
Deleting a backup by tag name:
RMAN>DELETE BACKUP TAG='before_upgrade';
Deleting all backups:
RMAN>DELETE BACKUP;
Deleting a backup on the disk which backed up to tape:
RMAN>DELETE ARCHIVELOG ALL BACKED UP 3 TIMES TO sbt;
Deleting Image copy backup:
RMAN>DELETE COPY;
Deleting Obsolete Backuıp
RMAN marks backups as obsolete are not needed for the recovery process. (if you set redundancy or recovery window )
Deleting obsolete backups:
RMAN>delete obsolete;
Deleting obsolete backups older than 3 days:
RMAN> delete obsolete recovery window of 3 days;
Deleting expired backup
RMAN>delete expired backup;
Crosscheck Control
Crosscheck command checks the backup in the RMAN repository whether it exists physically on the disk or tape . If the file not exists physically on the disk or tape (can be deleted through the operating system)  it marks the backup as  “EXPIRED” in the RMAN Repository. Then, you can delete from RMAN Repository with “DELETE EXPIRED” command.
Checking Archive log files with crosscheck:
RMAN>crosscheck archivelog all;
Checking whole backup with crosscheck:
RMAN>crosscheck backup;
Checking image copy backup with crosscheck:
RMAN>crosscheck copy;
Checking tagged backup with crosscheck:
RMAN>crosscheck backuppiece tag = 'nightly_backup';
Showing Backup List
RMAN>list backupset of database;
RMAN>list backup;
Showing Backup Preview (In which objects are listed in):
RMAN> restore database preview;

RMAN> restore tablespace users preview;
Configuration Operations
See the configuration settings:
RMAN>show all;
Return to the default configuration: At the end of statement iswritten  “clear” expression.
RMAN>configure backup optimization clear;
To see a configuration that has been set: At the begining of statement is written  “set” expression
RMAN>show controlfile autobackup format;
To configure a setting: At the begining of statement is written  “configure” expression
RMAN>configure device type disk backup type to copy;

RMAN>configure retention policy to recovery window of 7 days;

RMAN>configure retention policy to redundancy 3;
Verification Operations (validate) 
Verification whole backup:
RMAN>backup validate;
Verification archive log files backup:
RMAN>backup validate database archivelog all;
Verification whole database restore:
RMAN>restore database validate;
Verification control file restore:
RMAN>restore controlfile validate;
Verification spfile restore:
RMAN>restore spfile validate;
Verification a tablespace restore:
RMAN>restore tablespace users validate;
Backup Compression Operations (After 11g)
Compression a backupset:
RMAN>backup as compressed backupset database;
Backup Encryption  Operations
Setting the Encryption :
RMAN> Set  encryption identified by passwprd;
Setting the Decryption:
RMAN> Set  decryption identified by passwprd;
Enable & Disable Block change tracking
BCT to be active only changed blocks to keep track of:
SQL>alter database enable block change tracking using file '/rman_bkups/change.log';
Disabling Block change tracking:
SQL>alter database disable block change tracking;
To debug and trace RMAN backup
$rman target=/ debug=all trace=rman.trc
Create the backup log file
$export NLS_DATE_FORMAT=’dd.mm.yyyy hh24:mi:ss’;

$rman target=/ log=rman.log
Recovery area size information
select name
,        floor(space_limit / 1024 / 1024) "Size MB"
,        ceil(space_used  / 1024 / 1024) "Used MB"
from   v$recovery_file_dest
order by name
/
RMAN Catalog DB operations
  1. Create a user on catalog db.
  CREATE USER rman IDENTIFIED BY rman
  TEMPORARY TABLESPACE temp
  DEFAULT TABLESPACE users
  QUOTA UNLIMITED ON users;
  1. Grant Recovery Catalog owner to that user
GRANT RECOVERY_CATALOG_OWNER TO rman;
  1. Connect to catalog db and create catalog
rman CATALOG rman/rman@catalog
RMAN> create catalog;
  1. Register to target database which will be backed up.
rman TARGET sys/oracle@test10g CATALOG rman/rman@catolog RMAN> register database;
Opening channels in RMAN and  distribute objects to channels
Example:
RUN
{
  ALLOCATE CHANNEL c1 DEVICE TYPE sbt PARMS="ENV=(BACKUP_SERVER=tape_server1)";
  ALLOCATE CHANNEL c2 DEVICE TYPE sbt PARMS="ENV=(BACKUP_SERVER=tape_server2)";
  ALLOCATE CHANNEL c3 DEVICE TYPE sbt PARMS="ENV=(BACKUP_SERVER=tape_server3)";
  BACKUP
   (DATAFILE 1,2,3
    CHANNEL c1)
   (DATAFILECOPY '/tmp/system01.dbf', '/tmp/tools01.dbf'
     CHANNEL c2)
   (ARCHIVELOG FROM SEQUENCE 100 UNTIL SEQUENCE 102 THREAD 1
     CHANNEL c3);
}
 
 
 
source:
https://taliphakanozturken.wordpress.com/tag/delete-obsolete-backup/