Monday, March 6, 2017

install sqldeveloper on ubuntu 14.04 or linux mint 17

https://community.oracle.com/docs/DOC-888316

apt-get install alien
Download sqldeveloper rpm



Install the sqldeveloper rpm file using alien

# sudo alien -ic sqldeveloper..rpm

Download  jdk-8u121-linux-x64.tar.gz   from Here

extract it to /opt/java

vim /usr/local/bin/sqldeveloper


    unset GNOME_DESKTOP_SESSION_ID
    export JAVA_HOME=/opt/java
    /opt/sqldeveloper/sqldeveloper.sh

go to system programs and find sqldeveloper to start

End




Sunday, March 5, 2017

1-oracle architecture - control files



Control Files
its disk file, binary file
if you loose control files database is lost , its best to keep multiple copies of control files(multiplexing)
stores meta data eg. database creation date,
tracks physical components of db, gives answer - thats where my database is
name and location of datafiles ,online redo, time db is created, checkpoints etc.
imp: Backup your control files

Datafiles
physica os/binary file that stores actual data, 1 + more DataFile = table space


Tablespace is logical container for segments, and physically composed of multiple datafiles

Segment is made up of multiple extents ,objects(table, indexes),--extents are grouped together to form segment

Extents is made up of blocks

OnlineRedoLog - recovery method, it is physical file that stores changes made to db, readback the db changes and recover the db changes in the event of crash. archiving redo means copying the redo log to remote machine before its overwritten

parameter file - stores initialization parameters, server info -- num of process, how many process, memory,open cursors, db name, dump location ,user and system dumps etc. some can be changed online and some require restart

password file - stores SYSDBA user info , any user with sysdba grants have entry in this file

Fast Recovery Area - or flash recovery area,  is disk location that does management of backup related files
it basically simplifies db administration, speeds up rman backup ,holds backups, archived redo

AlertLog - stores error and exception messages, this is the first place to look when errors occur

Trace Files- diagonistic files. tool for query tuning, find what is running ,trace session
server and user process write to this file

ASM -automatic storage management
- LVM for oracle
- does striping and raid 10

Grid - G in 11g and 10g
-pools multiple resources and servers into on demand resource
- RAC enable multiple db instances to share a single database, so multiple servers accessing same data files
- Clusterware enable fault tolerance ,performance make multiple server act as single

Cloud backups - oracle secure backup cloud module
allow backups to S3




Saturday, February 25, 2017

Oracle grid installation part 1

1) install necessary rpms for asm support , download the rpm here ASM libs or  google "oracle asm rpm"
2) install the rpm

grep MemTotal /proc/meminfo
grep SwapTotal /proc/meminfo

 /etc/init.d/oracleasm configure
/etc/init.d/oracleasm createdisk ASMDISK01 /dev/sda2
/etc/init.d/oracleasm createdisk ASMDISK02 /dev/sdb1
/etc/init.d/oracleasm createdisk ASMDISK03 /dev/sdc1
/etc/init.d/oracleasm createdisk ASMDISK04 /dev/sdd1
/etc/init.d/oracleasm createdisk ASMDISK05 /dev/sde1
/etc/init.d/oracleasm createdisk ASMDISK06 /dev/sdf1
/etc/init.d/oracleasm createdisk ASMDISK07 /dev/sdg1
/etc/init.d/oracleasm createdisk ASMDISK08 /dev/sdh1
/etc/init.d/oracleasm createdisk ASMDISK09 /dev/sdi1
/etc/init.d/oracleasm createdisk ASMDISK10 /dev/sdj1
/etc/init.d/oracleasm createdisk ASMDISK11 /dev/sdk1
/etc/init.d/oracleasm createdisk ASMDISK12 /dev/sdl1
/etc/init.d/oracleasm createdisk ASMDISK13 /dev/sdm1
/etc/init.d/oracleasm createdisk ASMDISK14 /dev/sdn1

chmod 777 grid/install/.oui
chmod 777 grid/install/unzip

groupadd --gid 54321 oinstall
groupadd --gid 54322 dba
groupadd --gid 54323 asmdba
groupadd --gid 54324 asmoper
groupadd --gid 54325 asmadmin
groupadd --gid 54326 oper

useradd --uid 54321 --gid oinstall --groups dba,oper,asmdba,asmoper oracle
passwd oracle

useradd --uid 54322 --gid oinstall --groups dba,asmadmin,asmdba,asmoper grid
passwd grid


mkdir -p /u01/app/oracle/product/11.2.0/db_1
chown -R oracle:oinstall /u01
chmod -R 775 /u01


yum install oracle-rdbms-server-11gR2-preinstall libaio glibc compat-libstdc libgcc libstdc++ unixODBC unixODBC-devel  elfutils-libelf-devel compat-libstdc++-33



http://myorastuff.blogspot.com/2015/10/crs-4124-oracle-high-availability.html


and
vim /u01/app/oracle/product/11.2.0/grid/crs/install/roothas.pl
bash /u01/app/oraInventory/orainstRoot.sh
bash /u01/app/oracle/product/11.2.0/grid/root.sh
https://oracle-base.com/articles/11g/oracle-db-11gr2-installation-on-oracle-linux-6#Installation