Skip to main content

Posts

Showing posts from December, 2021

Shell script to find the print queue on Linux Server

Shell script to find the print queue on Linux Server In this post I am going to share a shell script to find if the print queue on a server of all printers is more than 50. You can customize based on your requirement. Sample Code: cat /root/bin/printstatus.sh #!/bin/bash lpstat `lpstat -a | awk '{print $1}'` > printq.lst qcount=`wc printq.lst | awk '{print $1}'` if [ $qcount -gt 50 ] then   mail -s "Print Queue is more than 50 in funebs122" support@funoracleapps.com < printq.lst fi If you like please follow and comment

Shell Script to Resize Temp File

Shell Script to Resize Temp File In this post, I am going to share a shell script to resize temporary tablespace. Mostly after the database base clone we might need to reduce the size of the temp files. You can incorporate this in any other post-clone scripts or as required. I have done it using functions in the shell script. cat resize.sh #!/bin/bash fun_temp_resize() { sqlplus -s '/as sysdba' << EOF > /tmp/tempfile_number set head off select file_id from dba_temp_files; EOF for i in `cat /tmp/tempfile_number` do echo "alter database tempfile ${i} resize 10g;" done >/tmp/temp_resize.sql } #####Main Program Call##### sqlplus /nolog << EOF   2>&1 | tee -a  $LOGFILE connect / as sysdba @/tmp/temp_resize.sql EOF If you like please follow and comment

How to check SSL certificate expiration date from a certificate file

How to check SSL certificate expiration date from a certificate file OpenSSL command is a very powerful command to check certificate info in Linux. We can use the following command to check the expiration date. openssl x509 -enddate -noout -in file.cer  Example: openssl x509 -enddate -noout -in server_funebs122.cer If you like please follow and comment

Shell Script to Check Concurrent Request Running for more than 2 hrs and send mail alert for Oracle Apps

Shell Script to Check Concurrent Request Running for more than 2 hrs and send mail alert for Oracle Apps Shell Script to run the check the concurrent request running more than 2 hrs cat concurrent_request_more2hrs.sh #!/bin/bash . ~/.bash_profile #Source DB environment file . FUAT_funebs122 rm -f /home/oracle/scripts/concrqst_hours.html cd /home/oracle/scripts sqlplus "/ as sysdba" @concrqst_hours.sql if grep --quiet 'RQST_ID' /home/oracle/scripts/concrqst_hours.html; then echo "Sending email" echo "Concurrent request running for 2 hours or more" | mutt -e "my_hdr Content-Type: text/html" -s "FUAT -- Long Running Request" support@funoracleapps.com < concrqst_hours.html fi SQL script which will be called to check long-running concurrent requests $ cat concrqst_hours.sql SET MARKUP HTML ON SPOOL ON set termout off set pages 999 set pagesize 999 set feedback off SET MARKUP HTML ON TABLE "class=sysaud cellspacing=2 border=...

Enable SSH in Linux Mint

Enable SSH in Linux Mint In this post I am going to share steps how to enable ssh on Linux Mint 1) Open Terminal 2) Install OpenSSH Server sudo apt-get install openssh-server -y If you are doing via root then sudo keyword is not required. 3) Check OpenSSH Status #systemctl is-enabled ssh if it show disabled then  do below  #systemctl enable ssh  4) Check ssh is active and running  #systemctl is-active ssh  #systemctl status sshd If you like please follow and comment

Windows 11 Installation On an UnSupported Hardware

Windows 11 Installation On an UnSupported Hardware I was installing windows 11 on my old laptop (i3 5th generation). I have created a bootable USB with windows 11. Now when installing I was getting an unsupported hardware error. No TPM Chip No Supported CPU On the screen when you are selecting Windows 11 for installation. Press Shift + F10 It will open a Command Prompt Type regedit The registry editor will now be open. Go to [HKEY_LOCAL_MACHINE\SYSTEM\Setup\LabConfig] If LabConfig is not there then please create it. Then Add below DWORD keys in the LabConfig with mentioned values DWORD "BypassTPMCheck"=1 DWORD "BypassSecureBootCheck"=1 DWORD "BypassRAMCheck"=1 DWORD "BypassStorageCheck"=1 DWORD "BypassCPUCheck"=1 Now-Again select windows Home/Pro 11 and now it will not fail on the precheck and will run smoothly and Installation will complete If you like please follow and comment

Shell Script to Monitor and Get Alert for Workflow Notification Mailer and Components in Oracle Apps

Shell Script to Monitor and Get Alert for Workflow Notification Mailer and Components in Oracle Apps I am going to share how to check workflow notification mailers and service components using shells scripts.   There can be multiple methods to do the same and write scripts Create a SQL script cat wf_mailer_status_component.sql spool /tmp/wf_mailer_status_component.log alter session set nls_date_format='DD-MON-RRRR HH24:MI:SS'; select sysdate from dual; select component_id,component_name,component_status from apps.fnd_svc_components where component_id in ('10002','10003','10004','10005','10006','10040','10022','10023') and component_status <> 'RUNNING'; spool off exit Create a shell script to call the SQL and trigger the alert to send mail cat wf_mailer_status_components.sh date . /u01/oracle/FUAT/apps/apps_st/appl/APPSFUAT_sgap2.env sqlplus "apps/apps" @/home/applmgr/bin/wf_mailer_status_com...

How to Enable Oracle E-Business Suite Audit Trail on Tables

How to Enable Oracle E-Business Suite Audit Trail on Tables Audit is a very important feature of the oracle apps. We can track the last changes in the Oracle apps records but what about the second last change so well there is no track of this. So to see all the changes that happened for the table we can use the Audit feature of the oracle apps. We can audit some of the sensitive tables in oracle apps R12 using audit trail functionality. We don't need to audit the complete table. We can audit the Complete or we can audit some of the columns in the table and the Audit report will give us all the details regarding any changes in this table for that audit columns. You can choose to store and retrieve a history of all changes users make on a given table. Auditing is accomplished using audit groups, which functionally registered Oracle IDs or group tables to be audited. For a table to be audited, it must be included in an enabled audit group. Audit Trail Groups are groups of tables and ...

When|How Can We Reverse the Cutover in Oracle Apps R12.2 - YES or No ?

When|How Can We Reverse the Cutover in Oracle Apps R12.2 - YES or No?   Cutover is a Critical Phase and changes would be committed at this level. If you want to cancel the patching cycle you should go for abort.  But still, in some failure states, we can try to recover after the cutover has happened. I would not recommend these steps and may hamper your system. Because once the patch DB edition has been promoted run DB edition it will not be a good idea to revert from there. If a cutover error occurs, you should first check the error message and try to determine if the problem can be fixed easily and try to fix that and re-run cutover. But if you want to revert to the state of the system before the patching cycle was started, you can use the Oracle Database Flashback feature to go back to a designated point in time (a restore point). You should create the restore point just before running the cutover phase. Before creating the restore point, it is advisable to issue a sui...