jueves, 18 de febrero de 2016

SAP BO Instalación sobre Linux - Oracle 12c - Step by Step



Preparación del usuario Oracle para la instalación de la DB.
: create group and user install oracle
#groupadd oinstall
#groupadd dba
#groupadd oper
#useradd -G dba,oper -g oinstall oracle
#passwd oracle


Crear el directorio de instalación de Oracle. De ser posible, que sean Filesystems
#chown -R oracle:oinstall /oracle
Con el usuario oracle
#mkdir -p /oracle/BOQ/12102
#mkdir -p /oracle/stage/12102
#chmod -R 775 /oracle


Setear parámetros
#vi /etc/sysctl.conf
Agregar las siguientes líneas.

# SAP
vm.max_map_count=2000000
kernel.shmmax=111669149696
kernel.sem=1250 256000 100 1024

# ORACLE
kernel.shmmni = 4096
kernel.shmall = 268435456
fs.file-max = 6815744
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.wmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_max = 1048576

fs.aio-max-nr = 1048576

#/sbin/sysctl -p

#vi /etc/security/limits.conf
add the following lines
@dba       soft    memlock   unlimited
@dba       hard    memlock   unlimited
@sapsys    hard    nofile    32800
@sapsys    soft    nofile    32800
@dba       hard    nofile    65536
@dba       soft    nofile    32800
@dba       soft    nproc     unlimited

oracle  soft    nproc   65535
oracle  hard    nproc   65535
oracle  soft    nofile  65535
oracle  hard    nofile  65535

bodadm  soft    nproc   65535
bodadm  hard    nproc   65535
bodadm  soft    nofile  65535

bodadm  hard    nofile  65535

Setear Variables de entorno para el usuario oracle
#su - oracle
$ cd ~
$ vi .bash_profile
add the following lines
# Oracle Settings
export PATH
export TMP=/tmp
export TMPDIR=$TMP
export ORACLE_HOSTNAME=chi679
export ORACLE_UNQNAME=BOD
export ORACLE_BASE=/oracle
export ORACLE_HOME=$ORACLE_BASE/BOD/12102
export ORACLE_SID=BOD
export PATH=/usr/sbin:$PATH
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib


export TZ="MET-1METDST"
export LANG=en_US.utf8
export LC_ALL=en_US.utf8
#export LD_LIBRARY_PATH=/u01/app/oracle/product/11.2.0/dbhome_1/lib:${LD_LIBRARY_PATH}
export SQLPATH=$ORACLE_HOME/lib:${SQLPATH}
#export ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1
export TNS_ADMIN=$ORACLE_HOME/network/admin
export LIB_PATH=$ORACLE_HOME/lib
#export PATH=$ORACLE_HOME/bin:$PATH
export PERL_HOME="/usr/sap/boxi41/InstallData/setup.engine/perl"

Instalar los siguientes packetes si no están presentes.
yum install binutils -y
yum install compat-libcap1 -y
yum install compat-libstdc++-33 -y
yum install compat-libstdc++-33.i686 -y
yum install gcc -y
yum install gcc-c++ -y
yum install glibc -y
yum install glibc.i686 -y
yum install glibc-devel -y
yum install glibc-devel.i686 -y
yum install ksh -y
yum install libgcc -y
yum install libgcc.i686 -y
yum install libstdc++ -y
yum install libstdc++.i686 -y
yum install libstdc++-devel -y
yum install libstdc++-devel.i686 -y
yum install libaio -y
yum install libaio.i686 -y
yum install libaio-devel -y
yum install libaio-devel.i686 -y
yum install libXext -y
yum install libXext.i686 -y
yum install libXtst -y
yum install libXtst.i686 -y
yum install libX11 -y
yum install libX11.i686 -y
yum install libXau -y
yum install libXau.i686 -y
yum install libxcb -y
yum install libxcb.i686 -y
yum install libXi -y
yum install libXi.i686 -y
yum install make -y
yum install sysstat -y
yum install unixODBC -y
yum install unixODBC-devel -y


Agregar la ip del host en el /etc/hosts
#vi /etc/hosts
192.168.10.100 oracle.test.com oracle.test
oracle.test is hostname and 192.168.10.100 is ip address


Unzip files
$unzip linuxamd64_12c_database_1of2.zip.zip
$unzip linuxamd64_12c_database_2of2.zip.zip


Install oracle DB
$xhost +
$cd /u01/setup/database
$./runInstaller
now, install ORACLE DATABSE using DBCA
$dbca

Instalación de BO con usuario oracle
Prepare database
At this point I don’t care of rights at db level.
create user bo_cms identified by Admin123;
grant dba to bo_cms;
create user bo_audit identified by Admin123;

grant dba to bo_audit;

Obtain the product key.

Create Destination Folder
Ej: /usr/sap/boxi41

BussinessObjectsServer_lnx path

./setup.sh

Chequeo:
./ccm.sh -cms hostname:6400 -username Administrator -password Admin123 -authentication secEnterprise -display

After finished the installation.

http://hostname:8080/BOE/CMC

Remove shared memory of sap instance

Command: cleanipc <instance_nr> remove

However, sometimes, cleanipc fails to cleanup some semaphores saying: Semaphore Key: XX remove failed **** - errno = 1 (Not owner)

Command: cleanipc 06 remove


In this case, login as root and run the following commands:

ipcs –s | grep “the number from the semaphore”

ipcrm –s “the number from the above command”


The above command ipcrm clears up
the semaphore which was not cleared by cleanipc command when executed by <sid>adm user.
Now, if you run cleanipc again using <sid>adm, you will find that the affected semaphore
is now cleared.