helps you achieve understanding, develop good practices, and operate your team and organization for maximum DevOps awesomeness
Thursday, December 7, 2017
Split linux file
0. Create a test file
[root@jmlab ~]# head -c 19MB /dev/urandom > jmtest1.txt
[root@jmlab ~]# pwd
/root
1. check the size of current file
[root@jmlab ~]# ls jmtest1.txt
jmtest1.txt
[root@jmlab ~]# du -sh jmtest1.txt
19M jmtest1.txt
2. check the file checksum
[root@jmlab ~]# md5sum jmtest1.txt
b06b3a95f8306b9a52390ede0e701e44 jmtest1.txt
3. split file into 5mb site
[root@jmlab ~]# split -b 5M jmtest1.txt jmtest1_
4. check the files and upload
[root@jmlab ~]# ls -lrt jmtest1_*
-rw-r--r-- 1 root root 5242880 Apr 14 06:48 jmtest1_aa
-rw-r--r-- 1 root root 5242880 Apr 14 06:48 jmtest1_ab
-rw-r--r-- 1 root root 5242880 Apr 14 06:48 jmtest1_ac
-rw-r--r-- 1 root root 3271360 Apr 14 06:48 jmtest1_ad
5. Marge file (Give this command to receiving person)
[root@jmlab ~]# cat jmtest1_* > jm1.txt
6. validate checksum
[root@jmlab ~]# md5sum jm1.txt
b06b3a95f8306b9a52390ede0e701e44 jm1.txt
[root@jmlab ~]#
Wednesday, November 8, 2017
Oracle Exadata - dcli
This is cheat sheet for Exadata command.
Exadata host inventory:
cat x6.txt
excc01
excc02
excc03
excc04
#This command is get status of OEM agent:
dcli -l oracle -g ~/x6.txt '/u01/app/agent13/agent_inst/bin/emctl status agent'
#Loop in shell - to get load in all server:
date; for i in {1..4} ; do ssh root@excc0${i} -i id_rsa.pub -C "hostname; uptime" ; done
Exadata host inventory:
cat x6.txt
excc01
excc02
excc03
excc04
#This command is get status of OEM agent:
dcli -l oracle -g ~/x6.txt '/u01/app/agent13/agent_inst/bin/emctl status agent'
#Loop in shell - to get load in all server:
date; for i in {1..4} ; do ssh root@excc0${i} -i id_rsa.pub -C "hostname; uptime" ; done
Saturday, October 7, 2017
Oracle Home Attach to inventory - attachHome
Issue: DBUA Unable to find ORACLE_HOME in Installer
Solution: ORACLE_HOME is missing and need to attech it with oracle inventory
[oracle@ebs121db1 11.2.0]$ export ORACLE_HOME=/u01/PROD/db/tech_st/11.2.0 [oracle@ebs121db1 11.2.0]$ cd $ORACLE_HOME/oui/bin [oracle@ebs121db1 bin]$ pwd /u01/PROD/db/tech_st/11.2.0/oui/bin [oracle@ebs121db1 bin]$ ./runInstaller -invPtrLoc /u01/PROD/oraInventory/oraInst.loc -attachHome ORACLE_HOME=/u01/PROD/db/tech_st/11.2.0 ORACLE_HOME_NAME="oracle_11204" Starting Oracle Universal Installer... Checking swap space: must be greater than 500 MB. Actual 8191 MB Passed The inventory pointer is located at /u01/PROD/oraInventory/oraInst.loc The inventory is located at /u01/PROD/oraInventory 'AttachHome' was successful. [oracle@ebs121db1 bin]$ [oracle@ebs121db1 bin]$
Sunday, July 30, 2017
Failed to execute adclone.pl
Failed to execute /u01/TEST/oracle/product/db/12.1.0.1/appsutil/clone/bin/adclone.pl
ERROR while running Apply... Fri Jul 29 15:11:22 2017 ERROR: Failed to execute /u01/TEST/oracle/product/db/12.1.0.1/appsutil/clone/bin/adclone.pl Please check logfile.
Solution
export PERL5LIB=$ORACLE_HOME/perl/lib/5.14.1:$ORACLE_HOME/perl/lib/site_perl/5.14.1:$ORACLE_HOME/appsutil/perl
and re-run Database techstack cloning
perl adcfgclone.pl dbTechStack /u01/TEST/oracle/product/db/12.1.0.1/appsutil/TEST_ebs121db1.xml
Tuesday, June 20, 2017
Oracle Database Migration to AWS Cloud
Take a full backup of the database
db_full.tz
check the checksum of the backupfile
md5sum db_full.tz
split backup into multiple file size 100mb
split -b 100M db_full.tz db_split_
scp/copy each file to the server
aws s3 cp db_split_ s3://bucket_name
Merge the files.
cat db_split_* > db_full.tz
check the checksum of the backup file
md5sum db_full.tz
db_full.tz
check the checksum of the backupfile
md5sum db_full.tz
split backup into multiple file size 100mb
split -b 100M db_full.tz db_split_
scp/copy each file to the server
aws s3 cp db_split_ s3://bucket_name
Merge the files.
cat db_split_* > db_full.tz
check the checksum of the backup file
md5sum db_full.tz
Friday, June 9, 2017
12.2.6 :: ERROR: txkWfClone.sh execution failed, exit code 1
Logs from the autoconfig file:
START: Executing /u01/EBSDEV/fs1/inst/apps/EBSDEV_grcldm/admin/install/txkWfClone.sh -nopromptmsg
txkWfClone.sh exited with status 1
ERROR: txkWfClone.sh execution failed, exit code 1
Solution:
1. Connect to database server with apps user and run below command
exec fnd_conc_clone.setup_clean;
2. run autoconfig
orasmk@sgofa03:/u02/EBSDEV/db/tech_st/12.1.0/appsutil/scripts/EBSDEV_sgofa03$ ./adautocfg.sh
Enter the APPS user password:
The log file for this session is located at: /u02/EBSDEV/db/tech_st/12.1.0/appsutil/log/EBSDEV_sgofa03/05091543/adconfig.log
AutoConfig is configuring the Database environment...
AutoConfig will consider the custom templates if present.
Using ORACLE_HOME location : /u02/EBSDEV/db/tech_st/12.1.0
Classpath : :/u02/EBSDEV/db/tech_st/12.1.0/jdbc/lib/ojdbc6.jar:/u02/EBSDEV/db/tech_st/12.1.0/appsutil/java/xmlparserv2.jar:/u02/EBSDEV/db/tech_st/12.1.0/appsutil/java:/u02/EBSDEV/db/tech_st/12.1.0/jlib/netcfg.jar:/u02/EBSDEV/db/tech_st/12.1.0/jlib/ldapjclnt12.jar
Using Context file : /u02/EBSDEV/db/tech_st/12.1.0/appsutil/EBSDEV_sgofa03.xml
Context Value Management will now update the Context file
Updating Context file...COMPLETED
Attempting upload of Context file and templates to database...COMPLETED
Updating rdbms version in Context file to db121
Updating rdbms type in Context file to 64 bits
Configuring templates from ORACLE_HOME ...
AutoConfig completed successfully.
3. Clear the failed session
rm -Rf /u01/EBSDEV/fs1/FMW_Home
rm -Rf /u01/EBSDEV/oraInventory
4. re-run cloning steps
cd /u01/EBSDEV/fs1/EBSapps/comn/clone/bin
perl adcfgclone.pl appsTier /u01/EBSDEV/fs1/inst/apps/EBSDEV_grcldm/appl/admin/EBSDEV_grcldm.xml
Monday, May 1, 2017
Start OSWatcher Black Box (OSWBB) Every System Boot
Oracle OSWatcher Black Box (OSWbb) : collects and archives operating system and network metrics that you can use to diagnose performance issues. OSWbb operates as a set of background processes on the server and gathers data on a regular basis, invoking such Unix utilities as vmstat, netstat, iostat, and top. From release v4.0.0, you can use the OSWbba analyzer to provide information on system slowdowns, system hangs and other performance problems, and also to graph data collected from iostat, netstat, and vmstat. OSWbba requires that you have installed Java version 1.4.2 or higher on your system.
You can use yum to install Java, or you can download a Java RPM for Linux from http://www.java.com. OSWbb is particularly useful for Oracle RAC (Real Application Clusters) and Oracle Grid Infrastructure configurations. The RAC-DDT (Diagnostic Data Tool) script file includes OSWbb, but does not install it by default
1. Install wget utility
yum install -y wget
2. Download latest oswatcher package
wget wget http://public-yum.oracle.com/repo/OracleVM/OVM3/34_latest/x86_64/getPackage/oswatcher-7.3.3-2.el6.noarch.rpm
3. Install OS Watcher
yum install oswatcher-7.3.3-2.el6.noarch.rpm
4. Change OS Watcher parameters
# Set OSW_HOME to the directory where your OSWatcher tools are installed
OSW_HOME='/opt/osw'
# Set OSW_INTERVAL to the number of seconds between collections
OSW_INTERVAL='60'
# Set OSW_RETENTION to the number of hours logs are to be retained
OSW_RETENTION='48'
# Set OSW_USER to the owner of the OSWHOME directory
OSW_USER='root'
# Set OSW_COMPRESSION to the desired compression scheme
OSW_COMPRESSION='bzip2'
# Set OSW_ARCHIVE to the location to generate the logs
OSW_ARCHIVE='archive'
5. Stop and start services
# /etc/init.d/oswatcher start
# /etc/init.d/oswatcher stop
Oracle Referece Note: How To Start OSWatcher Black Box (OSWBB) Every System Boot Using RPM oswbb-service (Doc ID 580513.1)
Wednesday, March 29, 2017
EBS 12.1.3 apachectl startssl libdb.so.2: cannot open shared object file: No such file or directory
Issue: EBS 12.1.3 apachectl startssl libdb.so.2: cannot open shared object file: No such file or directory
Error:
cat /var/lib/logrotate/status
Error: /u01/TEST/inst/apps/TEST_ebs121ap1/ora/10.1.3/Apache/Apache/bin/apachectl startssl: execing httpd /u01/TEST/apps/tech_st/10.1.3/Apache/Apache/bin/httpd: error while loading shared libraries: libdb.so.2: cannot open shared object file: No such file or directory
Solution
ls -l /usr/lib/libdb.so.2
ln -s /usr/lib/libgdbm.so.2.0.0 /usr/lib/libdb.so.2 [root@ebs121ap1 lib]# ls -ltr libgdbm.so.2.0.0 -rw-r--r-- 1 opc opc 24876 Jul 29 15:38 libgdbm.so.2.0.0 [root@ebs121ap1 lib]# ls -l /usr/lib/libdb.so.2 ls: cannot access /usr/lib/libdb.so.2: No such file or directory [root@ebs121ap1 lib]# ln -s /usr/lib/libgdbm.so.2.0.0 /usr/lib/libdb.so.2 [root@ebs121ap1 lib]# [root@ebs121ap1 lib]# [root@ebs121ap1 lib]# ls -l /usr/lib/libdb.so.2 lrwxrwxrwx 1 root root 25 Jul 29 15:39 /usr/lib/libdb.so.2 -> /usr/lib/libgdbm.so.2.0.0 [root@ebs121ap1 lib]#
Download file from here
Thursday, February 16, 2017
adding swap space to Oracle Linux 6
adding swap space to Oracle Linux 6
#16gb
dd if=/dev/zero of=/u01/swap1 bs=1024 count=16384000
mkswap /u01/swap1
swapon /u01/swap1
#/etc/fstab
/u01/swap1 swap swap defaults 0 0
#16gb
dd if=/dev/zero of=/u01/swap1 bs=1024 count=16384000
mkswap /u01/swap1
swapon /u01/swap1
#/etc/fstab
/u01/swap1 swap swap defaults 0 0
Saturday, February 11, 2017
Creating a Custom Application top for EBS 12.2 Using adsplice
Sunday, January 15, 2017
EBS R12.2 – java.io.IOException: DP_POLL failed for /dev/poll
This summary is not available. Please
click here to view the post.
Subscribe to:
Posts (Atom)
apt-key warning when sudo apt update run
Issue: apt-key warning when sudo apt update run Update below file: cat /etc/apt/sources.list.d/download_docker_com_linux_ubuntu.list ...
-
Install htop in Oracle Linux 7 htop is not default install and it's not part of default repo so when we try to install htop it throw...
-
How to Stop Firewall on Oracle Linux 7 [root@ebs121db1 ~]# iptables -L Chain INPUT (policy ACCEPT) target prot opt source ...
-
Oracle EBS 12.2.6 - DB Tire configuration error WARNING: [AutoConfig Error Report] The following report lists errors AutoConfig encounter...