client Archives - DBACLASS https://dbaclass.com/article-tag/client/ database administration Tue, 06 Jul 2021 19:09:44 +0000 en-US hourly 1 https://wordpress.org/?v=6.5.5 Automate oracle client installation using ansible https://dbaclass.com/article/automate-oracle-client-installation-using-ansible/ https://dbaclass.com/article/automate-oracle-client-installation-using-ansible/#respond Tue, 06 Jul 2021 19:00:48 +0000 https://dbaclass.com/?post_type=article&p=7102 We can use the power of ansible to automate the oracle client installation task on multiple servers.In this article, we will explain how we will achieve this by executing an ansible playbook from ansible control node.   Ansible control node  is any machine where ansible tool is installed.    IMPORTANT POINTS: oracle 19c client will […]

The post Automate oracle client installation using ansible appeared first on DBACLASS.

]]>
We can use the power of ansible to automate the oracle client installation task on multiple servers.In this article, we will explain how we will achieve this by executing an ansible playbook from ansible control node.

 

Ansible control node  is any machine where ansible tool is installed. 

 

IMPORTANT POINTS:

  1. oracle 19c client will be installed on all nodes.
  2. Make sure  the servers where  client need to be installed has connectivity from ansible control server

Below are the steps :

1. Copy the oracle 19c client software ( zip file ) to ansible control server.


[ansible_node] ls -ltr /oracle/LINUX.X64_193000_client.zip

2. Prepare the inventory file:

The list of servers where oracle 19c client will be installed.

[ansiblel_node] $ cat /home/ansible/ansible-scipts/host_inv
[appserver]
linux_host22 ansible_host=10.20.86.60 ansible_connection=ssh ansible_user=root ansible_ssh_pass=dbaclass@123
linux_host29 ansible_host=10.20.86.61 ansible_connection=ssh ansible_user=root ansible_ssh_pass=dbaclass@123
linux_host34 ansible_host=10.20.86.62 ansible_connection=ssh ansible_user=root ansible_ssh_pass=dbaclass@123

3. Prepare the client installation response file:

[ansible_node] $ cat /home/ansible/oracle_client_19c.rsp

#-------------------------------------------------------------------------------
# Do not change the following system generated value.
#-------------------------------------------------------------------------------
oracle.install.responseFileVersion=/oracle/install/rspfmt_clientinstall_response_schema_v19.0.0

#-------------------------------------------------------------------------------
# Unix group to be set for the inventory directory.
#-------------------------------------------------------------------------------
UNIX_GROUP_NAME=oinstall
#-------------------------------------------------------------------------------
# Inventory location.
#-------------------------------------------------------------------------------
INVENTORY_LOCATION=/oracle/app/oraInventory
#-------------------------------------------------------------------------------
# Complete path of the Oracle Home
#-------------------------------------------------------------------------------
ORACLE_HOME=/oracle/app/oracle/product/19c/client_1
#-------------------------------------------------------------------------------
# Complete path of the Oracle Base.
#-------------------------------------------------------------------------------
ORACLE_BASE=/oracle/app/oracle
oracle.install.client.installType=Administrator

#-------------------------------------------------------------------------------

4. Prepare the ansible playbook:

[ansible_node] $ cat oracle_client_installation.yml
- hosts: appserver
  strategy: free
  user: bvunix
  become: yes
  become_method: su
  become_user: oracle
  tasks:
    - name: check existance of mount point
      command: mountpoint -q /oracle
      register: volume_stat
      failed_when: False
    - name: Copy client software
      unarchive: src=/oracle/LINUX.X64_193000_client.zip dest=/oracle/
    - name: Copy response file
      copy: src=/home/ansible/oracle_client_19c.rsp dest=/oracle mode=0777
    - name: Install Oracle Client
      command: "/oracle/client/runInstaller -silent -showProgress -ignorePrereq -ignoreSysPrereqs -waitforcompletion -responseFile /oracle/oracle_client_19c.rsp"
      register: client_runinstaller_output
      failed_when: "'Successfully Setup Software' not in client_runinstaller_output.stdout"


5. Execute the playbook:

[ansible-node]$  ansible-playbook oracle_client_installation.yml -i /home/ansible/ansible-scipts/host_inv

PLAY [linux_host22,linux_host29,linux_host34] ***********************************************************************************************************************************
Tuesday 06 July 2021  20:30:15 +0300 (0:00:00.048)       0:00:00.048 **********
Tuesday 06 July 2021  20:30:15 +0300 (0:00:00.011)       0:00:00.060 **********
Tuesday 06 July 2021  20:30:15 +0300 (0:00:00.010)       0:00:00.071 **********

TASK [Gathering Facts] **********************************************************************************************************************************************************
[WARNING]: Module remote_tmp /home/oracle/.ansible/tmp did not exist and was created with a mode of 0700, this may cause issues when running as another user. To avoid this,
create the remote_tmp dir with the correct permissions manually
ok: [linux_host34]
ok: [linux_host22]
Tuesday 06 July 2021  20:30:18 +0300 (0:00:02.977)       0:00:03.048 **********
Tuesday 06 July 2021  20:30:18 +0300 (0:00:00.043)       0:00:03.091 **********

TASK [check existance of mount point] *******************************************************************************************************************************************
changed: [linux_host34]
Tuesday 06 July 2021  20:30:19 +0300 (0:00:01.304)       0:00:04.397 **********
changed: [linux_host22]
Tuesday 06 July 2021  20:30:19 +0300 (0:00:00.088)       0:00:04.486 **********

TASK [Gathering Facts] **********************************************************************************************************************************************************
ok: [linux_host29]
Tuesday 06 July 2021  20:30:20 +0300 (0:00:00.884)       0:00:05.370 **********

TASK [check existance of mount point] *******************************************************************************************************************************************
changed: [linux_host29]
Tuesday 06 July 2021  20:30:21 +0300 (0:00:01.329)       0:00:06.699 **********

TASK [Copy client software] *****************************************************************************************************************************************************
changed: [linux_host34]
Tuesday 06 July 2021  20:31:36 +0300 (0:01:14.560)       0:01:21.259 **********
changed: [linux_host22]
Tuesday 06 July 2021  20:31:38 +0300 (0:00:02.122)       0:01:23.382 **********

TASK [Copy response file] *******************************************************************************************************************************************************
changed: [linux_host34]
Tuesday 06 July 2021  20:31:40 +0300 (0:00:01.840)       0:01:25.222 **********
changed: [linux_host22]
Tuesday 06 July 2021  20:31:41 +0300 (0:00:01.072)       0:01:26.295 **********

TASK [Copy client software] *****************************************************************************************************************************************************
changed: [linux_host29]
Tuesday 06 July 2021  20:31:45 +0300 (0:00:04.660)       0:01:30.956 **********

TASK [Copy response file] *******************************************************************************************************************************************************
changed: [linux_host29]
Tuesday 06 July 2021  20:31:48 +0300 (0:00:02.787)       0:01:33.744 **********

TASK [Install Oracle Client] ****************************************************************************************************************************************************
changed: [linux_host22]
changed: [linux_host34]
changed: [linux_host29]

PLAY RECAP **********************************************************************************************************************************************************************
linux_host22               : ok=5    changed=4    unreachable=0    failed=0    skipped=0    rescued=0    ignored=0
linux_host29               : ok=5    changed=4    unreachable=0    failed=0    skipped=0    rescued=0    ignored=0
linux_host34               : ok=5    changed=4    unreachable=0    failed=0    skipped=0    rescued=0    ignored=0

Tuesday 06 July 2021  20:33:33 +0300 (0:01:45.191)       0:03:18.935 **********
===============================================================================
Install Oracle Client -------------------------------------------------------------------------------------------------------------------------------------------------- 105.19s
Copy client software ---------------------------------------------------------------------------------------------------------------------------------------------------- 74.56s
Gathering Facts ---------------------------------------------------------------------------------------------------------------------------------------------------------- 2.98s
Copy response file ------------------------------------------------------------------------------------------------------------------------------------------------------- 2.79s
check existance of mount point ------------------------------------------------------------------------------------------------------------------------------------------- 1.33s

We have successfully installed oracle client on all the mentioned servers.

The post Automate oracle client installation using ansible appeared first on DBACLASS.

]]>
https://dbaclass.com/article/automate-oracle-client-installation-using-ansible/feed/ 0
How to install oracle client in silent mode using response file https://dbaclass.com/article/install-oracle-client-silent-mode-using-response-file/ https://dbaclass.com/article/install-oracle-client-silent-mode-using-response-file/#comments Thu, 27 Dec 2018 08:45:44 +0000 http://dbaclass.com/?post_type=article&p=4063 Though GUI is a preferable method to do client installation, But sometimes DBAs might be not to be able to xmanager to enable GUI for the server. In that case, installation using response file will be useful. In this example, we will do the installation of Oracle client 12.1.0.2 version. 1. Download Oracle client software […]

The post How to install oracle client in silent mode using response file appeared first on DBACLASS.

]]>
Though GUI is a preferable method to do client installation, But sometimes DBAs might be not to be able to xmanager to enable GUI for the server. In that case, installation using response file will be useful.

In this example, we will do the installation of Oracle client 12.1.0.2 version.

1. Download Oracle client software from oracle portal.-  

 

2. Copy and unzip the software in the server

 

unzip solaris.sparc64_12102_client.zip
cd client
-rwxr-xr-x   1 debmadm  dmgrp        500 Feb  6  2013 welcome.html
-rwxr-xr-x   1 debmadm  dmgrp      16872 Jul  8  2014 runInstaller
drwxr-xr-x  14 debmadm  dmgrp         31 Dec 26 11:49 stage
drwxr-xr-x   4 debmadm  dmgrp         14 Dec 26 11:49 install
drwxr-xr-x   2 debmadm  dmgrp          4 Dec 26 16:05 response

3. Update the response file.

a sample response file comes with the software itself. We just need the update the response file with required values.

RESPONSE FILE LOCATION – > $SOFTWARE/client/response/client_install.rsp

In the response file, we will update only the below values.

NOTE – Here we have selected installation type as Administrator

INVENTORY_LOCATION=/dmapps/product/oraInventory
SELECTED_LANGUAGES=en,ar
ORACLE_HOME=/dmapps/product/release/oracle/oracle/product/12.1.0/client_1
ORACLE_BASE=/dmapps/product/release
oracle.install.client.installType=Administrator

The response file will look like this – >  client_install

If you wish you to customize the installation, then you can go through the response file and update accordingly.

4. Now do the installation silently.

COMMAND ./runInstaller -ignoreSysPrereqs -showProgress -silent -responseFile /software/client/response/client_install.rsp

cd /software/client

$ ./runInstaller -ignoreSysPrereqs -showProgress -silent -responseFile  /software/client/response/client_install.rsp
Starting Oracle Universal Installer...

Checking Temp space: must be greater than 180 MB.   Actual 19107 MB    Passed
Checking swap space: must be greater than 150 MB.   Actual 33400 MB    Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2018-12-26_04-05-08PM. Please wait ...                                                                                            webmadm@prewmis4:~/software/client$ [WARNING] [INS-13014] Target environment does not meet some optional requirements.
   CAUSE: Some of the optional prerequisites are not met. See logs for details. /dmapps/product/oraInventory/logs/installActions2018-12-26_04-05-08PM.log
   ACTION: Identify the list of failed prerequisite checks from the log: /dmapps/product/oraInventory/logs/installActions2018-12-26_04-05-08PM.log. Then either from the log file or from installation manual find the appropriate configuration to meet the prerequisites and fix it manually.
You can find the log of this install session at:
 /dmapps/product/oraInventory/logs/installActions2018-12-26_04-05-08PM.log

Prepare in progress.
..................................................   7% Done.

Prepare successful.

Copy files in progress.
..................................................   14% Done.
..................................................   20% Done.
..................................................   25% Done.
..................................................   30% Done.
..................................................   37% Done.
..................................................   42% Done.
..................................................   47% Done.
..................................................   52% Done.
..................................................   57% Done.
..............................
Copy files successful.

Link binaries in progress.
..........
Link binaries successful.

Setup files in progress.
..................................................   62% Done.
..........
Setup files successful.

Setup Inventory in progress.

Setup Inventory successful.
..........
Finish Setup in progress.
..................................................   67% Done.

Finish Setup successful.
The installation of Oracle Client 12c was successful.
Please check '/dmapps/product/oraInventory/logs/silentInstall2018-12-26_04-05-08PM.log' for more details.

Prepare for configuration steps in progress.

Prepare for configuration steps successful.
..................................................   83% Done.

Oracle Client Configuration in progress.
..................................................   100% Done.

Oracle Client Configuration successful.
Successfully Setup Software.

ORACLE CLIENT INSTALLATION COMPLETED SUCCESSFULLY. 🙂

The post How to install oracle client in silent mode using response file appeared first on DBACLASS.

]]>
https://dbaclass.com/article/install-oracle-client-silent-mode-using-response-file/feed/ 4
How to deinstall oracle client https://dbaclass.com/article/how-to-deinstall-oracle-client/ https://dbaclass.com/article/how-to-deinstall-oracle-client/#respond Tue, 03 Nov 2015 06:08:32 +0000 http://dbaclass.com/?post_type=article&p=510               We can deinstall oracle client by runnning the deinstall tool provided by oracle client software. [oracle@bt-Prov-devst1 client_1]$ cd deinstall/ [oracle@bt-Prov-devst1 deinstall]$ ls -ltr total 92 -rwxr-xr-x. 1 oracle oinstall 32343 Dec 16 2009 sshUserSetup.sh -rw-r–r–. 1 oracle oinstall 409 Aug 18 2010 readme.txt -rw-r–r–. 1 oracle oinstall 3466 […]

The post How to deinstall oracle client appeared first on DBACLASS.

]]>
              We can deinstall oracle client by runnning the deinstall tool provided by oracle client software.

[oracle@bt-Prov-devst1 client_1]$ cd deinstall/
[oracle@bt-Prov-devst1 deinstall]$ ls -ltr
total 92
-rwxr-xr-x. 1 oracle oinstall 32343 Dec 16 2009 sshUserSetup.sh
-rw-r–r–. 1 oracle oinstall 409 Aug 18 2010 readme.txt
-rw-r–r–. 1 oracle oinstall 3466 Aug 18 2010 deinstall.xml
-rwxr-xr-x. 1 oracle oinstall 9780 May 10 2011 bootstrap.pl
-rwxr-xr-x. 1 oracle oinstall 18841 Jan 29 2013 deinstall.pl
drwxr-xr-x. 2 oracle oinstall 4096 Sep 16 12:58 jlib
drwxr-xr-x. 2 oracle oinstall 4096 Sep 16 12:58 response
-rwxr-xr-x. 1 oracle oinstall 9665 Sep 16 12:58 deinstall

 

While running deinstall tool , it will ask for below details. So be ready with the information.

 

Oracle Home selected for deinstall is: /oracle/app/oracle/product/11.2.0/client_1
Inventory Location where the Oracle home registered is: /oracle/app/oraInventory

 

 

Now start deinstallation.

 

[oracle@bt-Prov-devst1 deinstall]$ ./deinstall
Checking for required files and bootstrapping ...
Please wait ...
Location of logs /tmp/deinstall2015-09-16_01-08-01PM/logs/

############ ORACLE DEINSTALL & DECONFIG TOOL START ############


######################### CHECK OPERATION START #########################
## [START] Install check configuration ##


Checking for existence of the Oracle home location /oracle/app/oracle/product/11.2.0/client_1
Oracle Home type selected for deinstall is: Oracle Database Client
Oracle Base selected for deinstall is: /oracle/app/oracle
Checking for existence of central inventory location /oracle/app/oraInventory
Checking for sufficient temp space availability on node(s) : 'bt-Prov-devst1'

## [END] Install check configuration ##


Network Configuration check config START

Network de-configuration trace file location: /tmp/deinstall2015-09-16_01-08-01PM/logs/netdc_check2015-09-16_01-08-20-PM.log

Network Configuration check config END


######################### CHECK OPERATION END #########################


####################### CHECK OPERATION SUMMARY #######################
Oracle Home selected for deinstall is: /oracle/app/oracle/product/11.2.0/client_1
Inventory Location where the Oracle home registered is: /oracle/app/oraInventory
Do you want to continue (y - yes, n - no)? [n]: y
A log of this session will be written to: '/tmp/deinstall2015-09-16_01-08-01PM/logs/deinstall_deconfig2015-09-16_01-08-18-PM.out'
Any error messages from this session will be written to: '/tmp/deinstall2015-09-16_01-08-01PM/logs/deinstall_deconfig2015-09-16_01-08-18-PM.err'

######################## CLEAN OPERATION START ########################

Network Configuration clean config START

Network de-configuration trace file location: /tmp/deinstall2015-09-16_01-08-01PM/logs/netdc_clean2015-09-16_01-08-33-PM.log

De-configuring backup files...
Backup files de-configured successfully.

The network configuration has been cleaned up successfully.

Network Configuration clean config END

Setting the force flag to false
Setting the force flag to cleanup the Oracle Base
Oracle Universal Installer clean START

Detach Oracle home '/oracle/app/oracle/product/11.2.0/client_1' from the central inventory on the local node : Done

Delete directory '/oracle/app/oracle/product/11.2.0/client_1' on the local node : Done

Delete directory '/oracle/app/oraInventory' on the local node : Done

Delete directory '/oracle/app/oracle' on the local node : Done

Oracle Universal Installer cleanup was successful.

Oracle Universal Installer clean END


## [START] Oracle install clean ##

Clean install operation removing temporary directory '/tmp/deinstall2015-09-16_01-08-01PM' on node 'bt-Prov-devst1'

## [END] Oracle install clean ##


######################### CLEAN OPERATION END #########################


####################### CLEAN OPERATION SUMMARY #######################
Successfully detached Oracle home '/oracle/app/oracle/product/11.2.0/client_1' from the central inventory on the local node.
Successfully deleted directory '/oracle/app/oracle/product/11.2.0/client_1' on the local node.
Successfully deleted directory '/oracle/app/oraInventory' on the local node.
Successfully deleted directory '/oracle/app/oracle' on the local node.
Oracle Universal Installer cleanup was successful.

Run 'rm -rf /etc/oratab' as root on node(s) 'bt-Prov-devst1' at the end of the session.
Oracle deinstall tool successfully cleaned up temporary directories.
#######################################################################


############# ORACLE DEINSTALL & DECONFIG TOOL END #############

 

The post How to deinstall oracle client appeared first on DBACLASS.

]]>
https://dbaclass.com/article/how-to-deinstall-oracle-client/feed/ 0