Posts

Showing posts from 2018

Cleanup Oracle ADR trace files on Linux

Here's a nice loop cleanup the Oracle DB trace files on Linux with the adrci utility. #!/bin/bash #cleanup Automatic Diagnostic Repository (i.e trace files) #set oracle_home (have a script with your home info) source ~/OracleHomeScript.sh #list current repo size echo "" echo "##############size before############" du -shx /u01/app/oracle/diag echo "" echo "Listing diag directory homes..." echo "" ADR_HOMES=`adrci exec="show homes" |grep -v "ADR Homes:"` adrci exec="show homes" |grep -v "ADR Homes:" echo "" echo "" #Set-up loop for each home # for f in $ADR_HOMES do echo "purging $f older than 1 week" #Slow ADRCI Execution When Purging Files After Upgrade to 12.2 (Doc ID 2335738.1) adrci exec="set homepath $f; purge -age 10080 -nolog" done #list ADR repo size after echo "" echo "##############size after####...

Cleaning up Oracle Recycle Bin

It is a good idea to keep tabs on the recycle bin in your Oracle database, especially after PeopleSoft upgrades. This info is in the dba_recyclebin view. To check the size and number of objects select count(*), sum(space)/1024/1024 AS "Size in MB" from dba_recyclebin; To empty it purge dba_recyclebin

Monitoring Diskspace Usage on Linux

While I would always advocate to monitor OS metrics like disk space usage with an agent (i.e. Enterprise Manager/Zabbix/Prometheus) sometimes, that's not always an option. For a recent edge case I needed to drop in a crontab script and wanted something dynamic (no hard coding) and informative. Here's what I came up with that may be useful for others. The output will look something like this: Running low on space "/dev/sda1 (85%)" on server.domain.com as on Tue Jul  3 12:54:39 EDT 2018.  It is mounted at /u01. To find large directories in the mount use the disk usage command, i.e. - du -ax /u01 | sort -n -r | head -n 10     **This email was generated from a script run on server.domain.com**

PeopleSoft HCM and PS Query Performance

Recently during a PeopleSoft HCM upgrade to image 24, we noticed our PeopleSoft Query performance was very poor. Thanks to a tip from the psadmin.io podcast, we found a work around referenced in Oracle doc id  - Multiple PSQueries Having Performance Issues After 9.2 Upgrade (Doc ID 2146808.1). The short version of the doc id, is to open Application Designer and switch the PERALL_SEC_QRY and EMPLMT_SRCH_QRY views from using the Oracle Specific SQL, back to the default SQL. It seems in Oracle's efforts to improve the performance of these views for their Oracle DB customers, they may have made it worse depending on your data.

Which Java version is my WebLogic server running?

While reviewing an Oracle CPU, I was asked to make sure we are running the current version of Java with our WebLogic servers. This should be an easy task, but Oracle's PeopleSoft DPK loads many version of Java, so it is not easy to know which one is in use. A quick Google, and I found a way to check the path of any running process. (in this instance, we're running Linux) First find the PID for the process ps -ef | grep -i java | grep -i "weblogic domain"       2. Check the path of the process against the /proc/ information ls -l /proc/"PID"/exe An the result will show the path to your java home. If you're not sure the version in the java home, just go to the directory and run  ./java --version For PeopleSoft, if you ever need to change the JAVA_HOME path that your WebLogic domain will use. You just need to modify the file $PS_CFG_HOME/webserv/ bin/setEnv.sh. In this file, is an option to override the default JAVA_HOME.