<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Paresh Zawar on Medium]]></title>
        <description><![CDATA[Stories by Paresh Zawar on Medium]]></description>
        <link>https://medium.com/@pareshzawar?source=rss-afc1f5c6f184------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*q9ugua5n8q8mYS0pZvVQPA.jpeg</url>
            <title>Stories by Paresh Zawar on Medium</title>
            <link>https://medium.com/@pareshzawar?source=rss-afc1f5c6f184------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 03:27:05 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@pareshzawar/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[OCI vs AWS: An Honest Cost Comparison]]></title>
            <link>https://pareshzawar.medium.com/oci-vs-aws-an-honest-cost-comparison-2de2472c9538?source=rss-afc1f5c6f184------2</link>
            <guid isPermaLink="false">https://medium.com/p/2de2472c9538</guid>
            <dc:creator><![CDATA[Paresh Zawar]]></dc:creator>
            <pubDate>Mon, 09 Mar 2026 16:54:06 GMT</pubDate>
            <atom:updated>2026-03-09T16:54:06.814Z</atom:updated>
            <content:encoded><![CDATA[<p>for Database Workloads</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Q30XvG_7ENX1QJCVvoxIaw.png" /></figure><p>Most teams pick AWS by default.</p><p>But when the cloud bill arrives, the conversation changes.</p><p>While comparing infrastructure pricing recently, I noticed something surprising:</p><p>In several common workloads, Oracle Cloud Infrastructure (OCI) can be 30–60% cheaper than AWS.</p><p>Not because AWS is bad.</p><p>But because the pricing models are fundamentally different.</p><p>Here are a few things most engineers overlook 👇</p><p>⚡ Flexible Compute OCI lets you scale CPU and RAM independently, avoiding over-provisioning.</p><p>📦 Lower Storage Costs High-performance block storage can cost significantly less depending on workload.</p><p>🌐 Data Egress Advantage OCI includes 10TB/month free outbound data transfer. AWS free tier? About 100GB.</p><p>🌍 Consistent Global Pricing OCI pricing stays similar across regions. AWS varies heavily between regions.</p><p>But AWS still dominates in:</p><p>• Managed services ecosystem • Community support • Market adoption</p><p>So the real question isn’t OCI vs AWS.</p><p>It’s:</p><p>👉 Which cloud is cheaper for your specific workload?</p><p>I break down the real cost differences, architecture implications, and pricing traps here:</p><p>🔗 <a href="https://cloudexplorers.club/oci-vs-aws-cost-comparison">https://cloudexplorers.club/oci-vs-aws-cost-comparison</a></p><p>If you run workloads in the cloud:</p><p>This comparison might save you a serious amount of money.</p><p>Curious to hear from others:</p><p>Have you ever compared OCI vs AWS pricing in real projects?</p><p>#CloudComputing #OCI #AWS #CloudArchitecture #FinOps #CloudCostOptimization #devops #oracle-cloud</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2de2472c9538" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I’ve Moved — Here’s Where to Find My Oracle Cloud & Multicloud Writing]]></title>
            <link>https://pareshzawar.medium.com/ive-moved-here-s-where-to-find-my-oracle-cloud-multicloud-writing-f1d0a6c6e07b?source=rss-afc1f5c6f184------2</link>
            <guid isPermaLink="false">https://medium.com/p/f1d0a6c6e07b</guid>
            <category><![CDATA[announcements]]></category>
            <category><![CDATA[oracle-cloud]]></category>
            <dc:creator><![CDATA[Paresh Zawar]]></dc:creator>
            <pubDate>Tue, 03 Mar 2026 16:41:40 GMT</pubDate>
            <atom:updated>2026-03-03T16:41:40.075Z</atom:updated>
            <content:encoded><![CDATA[<p><em>Same content, sharper focus, and a proper home. This is why I migrated, what’s coming, and how to follow along.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_oISOsMCnAB21pxr7ysfTg.png" /></figure><p>If you’ve followed my writing here on Medium — thank you. Genuinely. Every clap, comment, and follow over the past while has meant more than I can put into an intro paragraph.</p><p>I have some news: <strong>I’ve launched a dedicated blog for all my Oracle Cloud and multicloud writing.</strong> It has a real home now, a proper domain, and — most importantly — the structure and depth these topics deserve.</p><blockquote>“The move was about doing this properly, not just writing into the void.”</blockquote><h3>Why I Moved</h3><p>Medium is a wonderful platform, and I’ll be honest — this community is part of why I kept writing. But as my focus sharpened around Oracle Cloud Infrastructure and multicloud architecture, I needed something more structured.</p><p>I wanted a place where a reader could find the Terraform guide, then the IAM deep dive, then the Oracle@AWS walkthrough — and understand they’re part of a deliberate series, not a random mix of posts from different years.</p><p>So I built that. The new blog lives at:</p><blockquote><a href="https://cloudexplorers.club/">https://cloudexplorers.club/</a></blockquote><h3>What the New Blog Covers</h3><p>Every post fits into one of four focused series:</p><ul><li><strong>OCI in Practice</strong> — Compute, networking, Terraform, IAM, monitoring, DB migration</li><li><strong>The Multicloud Oracle Playbook</strong> — Oracle@AWS, Oracle@Azure, Kubernetes comparisons</li><li><strong>Oracle AI &amp; Autonomous</strong> — OCI Gen AI, Autonomous DB 23ai, AI Vector Search</li><li><strong>OCI vs The World</strong> — Honest cost comparisons and architecture trade-offs</li></ul><p>The first full guide — <a href="https://cloudexplorers.club/terraform-on-oci"><em>Terraform on OCI: A Complete Beginner’s Guide with Real Examples</em> — is already live.</a></p><h3>What Happens to Medium?</h3><p>I’m not disappearing from here. This community is where I started, and I’m not pulling up that bridge.</p><p>Here’s how it works going forward: <strong>every time I post, I’ll post a short summary here on Medium</strong> — the key insight from that latest article and a direct link to the full guide. Think of it as the trailer, not the film.</p><h3>The First Full Post Is Live Now</h3><p><strong>Terraform on OCI: Complete Beginner’s Guide</strong> covers installing Terraform, authenticating to OCI, building a full VCN with an Internet Gateway, provisioning an ARM compute instance, and running your first terraform apply. All HCL code included.</p><p><a href="https://cloudexplorers.club/terraform-on-oci">https://cloudexplorers.club/terraform-on-oci</a></p><h3>How to Follow Along</h3><ul><li><strong>Subscribe on the new blog</strong> — newsletter delivered on every blog post</li><li><strong>Follow me here on Medium</strong> — summaries with links</li><li><strong>Connect on LinkedIn</strong> — behind-the-scenes context on each post</li></ul><p>Have a topic you’d love to see covered? Drop a comment. The calendar is flexible from next week onward. See you. 👋</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JzkIE0bd1bCkW9qIWmni0A.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f1d0a6c6e07b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Enable Multi Factor Authenticator on Linux Server]]></title>
            <link>https://pareshzawar.medium.com/how-to-enable-multi-factor-authenticator-on-linux-server-1bf0ff596845?source=rss-afc1f5c6f184------2</link>
            <guid isPermaLink="false">https://medium.com/p/1bf0ff596845</guid>
            <category><![CDATA[two-factor-authentication]]></category>
            <category><![CDATA[mfa]]></category>
            <category><![CDATA[linux]]></category>
            <dc:creator><![CDATA[Paresh Zawar]]></dc:creator>
            <pubDate>Mon, 14 Dec 2020 00:53:21 GMT</pubDate>
            <atom:updated>2020-12-14T00:53:21.028Z</atom:updated>
            <content:encoded><![CDATA[<p>How to Setup Multi Factor Authenticator on Linux Server</p><h3>Setup MFA for Linux Server</h3><p>Secure your Bastian Server using Google Authenticator</p><p>If you are searching for this blog, so I hope you all are aware of what is MFA and why we are using this, otherwise you can go through this <a href="https://en.wikipedia.org/wiki/Multi-factor_authentication">Wikipedia</a> link and have a look at it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/200/1*NyUkhM_skHB3yXLCs834iw.png" /><figcaption>Logo of Google Authenticator</figcaption></figure><p>Please clear all your doubts about MFA before performing the below setup.</p><h4>Step 1: Install the Google Authenticator package</h4><blockquote>sudo yum install google-authenticator</blockquote><h4>Step 2: Enable MFA for a user</h4><p>Login as a user for which we want to enable the MFA and do the setup as per below.</p><blockquote>google-authenticator</blockquote><p>This tool asks a series of questions. For most of these questions, answer yes (<strong>y</strong>), unless you need something other than the default.</p><p>NOTE down the backup codes and copy the secret key to configure MFA on your mobile. You can use Microsoft Authenticator or Google Authenticator as well on your mobile.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*EH03Si8HF4IGbE7T9WvY-g.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*BPbuklLULSGYtg7U54jaaQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*8o9K2mI9SNdk0woaF5l_tQ.png" /></figure><h4>Step 3: Configure SSH to prompt for the OTP</h4><p><strong>NOTE: Backup all the files before editing and keep at least one session connected to prevent you from the failure.</strong></p><p>Backup and edit the file <strong>/etc/pam.d/sshd</strong></p><blockquote>cp /etc/pam.d/sshd /etc/pam.d/sshd.bckp</blockquote><p>Add the below line under the <strong>auth </strong>session in /etc/pam.d/sshd (Screenshot is given below)</p><p><strong><em>auth required pam_google_authenticator.so nullok</em></strong></p><p><strong>nullok:</strong></p><p>This parameter ensures that all the users are not forced to login with OTP.</p><p>If you want to disable the password authentication comment the below line in under <strong>auth </strong>section.</p><p><em>#auth substack password-auth</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/624/1*_7PYLC3UDHGN5NIMRlvU4w.png" /></figure><h4>Step 4: Modify the sshd_config file</h4><p>Backup and edit the file <strong>/etc/ssh/sshd_config</strong></p><blockquote>cp /etc/ssh/sshd_config /etc/ssh/sshd_config.bckp</blockquote><p>Find and comment out the line <strong>ChallengeResponseAuthentication no</strong> and add a new configuration line <strong>ChallengeResponseAuthentication yes</strong>. This line lets SSH ask for a <strong>Challenge Response</strong>. In our case, the response is an OTP code after a successful SSH key-based authentication. Here is the line:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/419/1*YzlgBGCwJlwfYHeNGoFERg.png" /></figure><p>To enable this settings for specific user, add the below lines of code.</p><blockquote>Match user paresh</blockquote><blockquote>AuthenticationMethods publickey,keyboard-interactive</blockquote><p>Save the file, and restart the ssh services. And give it try while being connected to the at least one session.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/594/1*lqnc28sE6VcRwcOC_XDwOw.png" /></figure><h3>References:</h3><ol><li><a href="https://www.redhat.com/sysadmin/mfa-linux">https://www.redhat.com/sysadmin/mfa-linux</a></li><li><a href="https://en.wikipedia.org/wiki/Multi-factor_authentication">https://en.wikipedia.org/wiki/Multi-factor_authentication</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1bf0ff596845" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Increase Block Volume Size Online in OCI]]></title>
            <link>https://pareshzawar.medium.com/increase-block-volume-size-online-in-oci-ce3250f47d6a?source=rss-afc1f5c6f184------2</link>
            <guid isPermaLink="false">https://medium.com/p/ce3250f47d6a</guid>
            <category><![CDATA[oci]]></category>
            <category><![CDATA[cloud]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[oracle-cloud]]></category>
            <category><![CDATA[parted]]></category>
            <dc:creator><![CDATA[Paresh Zawar]]></dc:creator>
            <pubDate>Mon, 14 Sep 2020 14:20:21 GMT</pubDate>
            <atom:updated>2020-09-14T16:56:51.204Z</atom:updated>
            <content:encoded><![CDATA[<p>How to increase Linux File System Online using parted</p><p>In this blog, we will discuss, how to increase the block volume size online and we will explore the steps how to increase the file system size on Linux. This will be the <strong>two step</strong> process, first we need to Increase the block volume size from Console and next we have to increase the partition on the Linux server using the parted utility.</p><h4><strong>Step A : Increase Block Volume Size from the Console</strong></h4><p>Login to the Console</p><p>Take the Block Volume Backup for safer side.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/866/1*V8xGOSgLKk47lgXCFPSpYg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lB0aUjX6PJSbPe2Mh5sGkg.png" /></figure><p>Once block volume backup completed, go to <strong>Block Volume and Click on Edit and Specify the New Size</strong>. This will take few seconds to provisioning, once it is done, you are good to go on Linux side.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/807/1*txjDt19GkgH_3YvAGrmIug.png" /></figure><p>Also <strong>remember to enable auto tune</strong> if not already as it will save you few bucks by converting the block volume performance to the Lower mode automatically if you are not attached block volume to any instance</p><h4>Step B: Increase the file system size, using the parted utility</h4><p>Run the <strong>lsblk </strong>to identify the partition to which block volume is attached. Example: /dev/sdf</p><blockquote><em>If you face any problem understanding the below steps, you can also check the screenshot at the end of the document.</em></blockquote><p>After identifying the correct partition, run the rescan command, as per below. Remember to replace the partition (/dev/sdf) with your respective partition.</p><p><strong><em>sudo dd iflag=direct if=/dev/sdf of=/dev/null count=1</em></strong></p><p><strong><em>echo “1” | sudo tee /sys/class/block/`readlink /dev/sdf | cut -d’/’ -f 2`/device/rescan</em></strong></p><p>Now call the parted utility.</p><p><strong><em>parted /dev/sdf</em></strong></p><p>When you run the parted, you may encounter the below message. You are then prompted to fix the error or ignore the error and continue with the current setting. Specify the option to fix the error.</p><pre>Warning: Not all of the space available to &lt;volume_id&gt; appears to be used, <br>you can fix the GPT to use all of the space (an extra volume_size blocks) <br>or continue with the current setting?</pre><p>Now run the below commands, in <strong><em>parted </em></strong>utility.</p><p><strong><em>(parted) unit s</em></strong></p><p><strong><em>(parted) print</em></strong></p><p><strong><em>(parted) rm &lt;partition_number&gt;</em></strong></p><blockquote>&lt;partition_number&gt; is the value from the <strong>Number</strong> column.</blockquote><p>Now, enter the below command.</p><p><strong><em>(parted) mkpart</em></strong></p><blockquote>At the <strong>Start? </strong>prompt, specify the value from the <strong>Start</strong> column. At the <strong>File system type</strong>? prompt, specify the value from the <strong>File system</strong> column. Specify <strong>100%</strong> for the End? prompt.<strong></strong></blockquote><p>Exit the parted utility.</p><p><strong><em>(parted) quit</em></strong></p><p>To verify that the root partition was extended, run the <strong><em>lsblk </em></strong>command.</p><h4>After you extend the root partition you need to grow the file system.</h4><p>Below is shown example for ext4 file system.</p><p><strong><em>resize2fs /dev/sdf</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/728/1*lqzOvveSeyepgvcgBLupqw.png" /></figure><p>Boom, you did it ! You can now check the <em>df -h </em>to confirm. If anything goes wrong, you will still have the backup of block volume and if all goes well remember to delete the block volume backup if not required.</p><h4>References:</h4><p><a href="https://docs.cloud.oracle.com/en-us/iaas/Content/Block/Tasks/rescanningdisk.htm">https://docs.cloud.oracle.com/en-us/iaas/Content/Block/Tasks/rescanningdisk.htm</a></p><p><a href="https://docs.cloud.oracle.com/en-us/iaas/Content/Block/Tasks/extendingblockpartition.htm">https://docs.cloud.oracle.com/en-us/iaas/Content/Block/Tasks/extendingblockpartition.htm</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ce3250f47d6a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Email Delivery Setup with Sendmail in Oracle Cloud]]></title>
            <link>https://pareshzawar.medium.com/email-delivery-setup-with-sendmail-in-oracle-cloud-2797a4239f5a?source=rss-afc1f5c6f184------2</link>
            <guid isPermaLink="false">https://medium.com/p/2797a4239f5a</guid>
            <category><![CDATA[smtp-relay]]></category>
            <category><![CDATA[email-delivery]]></category>
            <category><![CDATA[oracle-cloud]]></category>
            <category><![CDATA[linux]]></category>
            <category><![CDATA[oracle-cloud-training]]></category>
            <dc:creator><![CDATA[Paresh Zawar]]></dc:creator>
            <pubDate>Wed, 02 Sep 2020 10:43:48 GMT</pubDate>
            <atom:updated>2020-09-02T10:43:48.731Z</atom:updated>
            <content:encoded><![CDATA[<h4>How to use Oracle Email Delivery Service</h4><h4>RELAY the mails to Oracle SMTP Server from Linux Server</h4><p>Before we start make sure whether email delivery setup has already been done or not, before making any changes. (It’s advisable to check in and each compartment for safety purpose). And check whether you are receiving any mail from server using sendmail.</p><blockquote>echo “Test email from server, testing email delivery” | mail -s -v “Test Email Delivery Setup” &lt;your_email_address&gt;</blockquote><p>This will be <strong>two-step process;</strong> in first step we will be s<strong>etting up the Oracle Email Delivery</strong> using the Console and in second step we will be<strong> configuring the sendmail from Linux server.</strong></p><h3>Step A: Setup Email Delivery in OCI</h3><p>Brief Overview:</p><ol><li>Create a Policy.</li><li>Create Approved Sender.</li><li>Generate SMTP Credentials, if not generated.</li><li>Use Suppression limit, if you want to stop sending emails to particular address.</li><li>Make sure you already have configured the SPF.</li></ol><h4>1. Create a Policy</h4><p>Below example is showing policy created at tenancy level, whereas you can create the policy at the compartment level as well.</p><blockquote><strong>Allow group Administrators to manage approved-senders in tenancy</strong></blockquote><p>For Suppression List, add below statement as well.</p><blockquote><strong>Allow group Administrators to manage suppressions in tenancy</strong></blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1009/1*BTG2GnhdB_uX7PxHyjXQlg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZLrrUKOZzVs3s7WklehEYw.png" /></figure><h3>2. Create Approved Sender</h3><p>Find out the Domain Name of the company. (Eg oracle.com). So that approved sender will be like this.</p><p><strong>username@domain_name</strong></p><blockquote>Example: no-reply@oracle.com</blockquote><p><strong>If you are not using the masquerade, then add the Approved Sender as below.</strong></p><p>First get FQDN from server, use below command for fully qualified domain name.</p><blockquote><em>hostname -f</em></blockquote><blockquote>username@fqdn</blockquote><p>Navigation to create the Approved Sender from OCI Console</p><p><strong>Hamburger Menu → Solutions and Platform → Email Delivery → Email Approved Sender</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/555/1*nGgQThW7dnBttqCQH3KzdA.png" /></figure><p>Now, <strong>Click on Create Approved Sender</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/665/1*g2Tfsg5g0UAEWm2cmBF0oA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/680/1*M_c8jNX6PQnwlSCIQipvow.png" /></figure><h4>3. Generate SMTP Credentials, if not generated. (This is very important)</h4><p>Navigation:</p><p><strong>Hamburger Menu → Solutions and Platform → Email Delivery → Email Configuration</strong></p><p>Note: This is very important step, note down all the details mentioned below, which will be useful in configuring sendmail.</p><p>1. SMTP Server Name</p><p>2. SMTP OCID</p><blockquote>3. <strong>Password of user. (This is very crucial to save, as there’s no option to get the password back)</strong></blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/703/1*rVeTeohEpTUDee6yEfDPcQ.png" /></figure><p>In above picture underlined URL is our SMTP Server Name. Next, click on <strong>Manage SMTP Credentials</strong> and Generate SMTP Credentials.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/702/1*Q3LpR3lGlhgaobRiaJH6jA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/619/1*mIcF3FzEy5ett7iJspSP4w.png" /></figure><p>Copy this Username and Password and SMTP Server Name, and we will now configure the sendmail side, and we are done with Step A.</p><h3>Step B: <strong>Configure Sendmail on Linux Server</strong></h3><p>Now logon to the server from where you want to send email. And connect as a root user/user which have sudo access.</p><p>Brief Description:</p><ol><li>Make sure sendmail and m4 are installed already.</li><li>Create Authfile.</li><li>If you are using the PLAIN Authentication then make sure <strong>cyrus-sasl-plain </strong>is installed.</li><li>Add RELAY.</li><li>Backup Sendmail config file.</li><li>Update the sendmail.mc</li><li>Restart the sendmail.</li></ol><h4><strong>1. Make sure sendmail and m4 are installed already.</strong></h4><p>Use below command to verify if sendmail is installed or not, if not install using the yum repository only.</p><blockquote><em>rpm -qa sendmail</em></blockquote><blockquote><em>rpm -qa m4</em></blockquote><p>If not already installed,</p><blockquote><em>yum install -y sendmail</em></blockquote><blockquote><em>yum install -y m4</em></blockquote><h4>2. Create Authfile.</h4><p>This is important step again, re-collect all the information gathered in step A Modify the authinfo file, create it if not exist already, and take a backup of original one before modifying it.</p><blockquote>vi /etc/mail/authinfo</blockquote><p>Add the following lines:</p><pre>AuthInfo:&lt;SMTP connection endpoint&gt; &quot;U:root&quot; &quot;I:&lt;username from smtp credentials&gt;&quot; &quot;P:&lt;password from smtp credentials&gt;&quot; &quot;M:PLAIN&quot;<br>#write and quit file<br>:wq!</pre><p><strong>Fill the details in brackets &lt; &gt;</strong></p><ol><li>SMTP Connection endpoint is your SMTP Server Name. (example: smtp.us-phoenix-1.oraclecloud.com)</li><li>Username from smtp credentials will be your user OCID (example: ocid1.user.oc1..abcd@ocid1.tenancy.oc1..abcd)</li><li>Password from SMTP Credentials will be your password.</li></ol><p>After filling the details save the file and exit (wq!)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FfG7yZG-8B6aj5CLydelVQ.png" /></figure><p><strong>Now, Generate the /etc/mail/authinfo.db file. </strong>Run the following command:</p><blockquote>sudo sh -c ‘makemap hash /etc/mail/authinfo.db &lt; /etc/mail/authinfo’</blockquote><p>Add support for relaying to the Oracle Cloud Infrastructure Email Delivery SMTP endpoint. Run the following command:</p><blockquote>sudo sh -c ‘echo “Connect:&lt;SMTP connection endpoint&gt; RELAY” &gt;&gt; /etc/mail/access’</blockquote><p><strong>Regenerate /etc/mail/access.db. </strong>Run the following command:</p><blockquote>sudo sh -c ‘makemap hash /etc/mail/access.db &lt; /etc/mail/access’</blockquote><p><strong>Create a backup of the sendmail.cf and sendmail.mc files. </strong>Run the following command:</p><blockquote>sudo sh -c ‘cp /etc/mail/sendmail.cf /etc/mail/sendmail_cf.backup &amp;&amp; cp /etc/mail/sendmail.mc /etc/mail/sendmail_mc.backup’</blockquote><p><strong>Update the /etc/mail/sendmail.mc file.</strong></p><p>Run the following command:</p><blockquote>sudo vi /etc/mail/sendmail.mc</blockquote><h4>Find the MAILER() definitions.</h4><p>Type /MAILER and press ENTER.</p><p>In Insert mode, add the <strong>following settings before any MAILER() definitions</strong>:</p><pre>define(`SMART_HOST&#39;, `&lt;SMTP connection endpoint&gt;&#39;)dnl<br>define(`RELAY_MAILER_ARGS&#39;, `TCP $h 25&#39;)dnl<br>define(`confAUTH_MECHANISMS&#39;, `LOGIN PLAIN&#39;)dnl<br>FEATURE(`authinfo&#39;, `hash -o /etc/mail/authinfo.db&#39;)dnl<br>MASQUERADE_AS(`&lt;sending_domain&gt;&#39;)dnl<br>FEATURE(masquerade_envelope)dnl<br>FEATURE(masquerade_entire_domain)dnl</pre><p>Example:</p><pre>define(`SMART_HOST&#39;, `smtp.us-ashburn-1.oraclecloud.com&#39;)dnl<br>define(`RELAY_MAILER_ARGS&#39;, `TCP $h 25&#39;)dnl<br>define(`confAUTH_MECHANISMS&#39;, `LOGIN PLAIN&#39;)dnl<br>FEATURE(`authinfo&#39;, `hash -o /etc/mail/authinfo.db&#39;)dnl<br>MASQUERADE_AS(`abc.com&#39;)dnl<br>FEATURE(masquerade_envelope)dnl<br>FEATURE(masquerade_entire_domain)dnl</pre><p>Make Sendmail writeable. Run the following command:</p><blockquote>sudo chmod 666 /etc/mail/sendmail.cf</blockquote><p><strong>Regenerate sendmail.cf. </strong>Run the following command:</p><blockquote>sudo sh -c ‘m4 /etc/mail/sendmail.mc &gt; /etc/mail/sendmail.cf’</blockquote><p>Note: If you receive an error, such as “Command not found” or “No such file or directory,” confirm that the m4 and sendmail packages are installed on your system.</p><p>Reset permissions for sendmail.cf to read only. Run the following command:</p><blockquote>sudo chmod 644 /etc/mail/sendmail.cf</blockquote><p>Restart Sendmail. Run the following command:</p><blockquote>sudo service sendmail restart</blockquote><p>Test the configuration by sending a test email. Run the following command:</p><blockquote>echo “Test email from server, testing email delivery” | mail -v -s “Test Email Delivery Setup” &lt;your_email_address&gt;</blockquote><p>Known Issue:</p><p>If you now restart sendmail and you will receive the following error in /var/log/maillog</p><blockquote>(1002/1007), delay=00:00:01,xdelay=00:00:01, mailer=relay, pri=120587, relay=smtp.us-phoenix-1.oraclecloud.com. [138.1.38.16],dsn=4.0.0, stat=Deferred: <strong>Temporary AUTH failure</strong></blockquote><p><strong>Solution:</strong></p><p>We still need package <strong>cyrus-sasl-plain</strong> installed, I’ve enabled public Oracle Linux repo to get it installed:</p><blockquote><em>yum -y install cyrus-sasl-plain</em></blockquote><blockquote>NOTE:</blockquote><blockquote>1. Please check pricing details before implementing the changes.</blockquote><blockquote>2. Also make sure you have SPF configured properly.</blockquote><blockquote>3. And you can send mails up to 2 MB size only and this is not configurable as of now.</blockquote><blockquote>4. Checkout below blogpost for more FAQs on Email Delivery.</blockquote><blockquote><a href="https://www.oracle.com/in/cloud/networking/email-delivery-faq.html">https://www.oracle.com/in/cloud/networking/email-delivery-faq.html</a></blockquote><p><strong>References:</strong></p><ul><li><a href="https://docs.cloud.oracle.com/en-us/iaas/Content/Email/Concepts/overview.htm">Overview of the Email Delivery Service</a></li><li><a href="https://www.thatfinnishguy.blog/2019/08/21/configuring-oci-email-delivery-with-oci-exadata-to-send-emails/">Configuring OCI Email Delivery with OCI Exadata to send emails</a></li><li><a href="https://www.oracle.com/in/cloud/networking/email-delivery-faq.html">Email Delivery FAQ</a></li></ul><p><a href="https://docs.cloud.oracle.com/en-us/iaas/Content/Email/Reference/sendmail.htm">https://docs.cloud.oracle.com/en-us/iaas/Content/Email/Reference/sendmail.htm</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2797a4239f5a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[ADOP : Online Patching Oracle EBS R12.2]]></title>
            <link>https://pareshzawar.medium.com/adop-online-patching-oracle-ebs-r12-2-bae66b800e7d?source=rss-afc1f5c6f184------2</link>
            <guid isPermaLink="false">https://medium.com/p/bae66b800e7d</guid>
            <category><![CDATA[oracle-apps-dba]]></category>
            <category><![CDATA[oracle-r12]]></category>
            <category><![CDATA[oracle-dba]]></category>
            <category><![CDATA[oracle-adop]]></category>
            <category><![CDATA[oracle-patching]]></category>
            <dc:creator><![CDATA[Paresh Zawar]]></dc:creator>
            <pubDate>Wed, 02 Sep 2020 05:43:28 GMT</pubDate>
            <atom:updated>2020-09-02T05:43:28.080Z</atom:updated>
            <content:encoded><![CDATA[<h3>ADOP : Online Patching Oracle EBS R12.2</h3><p>Before Oracle Application R12.2 we need to shutdown application tier to apply patch on production environment and downtime depends on multiple factors, scheduled lengthy downtime window were major problem from more than last two decades in single instance environment in R12.1 and earlier versions of Oracle Apps. Oracle R12.2 finally comes with solution to this by introducing ADOP (Application DBA Online Patching) tool where users can be still connected to system while patch being applied to the system. And very small downtime independents of all factors unlike in R12.1 and older version. Users gets disconnected only during cutover phase. Here in this blog we will discuss about adop.</p><p>There are <strong>five </strong>important stages in ADOP to apply patch on the system. Listed as per below:</p><ol><li>Prepare File System</li><li>Apply Patch</li><li>Finalize</li><li>Cutover</li><li>Cleanup</li></ol><figure><img alt="http://drive.google.com/open?id=0Byna3r00epbyWFZwTGxHUVFDYUE" src="https://cdn-images-1.medium.com/max/1024/1*mUf_T_0OrC6gjUxdspw8FQ.png" /></figure><p><strong>In Brief:</strong></p><p><strong><em>adop phase=prepare : </em></strong>A copy is made from the running file system which resides in both file system as well as database.</p><p><strong><em>adop phase=apply patches=&lt;patch_number&gt; &amp;</em></strong></p><p><strong><em>adop phase=finalize</em></strong></p><p>Patches are applied to the copied file system while users continue to access the running system.</p><p><strong><em>adop phase=cutover : </em></strong>The copied file system becomes the new running system</p><p><strong><em>adop phase=cleanup : </em></strong>The original running system (now obsolete) is recycled for use in future patching cycles.</p><p><strong>Benefits of ADOP:</strong></p><ol><li>Patching downtime time can now be measured in terms of minutes rather than hours, only being limited by the time it takes to bounce the Application processes in the Middle Tier.</li><li>All patches and maintenance packs are applied online, requiring only a short cutover period.</li><li>Maintenance windows can now be better planned</li><li>Only a minimal patching disruption time is required</li></ol><p><strong>File System in R12.2:</strong></p><p>Oracle Application R12.2 comes with three different types of file system.</p><ol><li><strong>Run File System:</strong> Systems where users are connected and online. The Run Edition includes a complete application-tier file system along with all objects and data visible in the default edition of the database. Assume fs1 as current run file system in below example.</li><li><strong>Patch File System:</strong> Systems where patches are applied. Users don’t have access to this file system. Assume fs2 as current patch file system.</li><li><strong>Non-Editioned File System (fs_ne):</strong> File system which remains consistent during all the patching cycle and contain details regarding patches applied on systems.</li></ol><p>All three file systems forms Oracle Application R12.2 and connects to Oracle Database as described in below diagram.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/708/1*fHvsbA7kdEkV7VNbzXOZmw.png" /></figure><p>fs1 and fs2 are interchanged after cutover phase, as shown in below picture.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Evl-27FafJyZKHgOi5docg.png" /></figure><p><strong>Connecting to the Run Edition and Patch Edition :</strong></p><p>Sourcing the APPS environment in R12.2 , is totally different than earlier version of Oracle Apps. The below picture shows how to source environment in Apps R12.2 and connect to run file edition.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/575/1*SKVZHiMHaM4_5gBF4_IIsA.png" /></figure><p>End users can only connects to run file systems but developers may also want to connect the patch file system. Hence we have also covered connecting to patch file edition, as shown in below picture.</p><p><strong>Warning</strong>: It is only safe to connect to the patch edition while an Online Patching session is in progress. Specifically, the Patch Edition is active after the “adop phase=prepare” operation, and persists until the cutover or abort operation is run.</p><p>The application-tier Patch Edition environment is configured to connect to the database patch edition by default. If a database patch edition is not active, then attempting to connect to the database from the application-tier patch edition environment will fail.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/610/1*TyGaAifPlYTH1ljgikMHdw.png" /></figure><p>As shown in above picture the highlighted red boxes indicates that we can also check the current file edition system in which we are working.</p><p><strong>Edition-Based Redefinition (EBR):</strong></p><p>Traditionally, applications such as Oracle E-Business Suite have had to be unavailable while their associated database objects are patched or upgraded. The Edition-Based Redefinition (EBR) feature of the Oracle 11gR2 Database allows this downtime to be avoided.</p><p>Every database has at least one edition, and can support multiple editions. A new edition is created as a child of an existing edition. The changes are made in the child edition, while the parent edition remains available for use. Changes to data (such as when a patch is applied) are made by writing only to new columns or new tables not seen by the old edition.</p><p>EBR allows an application’s database objects to be changed without interrupting the application’s availability. For example, an Oracle E-Business Suite patch can be applied while users are logged in and active. This is accomplished by making the changes in the privacy of a new edition.</p><p><strong>Key objects used by EBR include:</strong></p><ol><li>Editioning views expose a different projection of a changed table to each edition, allowing each to see only its own columns.</li><li>Cross-edition triggers propagate data changes made by the old edition into the columns of the new edition, which subsequently replaces the old edition</li></ol><p>More number of active database editions also causes the problem as it increases the inheritance hence more time required to fetch the objects from older editions and cause the slower database performance.</p><p>For more information on the Edition-Based Redefinition feature introduced on Oracle Database 11gR2 see the following:</p><p><a href="http://docs.oracle.com/cd/E11882_01/appdev.112/e41502/adfns_editions.htm#ADFNS020">Edition-Based Redefinition</a> of the Oracle Database Advanced Application Developer’s Guide 11g Release 2 (11.2) — E41502</p><p><strong>Prepare</strong></p><p>Before applying a patch, you must start an Online Patching Cycle. This is done using the adop “prepare” command. Connect to the primary application-tier node of your target system and source the run edition environment. Then execute the prepare command.</p><p><em>adop phase=prepare</em></p><p>The adop utility may first execute the cleanup phase from the previous cycle if needed, and will then proceed to prepare the patch edition for a new Online Patching Cycle. To prepare the patch edition, adop will:</p><ol><li>Validate that the system is ready to start a new patching cycle.</li><li>Create a new database patch edition</li><li>Synchronize the file system patch edition with the run edition</li><li>Configure the patch edition for use by the patching tools</li></ol><p>File system synchronization may be done by applying the delta (changes) from the previous patching cycle, or by re-creating the entire patch edition file system as a fresh copy of the run edition (called “fs_clone”). When complete, check the exiting status code (success is ‘0’):</p><p>If there were any problems with the prepare phase, check <a href="http://support.oracle.com/epmos/faces/DocumentDisplay?_afrLoop=385126376504376&amp;id=1577661.1&amp;_afrWindowMode=0&amp;_adf.ctrl-state=177f6ivcj1_4#S7">Troubleshooting</a> and resolve the problem. Then run the prepare command again.</p><p>After a successful prepare phase, the database and file system patch edition will contain a copy of the run edition code and seed data. You can now apply patches to the patch edition.</p><p><strong>Apply</strong></p><p>Once the Patch Edition is prepared, you can apply any number of patches to the patch edition. Changes to the patch edition are isolated from the run edition, which is still available for use.</p><p>Before applying an patch, you must first download the patch bundle from the web user interface (<a href="http://support.oracle.com/epmos/faces/MosIndex.jspx">support.oracle.com</a>). The downloads will be in the form of ZIP files. Place the ZIP files in the “$PATCH_TOP” directory on the application-tier installation of your target application system, and then unzip all ZIP files.</p><p>Patches are applied to the patch edition using the “adop phase=apply” command. The command accepts a “patches=…” parameter where you can specify a single patch or a comma-separated list of patches.</p><p><em>adop phase=apply patches=16605855 </em>… <em>adop phase=apply patches=15111111,15222222</em> …</p><p>Note that the adop command will apply patches to the patch edition no matter what edition your current environment is set to.</p><p>If the adop apply commands fail, check <a href="http://support.oracle.com/epmos/faces/DocumentDisplay?_afrLoop=385126376504376&amp;id=1577661.1&amp;_afrWindowMode=0&amp;_adf.ctrl-state=177f6ivcj1_4#S7">Troubleshooting</a> and correct the problem, then run the adop apply command again, adding the “restart=yes” option.</p><p><em>adop phase=apply patches=16605855 restart=yes</em></p><p>In some cases, an error when applying a patch can be corrected by applying a replacement patch. You can abandon an existing failed patch and apply the replacement patch by running the apply command with the “abandon=yes” parameter.</p><p><em>adop phase=apply patches=16699999 abandon=yes</em></p><p><strong>Finalize</strong></p><p>The finalize phase is used by the Online Patching tool to perform any final actions needed to make the system ready for the fastest possible cutover. The finalize command is run as follows:</p><p><em>adop phase=finalize</em></p><p>If the finalize command returns an error, the system is not ready for cutover. In this case, check <a href="http://support.oracle.com/epmos/faces/DocumentDisplay?_afrLoop=385126376504376&amp;id=1577661.1&amp;_afrWindowMode=0&amp;_adf.ctrl-state=177f6ivcj1_4#S7">Troubleshooting</a> correct the problem and run the finalize command again.</p><p>After successful completion of the finalize phase, the system is ready for cutover, but you do not need to execute the cutover right away; you can delay executing cutover until a convenient or predetermined time in the future. You may also apply additional patches if needed, but you will need to run the finalize phase again after doing so.</p><p><strong>Cutover</strong></p><p>The cutover phase will configure the patch edition to become the new run edition, and restart the application on this new run edition.</p><p><em>adop phase=cutover</em></p><p>After successful completion of the cutover phase, the application will be up and running on the new edition, ready for use. Since the run/patch designation of the dual file systems are swapped during cutover, you must re-source the run edition environment directly after cutover.</p><blockquote><strong>Important:</strong></blockquote><blockquote><strong>Remember to re-source the run edition environment directly after cutover.</strong></blockquote><blockquote><strong>If cutover fails there is no option to redirect back except restoration.</strong></blockquote><p>You can also check-out my below blog post for best practices while patching with ADOP</p><p><a href="https://link.medium.com/prYVhCrDr9">Best Backup Practices while using Online Patching(adop) in R12.2</a></p><p><strong>Cleanup</strong></p><p>The cleanup phase will remove unnecessary code and data from old editions that are no longer needed by the application. Cleanup should be run after cutover, at any time before the next prepare phase. It is best to run cleanup immediately after cutover so that there is no delay when preparing the next online patching cycle. There are three levels of cleanup available:</p><ul><li>quick — the minimal cleanup required before starting the next patching cycle.</li><li>standard — (default) removes obsolete code and seed data from old editions.</li><li>full — removes all obsolete code, data, and table columns.</li></ul><p>Standard cleanup is the default, and is recommended to avoid a buildup of obsolete code objects in old editions.</p><p><em>adop phase=cleanup</em></p><p>Use quick cleanup when you need to start the next patching cycle as soon as possible.</p><p><em>adop phase=cleanup cleanup_mode=quick</em></p><p>Use full cleanup to remove obsolete table columns. Full cleanup is required after aborting an online patching cycle.</p><p><em>adop phase=cleanup cleanup_mode=full</em></p><p><strong>Special Patching Action</strong></p><p>There are some more useful patching action in adop, which are also listed here.</p><p><strong>fs_clone</strong></p><p>The “fs_clone” command recreates the patch edition file system by making a full copy of the run edition file system. This command is required when the patch edition file system cannot be automatically synchronized with the run edition file system by adop. Run the fs_clone command if you have done any of the following actions:</p><ul><li>Applied middle-tier technology patches to the run edition</li><li>Changed run edition files manually (outside of online patching)</li><li>Aborted an online patching cycle</li></ul><p>The fs_clone command is executed as follows:</p><p><em>adop phase=fs_clone</em></p><p><strong>Abort</strong></p><p>If an online patching cycle has failed for some reason that cannot be corrected, you can abort the online patching cycle and return to normal operation. The adop “abort” command drops the database patch edition and removes or abandons any changes made during the the online patching cycle. If the online patching cycle has completed the cutover phase, then you can no longer abort the patching cycle.</p><p>When aborting an online patching cycle, you must also run the cleanup and fs_clone commands to fully eliminate changes from the patching cycle. The abort command is run as follows:</p><p><em>adop phase=abort adop phase=cleanup adop phase=fs_clone</em></p><p><strong>Tools and Scripts for Edition-based Development:</strong></p><p>There are a number of SQL*Plus scripts that can provide useful information about the state of your editioned development environment. All <strong>ADZD* </strong>scripts are found under <strong>$AD_TOP/sql.</strong></p><ul><li>ADZDDBCC — database compliance checker, shows violations of the database object development standards documented in the Oracle E-Business Suite Developer’s Guide, Part No. E22961. Warning: this script takes a long time to run.</li><li>ADZDSHOWED — Show database editions and current edition.</li><li>ADZDSHOWLOG — Show full diagnostic log for online patching infrastructure.</li><li>ADZDSHOWLOGEVT — Show only event and error messages from online patching diagnostic log (a useful summary, without the detailed statement text).</li><li>ADZDSHOWLOGERR — Show only error messages from online patching diagnostic log.</li><li>ADZDSHOWEV TABLE_SYNONYM_NAME — Show editioning view column mapping for table.</li><li>ADZDSHOWTAB TABLE_SYNONYM_NAME — Show table information and related objects.</li><li>ADZDSHOWMV MVIEW_NAME — Show materialized view information and related objects.</li><li>ADZDSHOWTS — Show important tablespace status. Ensure that you have enough SYSTEM tablespace.</li><li>ADZDCMPED — Compare Patch Edition with Run Edition. Warning: this script may take a long time to run.</li><li>ADZDSHOWDDLS — Show stored DDL summary by phase.</li><li>ADZDALLDDLS — Show stored DDL statement text.</li><li>ADZDDDLERROR — Show stored DDL execution errors and messages.</li><li>adutlrcmp — Recompile all objects, with before/after status report. Warning: this script may take a long time to run.</li></ul><p>The following scripts are for experts:</p><ul><li>ADZDSHOWOBJS — Show Object Summary per edition. Counts of actual and stub (inherited) editioned object per edition.</li><li>ADZDSHOWAOBJS — Show Actual Objects in the current edition. These are the editioned objects that have been changed by the patch.</li><li>ADZDSHOWIOBJS — Show Inherited Objects in the current edition. These are the editioned objects that remain untouched in the patch edition. This script is used to confirm that the adop actualize_all command has worked properly.</li><li>ADZDSHOWCOBJS — Show Covered Object Summary per edition. Count of objects in old editions that have a replacement in the run edition. This script is used to confirm that the adop cleanup command has worked properly.</li><li>ADZDSHOWCOBJX — Show Covered Object List. List of objects in old editions that have a replacement in the run edition.</li><li>ADZDSHOWSM — Show Seed Manager status.</li><li>ADZDSHOWTM — Show Table Manager status.</li><li>ADZDSHOWAD — AD (online patching) database object status</li><li>ADZDSHOWSES — Show sessions connected to the database (by edition).</li><li>ADZDSHOWDEP OBJECT_NAME — Show objects that OBJECT_NAME depends on.</li><li>ADZDSHOWDEPTREE OBJECT_NAME — Show full dependency tree of objects that OBJECT_NAME depends on.</li></ul><p><strong>ADOP Parameters</strong></p><p>Below table shows all the useful commands used in ADOP tool. You can always use <strong><em>adop -help</em></strong> to get online help at any point of time. It is also nice practice to use <strong><em>adop -status</em></strong> command before running of every phase of adop.</p><p><strong>References:</strong></p><ol><li>Doc ID 1590494.1 : Patching &amp; Maintenance Advisor: E-Business Suite (EBS) R12.2</li><li>Doc ID 1355068.1 : Oracle E-Business Suite 12.2 Patching Technology Components Guide</li><li>Doc ID 1577661.1 : Developing and Deploying Customizations in Oracle E-Business Suite Release 12.2</li><li><a href="http://abhinavkotnala.wordpress.com/category/oracle-e-business-suite-r12-2/">https://abhinavkotnala.wordpress.com/category/oracle-e-business-suite-r12-2/</a></li><li>Oracle E-Business Suite Maintenance Guide Release 12.2 Part No. E22954–21</li></ol><p><strong>More reference for troubleshooting</strong></p><p><strong>1. </strong><a href="https://k21academy.com/oracle-apps-dba-r12/adop-prepare-phase-issue-fs_clone-failed-weblogic-management-scripting-scriptexception/">https://k21academy.com/oracle-apps-dba-r12/adop-prepare-phase-issue-fs_clone-failed-weblogic-management-scripting-scriptexception/</a></p><p>Originally posted at</p><p><a href="https://pareshzawar.wixsite.com/tech/post/2017/04/27/adop-online-patching-oracle-ebs-r122">https://pareshzawar.wixsite.com/tech/post/2017/04/27/adop-online-patching-oracle-ebs-r122</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bae66b800e7d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Best Backup Practices while using Online Patching(adop) in R12.2]]></title>
            <link>https://pareshzawar.medium.com/best-backup-practices-while-using-online-patching-adop-in-r12-2-e65ec74a5b93?source=rss-afc1f5c6f184------2</link>
            <guid isPermaLink="false">https://medium.com/p/e65ec74a5b93</guid>
            <category><![CDATA[oracle]]></category>
            <category><![CDATA[adops]]></category>
            <category><![CDATA[oracle-dba]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[oracle-apps-dba]]></category>
            <dc:creator><![CDATA[Paresh Zawar]]></dc:creator>
            <pubDate>Tue, 28 May 2019 09:28:15 GMT</pubDate>
            <atom:updated>2019-11-28T04:40:15.966Z</atom:updated>
            <content:encoded><![CDATA[<h4>How to Deal with Cutover Phase in R12.2 (ADOP)</h4><h4>Rollback Patch even after cutover phase in Oracle Apps R12.2 using Oracle Database Flashback</h4><p>If you are applying patch in Oracle Apps R12.2 using ADOP and your development team comes and request for the patch rollback. You will simply going to run <em>adop phase=abort</em> and your patch will be rollback and development team will be happy for having such a nice and wonderful DBA. But this will be easy only if you haven’t run the cutover phase yet. Suppose you are in middle of cutover phase or you have already executed the cutover phase then you will be left high and dry in such a situation to rollback the patch and will be very angry or upset on your developers. If you have taken application as well as database backup before applying the patch then only you will be able to rollback the patch by restoring to the latest backup.</p><p>One of the best feature of Oracle EBS R12.2 is ADOP tool. And great thing about ADOP is the ability to rollback the patch and changes created by the patch, but this roll back will be available till you run the cutover phase. Once the cutover is executed, the changes being made by apply phase are committed, and cannot be rolled back. This constraint brings requirement of taking backup each time patch being applied. Taking backup each time before applying the patch will require lot of time whether it is hot backup or cold backup.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*x12VhnM-9eX25ueIEJ57yg.png" /><figcaption>Cutover Failure</figcaption></figure><p>The problem here is not actually the method of the backup. It is the backup operation itself that creates the cost. In other words, taking a backup before applying every online patch in EBS 12.2 is not so applicable, as it costs so much that it complicates the patching operation and it increases the backup maintenance operations; therefore, it even reduces the benefits of using online patching.</p><p>So here we are with different approach of backup and guaranteed roll back to the state of system before applying the patch. We will take a use of <strong>Oracle Database Flashback</strong> feature in this method and restarting the application services from the relevant file system edition depending on whether the decision to roll back the system is done before the file systems were switched.</p><p>Discuss a scenario in which we actually need to roll back the system after the cutover phase has been run. After the finalize phase you execute <strong><em>adop phase=cutover</em></strong>, but cutover fails. Suppose you try to fix the problem, causing cutover to fail (as Oracle suggests so) but could not fix it. The only option left is go back to a state before you cutover phase and roll back the changes done in the database and application tiers. To do so we need to have a backup that can restored and used for recovering the database just before running the cutover phase. However, taking an online backup in the cutover phase extends the time needed for patching,and therefore it is not applicable for every patch. If patch size is small (suppose 10KB), to guarantee a roll back in case of failure we need to backup our EBS environment which large is size (generally in GB). So backing up the environment before cutover would increase the patching window time even to apply small size patch. And also would cost us side effects such as heavy I/O created by backup jobs. So taking full backup before applying a small patch is not a great idea and similarly restoring the full backup will be time consuming process, and it will also not a great idea to used in case of patching failure.</p><p>So, Let’s go back where we have started and illustrate this scenario again, but this time we will use the flashback option and a couple of application tier operations to restore your EBS 12.2 system to the state it was in before the online patching cutover phase was run</p><p><strong>Backing Up:</strong></p><p>In this section we will learn how to backup the EBS before cutover.</p><p><strong>Step 1:Enable Flashback</strong></p><p>Enable flashback and configure it with four settings accordingly, before starting the patching cycle, as follows:</p><p>alter system set db_recovery_file_dest=&#39;/some_path/&#39; scope=BOTH SID=&#39;*&#39;;</p><p><strong>db_recovery_file_dest</strong> is set to a directory where the flashback logs are placed. It can set to an ASM disk group, as well.</p><p>alter system set db_recovert_file_dest_size=100G scope=BOTH SID=&#39;*&#39;;</p><p><strong>db_recover_file_dest_size</strong> is where flashback is placed; the size of the db_recovery_file_dest should be set according to our needs. It actually depends on how long we want to store the flashback logs. Also in addition to the flashback logs if we place our rman backups and online redo logs in the database recovery file destination, then we also need to consider them for setting the db_recovery_file_dest_size.</p><p>alter system set db_flashback_retention_target=120;</p><p><strong>db_flashback_retention_target</strong> is set to a value which actually represents the upper limit in minutes on how far back in time the database may be flashed back.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/508/1*vZmUmamBwSZ21Xb7epgXKQ.png" /></figure><p>alter databse flashback on;</p><p>By executing “alter database flashback on”, flashback in the Database gets activated.</p><p><strong>Step 2: Create a Flashback Restore Point</strong></p><p>The next thing to do is to create a flashback restore point, this restore point may be created just before starting the patching cycle or preferably just before the cutover phase.</p><p><strong>NOTE:</strong></p><blockquote>1. Stop the web services.</blockquote><blockquote>2. Stop the concurrent managers or put the schedule concurrent requests on hold.</blockquote><blockquote>3. Stop database-bound third-party applications or cut off their database connections.</blockquote><blockquote>4. Force a log switch.</blockquote><blockquote>5. Create a guaranteed restore point.</blockquote><blockquote>6. Force another log switch.</blockquote><blockquote><strong>Guaranteed restore point</strong> assures that the database will maintain enough flashback logs to flash back the database to the restore point and by <strong>shutting down the web services</strong> and <strong>putting the critical concurrent requests on hold</strong>, you can ensure that you won’t lose any important transactional data. Also, if there are any other database applications that reach the EBS database via database links or any other non-EBS products using the EBS database (actually there should not be), then they should be stopped or their EBS-related activities should prevented by their application owners.</blockquote><blockquote><strong>It is advisable to create the restore point just before the cutover phase</strong>, because as per the action plan, there are some requirements to stop the application services, which will increase the downtime for the patching operation. So, it is better to create the restore point as late as possible.</blockquote><p>After reviewing and ensuring the recommendations are in place, you continue with creating the patching cycle and completing phases one by one until you reach the cutover phase and creating the restore point as follows. To start patching, you create the patching cycle using the adop phase=prepare command and complete the phases one by one as shown here, until the cutover phase:</p><p>adop phase=fs_clone</p><p>adop phase=prepare</p><p>adop phase=apply</p><p>adop phase=finalize</p><h3>Just before the cutover phase, you create the restore point as follows:</h3><p>alter system switch logfile;</p><p><strong>CREATE RESTORE POINT BEFORE_PATCH GUARANTEE FLASHBACK DATABASE;</strong></p><p>alter system switch logfile;</p><p>Once the restore point is created, you have a database backup that was taken exactly at the time you wanted and can be restored if needed. At this point, you have a backup; thus, you can continue with the critical cutover phase.</p><p>adop phase=cutover</p><h3><strong>Recovering</strong></h3><p>Now suppose you face an unsolvable error during the cutover phase and decide to roll your EBS 12.2 environment back to the state before the patching cycle was started.</p><p><strong>Step 1: Restore Database</strong></p><p>This time, rather than a costly standard database and application file system restore, you can use flashback to restore the database to the restore point named <strong><em>BEFORE_PATCH</em></strong>, which was created just before the cutover phase. To accomplish this, you follow this action plan:</p><ol><li>Shut down the database.</li></ol><p>SQL&gt;shutdown immediate</p><p>2. Start the database in mount mode.<br>SQL&gt;startup mount</p><h4>3. Restore the database to the restore point BEFORE_PATCH using the flashback feature.</h4><p><strong><em>SQL&gt;flashback database to restore point BEFORE_CUTOVER;</em></strong></p><p>4. Start the database in read-only mode.<br><strong><em>SQL&gt;alter database open read only</em></strong></p><p>5. Check the database with simple queries and ensure that there are no abnormalities.<br>6. Shut down the database and open it using the resetlogs option.</p><p><strong><em>SQL&gt;shutdown immediate;<br>SQL&gt;startup mount;<br>SQL&gt;alter database open resetlogs;</em></strong></p><p>By doing the previous actions, you roll back your database to a state before the cutover phase. <strong>After rolling back your database using flashback, you should disable the flashback in the database and leave it to be disabled until the next patching operation.</strong> By doing so, you eliminate the risk of running out of space in FRA, which may be caused by retaining the flashback logs. Note that running out of space will cause the EBS database to hang. The following action plan can be used to accomplish that:</p><p>1. Disable flashback.<br><strong><em>SQL&gt;alter database flashback off;</em></strong></p><p>2. Drop the restore point.<br><strong><em>SQL&gt;drop restore point BEFORE_CUTOVER;</em></strong></p><p>3. Set recovery file destination.<br><strong><em>SQL&gt;alter system set db_recovery_file_dest=’’;</em></strong></p><h4><strong>Step 2: Restore Application File System</strong></h4><p>So far, so good. We have successfully roll back to restore point in EBS 12.2 database using the flashback option in case of a failure that may be encountered during the cutover phase. But what about the application tier file systems? To fully roll back an EBS 12.2 system in the case of a cutover failure, you need to roll back the file systems of the application nodes, too.</p><p>As patching activities change the database objects in the database, they change the file objects in the application file system. Until the cutover phase, all the file object changes are done in the patch file system; likewise, all the database objects changes are done in the patch edition. So, any time before the cutover phase, you can use adop phase=abort and roll back those changes. However, once you start the cutover phase, abort will no longer work, and that’s why you need to do some special actions to roll back the changes done in the cutover phase.<br>For the database tier, it is a little complicated. An operation like rolling back the changes that occurred before the cutover employs using the flashback option, restore points, and so on. However, it is pretty simple for the application tier.</p><p>Suppose you execute the cutover phase during a patching activity and encounter some errors. So, you decide to roll back your EBS system to a state before the cutover phase. To roll back the changes for the database tier, suppose you use the flashback restore point that you created earlier.<br>Just after the database is restored, you continue with rolling back the application tier.</p><blockquote><strong>To do that, you need to know whether the cutover failed before the file systems were switched. You can identify this using the cutover logs </strong>($NE_BASE/EBSapps/log/adop/&lt;current_session_id&gt;/cutover_&lt;timestamp&gt;/ for your session ID).</blockquote><p><strong>If the cutover failed before the file systems were switched,</strong> then you are lucky, as you just need to shut down all the application services and then start all the application services using the run edition environment like in your standard startup procedure.</p><p>If <strong>the log file indicates that cutover failed after the file systems were switched</strong>, then you have to follow a different action plan. That is, if the file systems were switched, then you need to switch back the file systems in order to roll back your application tier to its state before the cutover phase. What you need to do is as follows:</p><blockquote><strong>1. </strong>Source the environment on the current run file system.</blockquote><blockquote>2. Shut down all the application services using the standard procedure (<strong>adstpall.sh</strong>).</blockquote><blockquote>3. Switch back the file system using <strong>txkADOPCutOverPhaseCtrlScript.pl</strong>.</blockquote><blockquote><strong>Usage :</strong></blockquote><blockquote><strong><em>perl $AD_TOP/patch/115/bin/txkADOPCutOverPhaseCtrlScript.pl \<br>-action=ctxupdate \<br>-contextfile=&lt;full path to new run context file&gt; \<br>-patchcontextfile=&lt;full path to new patch file system context file&gt; \<br>-outdir=&lt;full path to out directory&gt;</em></strong></blockquote><blockquote>4. Start up all services from the new run file system using the standard procedure.(Source run edition environment and use the adstrtal.sh script to start all the application services.)</blockquote><blockquote><em>Once you flash back the database and restart the application services from the file system that was your run file system before the last cutover phase, your EBS 12.2 system is rolled back to the state before the cutover phase. At this point, you can decide whether to continue or abort the patching cycle. If you fix the issues causing cutover to fail, you may decide to continue the patching. In that case, you can just execute the </em><em>adop phase=cutover command. However, if you decide not to continue, you can use </em><em>adop phase=abort and abort the patching cycle.</em></blockquote><p><strong>References:</strong></p><ul><li>Practical Oracle E-Business Suite An Implementation and Management Guide by Syed Zaheer and Erman Arslan</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e65ec74a5b93" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>