1 每次克隆前最好运行数据库层的adpreclone,如果有数据文件增加就运行,确认没有数据文件增加可以不运行。数据库层可以手动创建控制文件,所以adpreclone并不是必须的,要看你怎么做了。
2 adpreclone.pl运行时数据库必须启动,应用层状态无所谓
3 打的补丁不大(而且不是AD的补丁)可以不做应用层的preclone
预克隆为什么是先做dbtier,再做appsTier?
因为apps里面要链接数据库
所以要先做好数据库,然后应用连上
EBS Clone可分为五个步骤:
1.在DB层执行预clone: 建议关闭应用(可以不关闭),数据库保持开启状态
$ cd [RDBMS ORACLE_HOME]/appsutil/scripts/[CONTEXT_NAME]
$ perl adpreclone.pl dbTier
cd $ORACLE_HOME/appsutil/scripts/$CONTEXT_NAME
perl adpreclone.pl dbTier
2.在APP层执行预clone:
$ cd [INST_TOP]/admin/scripts
$ perl adpreclone.pl appsTier
cd $INST_TOP/admin/scripts
perl adpreclone.pl appsTier
3.关闭APP层、DB层及复制APP层、DB层目录:
For example: cd /target_dest_dir/db cp -RH /source_dir/db/*
压缩appsTier
cd /home/CEOCS
nohup gtar zcvf `hostname`_inst_$(date +%F).tar.gz ./inst > `hostname`_inst_$(date +%F).log &
nohup gtar zcvf `hostname`_apps_$(date +%F).tar.gz ./apps > `hostname`_apps_$(date +%F).log &
压缩dbTier
sudo su -
cd /home/CEOCS/db/tech_st/11.2.0/..
nohup tar cfvz `hostname`_dbhome1_$(date +%F).tar.gz --exclude 11.2.0/log --exclude 11.2.0/admin --exclude 11.2.0/rdbms/audit 11.2.0 &
备份数据库
#######################################ebsbackup_db_level0.sh
cat ebsbackup_db_level0.sh
backup_path=/backup/rman/$(date +%F)
mkdir -p $backup_path
chown -R oracle:oinstall $backup_path
su - oracle -c 'rman target / nocatalog msglog#/backup/rman/rman_L0.`date +%Y%m%d%H%M%S`.log' <<EOF
run
{
configure device type disk parallelism 16 backup type to compressed backupset;
backup as compressed backupset incremental level 0 format '$backup_path/%d_level0_%Y%M%D$(date +%H%M%S)_%U' database;
sql "alter system archive log current";
sql "alter system archive log current";
sql "alter system archive log current";
backup as compressed backupset archivelog all format '$backup_path/%d_arch_%Y%M%D$(date +%H%M%S)_%U';
backup current controlfile format '$backup_path/%d_controlfile_level0_%Y%M%D$(date +%H%M%S)_%U';
configure device type disk parallelism 6 backup type to compressed backupset;
}
EOF
#######################################ebsbackup_db_arch.sh
cat ebsbackup_db_arch.sh
backup_path=/backup/rman/$(date +%F)
mkdir -p $backup_path
chown -R oracle:oinstall $backup_path
su - oracle -c 'rman target / nocatalog msglog#/backup/rman/rman_arch.`date +%Y%m%d%H%M%S`.log' <<EOF
run
{
configure device type disk parallelism 16 backup type to compressed backupset;
sql "alter system archive log current";
sql "alter system archive log current";
sql "alter system archive log current";
backup as compressed backupset archivelog all format '$backup_path/%d_arch_%Y%M%D$(date +%H%M%S)_%U';
backup current controlfile format '$backup_path/%d_controlfile_arch_%Y%M%D$(date +%H%M%S)_%U';
configure device type disk parallelism 6 backup type to compressed backupset;
}
EOF
#######################################
4.在DB层执行clone:
$ cd [RDBMS ORACLE_HOME]/appsutil/clone/bin
$ perl adcfgclone.pl dbTier
export PATH=/usr/bin:$PATH
which unzip
unzip -V
export PERL5LIB=/home/CEOCS/db/tech_st/11.2.0/perl/lib
export PATH=/home/CEOCS/db/tech_st/11.2.0/perl/bin:$PATH
cd /home/CEOCS/db/tech_st/11.2.0/appsutil/clone/bin
perl adcfgclone.pl dbTier
perl adcfgclone.pl dbTechStack
perl adcfgclone.pl dbTechStack $CONTEXT_FILE
5.在APP层执行clone:
$ cd [COMMON_TOP]/clone/bin
$ perl adcfgclone.pl appsTier
perl adcfgclone.pl atTechStack
perl adcfgclone.pl atTechStack $CONTEXT_FILE
#######################################清除节点信息
sqlplus apps/apps
exec fnd_conc_clone.setup_clean;
commit;
#######################################dbTier autoconfig
ls -l $CONTEXT_FILE
cd $ORACLE_HOME/appsutil/bin
./adconfig.sh
cd $ORACLE_HOME/appsutil/bin
./adconfig.sh contextfile=$CONTEXT_FILE appspass=apps
#######################################在APP层执行clone
export PATH=/usr/bin:$PATH
which unzip
unzip -V
cd /home/CEOCS/apps/apps_st/comn/clone/bin
export PATH=/home/CEOCS/apps/tech_st/10.1.3/perl/bin:$PATH
export PERL5LIB=/home/CEOCS//apps/tech_st/10.1.3/perl/lib/
perl adcfgclone.pl appsTier
你想偷懒 还是嫌启动起来麻烦
一般我是这样 clone 完成 不让系统自动启动服务
启动服务是退出clone
自己先启动opmn里的各种服务改颜色 改标题 改并发数量
这些没问题之后 再起并发 就OK了
#########################################
su - applmgr
rm -rf $INST_TOP/admin/out/appsutil.zip
perl $AD_TOP/bin/admkappsutil.pl
ls -l $INST_TOP/admin/out/appsutil.zip
su - oracle
cd $ORACLE_HOME
unzip -o appsutil.zip
su - oracle
cd $ORACLE_HOME/appsutil/scripts/$CONTEXT_NAME
perl adpreclone.pl dbTier
su - applmgr
cd $INST_TOP/admin/scripts
perl adpreclone.pl appsTier
su - oracle
perl adbldxml.pl tier=db appsuser=apps appspasswd=apps
su - oracle
cd $ORACLE_HOME/appsutil/bin
./adconfig.sh contextfile=$CONTEXT_FILE appspass=apps
su - applmgr
cd $AD_TOP/bin
./adconfig.sh contextfile=$CONTEXT_FILE appspass=apps
EBS R12.1 Cloning Steps
未经允许不得转载:徐万新之路 » EBS R12.1 Cloning Steps
最新评论
这个牛
放下欲望,男人从来不醉,充分且必要
勇气、责任、自信、创新,为天下先!
软件即数据,软件即服务,软件即管理,软件就是对人类各种社会活动的仿真和记录。软件很重要,但软件不可能凌驾于业务之上,尤其不可能高人一等。