Beruflich Dokumente
Kultur Dokumente
ANDREJS PROKOPJEVS
Lead Applications Database Consultant
PAVAN MARTI
Applications Database Consultant
About me
@aprokopjevs
© 2017 Pythian 2
About me
@Pavanmarti
© 2017 Pythian 3
ABOUT PYTHIAN
© 2017 Pythian 4
TECHNICAL EXPERTISE Big Data: Harnessing the transformative
power of data on a massive scale
© 2017 Pythian 5
EXPERIENCED GLOBAL EXPERTS
11,800 400 2
Systems currently Pythian experts Millennia of experience
managed by Pythian in 35 countries gathered and shared over
19 years
© 2017 Pythian 6
Agenda
© 2017 Pythian 7
What is logical
hostname
© 2017 Pythian 8
What is a logical hostname?
• Virtual host or address is a mapping of your application logically for an end user.
• That’s it?
© 2017 Pythian 9
Example #1
server1.domain.com server2.domain.com
app1.domain.com app4.domain.com
app2.domain.com app5.domain.com
app3.domain.com app6.domain.com
© 2017 Pythian 10
Example #2
• Clusters.
Load
Balancer
server1.domain.com server2.domain.com
app1.domain.com app1.domain.com
app2.domain.com app2.domain.com
app3.domain.com app3.domain.com
Cluster 1
© 2017 Pythian 11
Example #3
• Cloud.
LBaaS
© 2017 Pythian 12
Why it should be an important
piece of a DR strategy
© 2017 Pythian 13
DR – in general
• Transparency ip-10-10-10-10
eu-1.cloud.com
ip-10-10-17-21
us-1.cloud.com
• Preferred
• Minimum downtime APP 1 APP 1
• Minimum data loss
• SLA
• Maximum allowed switchover
window to be defined.
• Bi – Directional
• And to be tested, at least, on a bi- Production DR
yearly basis.
© 2017 Pythian 14
DR – Oracle E-Business Suite – DB tier
• Physical standby
• $$$ (EE license for standby).
• Lots of manual effort.
• Data loss of, at least, one redo log. ebsdb1.domain.com ebsdb3.domain.com
Production - RAC DR
• Active Data Guard
• $$$$$$ (additional option)
© 2017 Pythian 15
DR – Oracle E-Business Suite – Apps tier
• Only Active-Passive
• Cloning RSYNC
ebsapp2.domain.com
• Switchover back
• Another Cloning
APPS_BASE
Multi-Node production DR
© 2017 Pythian 16
Challenge
• Why cloning?
• EBS configuration is very tight to node name (FND).
• R12.2: EBS configuration is very tight to node name and IP address of that node (+ADOP).
• To enable a new DR node, you need to follow cloning process to get the new node set.
• It takes time
• 30-60 minutes, and even longer.
• Workarounds
• Well scripted and tested automated process, but still adcfgclone.pl takes time.
• Have DR nodes already inside the primary configuration.
▪ Reports of unavailable nodes in the stack.
▪ Still requires post steps (like relocation of the Concurrent Managers).
ebsapp1.domain.com ebsapp3.domain.com
app.domain.com app.domain.com
APPS_BASE APPS_BASE
Production DR
© 2017 Pythian 18
Benefits
© 2017 Pythian 19
How cloning process can be
improved
© 2017 Pythian 20
Cloning process
• Cloning using rapid clone
Run adpreclone.pl Run adcfgclone.pl
prod1.domain.com test1.domain.com
COPY
prod2.domain.com test2.domain.com
Source Target
© 2017 Pythian 21
Cloning process - detailed
• Post steps
© 2017 Pythian 22
Challenges
• Why hostname area is important? Why we can’t just copy the files?
• EBS configuration, FND tables.
• Profile options.
• Concurrent Managers validate “uname -n” !!!
• Multi node, Load balancer, OID/SSO integrations.
• … etc. Lots of more.
• Workarounds
• Automation (scripts, Ansible, etc)
• Applications Management Pack (EM)
© 2017 Pythian 23
How it could look like? Hi! I am a logical
hostname.
prod3.domain.com test3.domain.com
db1.domain.com db1.domain.com
COPY
EBSDB EBSDB
Source Target
© 2017 Pythian 24
Benefits
• No need of Source and Target steps
• Cloning is just a copy of source to target.
• Any DB tier change (SID, host, port) is just a context update plus AutoConfig.
• Reduces the manual effort. Automation is easy.
• Reduces the work within few hours, or even minutes (cloud).
© 2017 Pythian 25
Cloud provisioning example
•
ebsapp.domain.com ebsapp.domain.com
Create VM Image /
APPS_BASE APPS_BASE
Template
© 2017 Pythian 26
Support for 11i/R12 and
R12.2
© 2017 Pythian 27
Logical hostname support
• Release 11i / R12.0 / R12.1
• Only physical hostname is supported.
• You have to configure logical name as a physical hostname on the server.
• OS commands must return the hostname configured.
▪ uname -n
▪ hostname
• Release R12.2
• Official support and solution are implemented.
• Configuration can be based on logical hostname.
• Requires a specific patch level.
© 2017 Pythian 28
R12.2 requirements
• Patch level
• Patch 25178222:R12.AD.C.Delta.9
• Patch 25180736:R12.TXK.C.Delta.9
• Patch 17075726:R12.FND.C
• Alias in /etc/hosts
© 2017 Pythian 29
R12.2 – what is changed?
• Context name, s_hostname, s_%host context variables can be pointed to logical
hostname value.
<host oa_var="s_hostname">ebsapp1</host>
• $APPL_TOP/APPSVIS122_vis122app01.env
currentHost=`hostname|sed 's/\..*//g'|tr "[A-Z]" "[a-z]"`
host=`echo ”ebsapp1"|tr "[A-Z]" "[a-z]"`
physicalHost=`echo ”prod1"|tr "[A-Z]" "[a-z]"`
• Changes in CM initialization
• "uname -n” use is gone.
• Startup is using the configured host value and passes it to the runtime as a parameter.
• Examples:
$ ps -fu applmgr
...
...
/u01/vision/fs1/EBSapps/comn/util/jdk64/bin/java ...
-DEBS_HOSTNAME=ebsapp1 ... oracle.apps.fnd.cp.gsf.GSMServiceController
© 2017 Pythian 31
What to do with a release below R12.2 TXK delta 9?
• Challenge
• Starting Concurrent Managers is the main problem. These validate their target node name with
server hostname.
• Any alternatives?
© 2017 Pythian 32
Alternatives
• How about to fake the hostname on your Linux server just for Oracle EBS.
• fakehostname.c is created to replace gethostname() default OS call to return you the desired
hostname value from environment variable.
• fakehostname.c is compiled as 32-bit library. With R12.2 you need both 32 and 64 bit libraries
to be created.
• This tweak can be added to your environment source (.bash_profile) before your EBS
environment is set.
© 2017 Pythian 33
Fake hostname
• Example:
[applmgr@prod1 ~]$ ls -l /lib/libfakehostname.so.1
-rwxr-xr-x 1 root root 7240 Jan 6 19:40 /lib/libfakehostname.so.1
[applmgr@prod1 ~]$ ls -l /lib64/libfakehostname.so.1
-rwxr-xr-x 1 root root 8464 Jan 6 19:40 /lib64/libfakehostname.so.1
[applmgr@prod1 ~]$
[applmgr@prod1 ~]$ export MYHOSTNAME=ebsapp01
[applmgr@prod1 ~]$
[applmgr@prod1 ~]$ hostname
prod1.domain.com
[applmgr@prod1 ~]$
[applmgr@prod1 ~]$ export LD_PRELOAD="libfakehostname.so.1”
[applmgr@prod1 ~]$ hostname
ebsapp01
[applmgr@prod1 ~]$
• Reference:
https://blog.pythian.com/oracle-e-business-suite-virtual-host-names-solution-r12-2/
© 2017 Pythian 34
Advanced configurations
Linux Containers
© 2017 Pythian 35
Linux Containers
• LXC virtualization
• Multiple Linux instances on a single host.
• Shared kernel
• Not a classic virtual machine we used to.
• Hardware is not emulated.
• Isolated process tree view of the OS, security, networking, storage.
HyperVisor
HOST OS
KERNEL
© 2017 Pythian 37
Architecture with LXC
Container engine
HOST OS
KERNEL
© 2017 Pythian 38
Configuration
• Examples:
[root@ebsapp1 ~]# lxc-create -n app -t oracle -- --release=6.latest --privileged
[root@ebsapp1 ~]# lxc-start -n app -d -o /var/log/lxc/app.log
root@app:~# hostname
app.domain.com
root@app:~#
© 2017 Pythian 39
Resource control
• Examples:
[root@ebsapp1 ~]# lxc-cgroup -n app cpuset.cpus 0,1
[root@ebsapp1 ~]# lxc-cgroup -n app memory.limit_in_bytes 53687091
© 2017 Pythian 40
E-Business Suite use case
• DR
• Rsync between containers.
• Snapshot or keep in sync the container repository.
ebsapp1.domain.com ebsapp3.domain.com
app.domain.com app.domain.com
APPS_BASE APPS_BASE
Containers Containers
Production DR
© 2017 Pythian 42
Summary
• Official logical hostname support is long awaited and finally available, but only for
R12.2.
• It can streamline the instance lifecycle management, rapid process of cloning.
• Easier instance provisioning from images (cloud deployment and automation).
• DR failover window is minimum.
• There are still unofficial options available for pre-R12.2 releases.
• Linux Containers is a good OS level alternative approach.
© 2017 Pythian 43
THANK YOU
Q&A
© 2017 Pythian 44