jeudi 19 décembre 2013

How to recover from : CRS-0184: Cannot communicate with the CRS daemon

Yesterday, i am facing an issue where all crs commands fail on a cluster with the following error :
“CRS-0184: Cannot communicate with the CRS daemon”

 I doesn't want to resintall a complete clusterware and loose all the clusterware configuration.

To solve the probleme, i use perl script defined in the  $ORAGRID_HOME./crs/install/ directory.
I found that the file crsconfig_params containes the global configuration of my cluster.
This file will be generated at the first installation.
This file in used as input by some perl scripts and especially by the roothas.pl and rootcrs.pl. 

so first, i try on each node of my cluster to reset the complete ocr/olr configuration files. 
To that i execute the following commands :
$ORAGRID_HOME./crs/install/roothas.pl  -deconfig  -force
and 
$ORAGRID_HOME./crs/install/rootcrs.pl  -deconfig  -force

This script remove all the configuration donne for the Oracle High Availability Services and also for the Cluster Ready Services.
The -force option is used to indicate to note use the clusterware services (cause not available)
The -deconfig option is used to remove content of the clusterware configuration files.

To recreate the cluster i use the following command that takes in input by default the crsconfig_params file :
$ORAGRID_HOME./crs/install/rootcrs.pl

The magic is done.
You can after restart your cluster using the following command :
$ORAGRID_HOME/bin/crsctl start crs
@see here under the content of the crsconfig_params file :
SILENT=false
ORACLE_OWNER=ora11grid
ORA_DBA_GROUP=dba
ORA_ASM_GROUP=dba
LANGUAGE_ID=AMERICAN_AMERICA.AL32UTF8
TZ=Europe/Paris
ISROLLING=true
REUSEDG=false
ASM_AU_SIZE=1
USER_IGNORED_PREREQ=true

ORACLE_HOME=/opt/ora11grid
ORACLE_BASE=/opt/oracle
OLD_CRS_HOME=
JREDIR=/opt/ora11grid/jdk/jre/
JLIBDIR=/opt/ora11grid/jlib

VNDR_CLUSTER=true
OCR_LOCATIONS=/ocr/ocr1/ocr1.data,/ocr/ocr2/ocr2.data,/ocr/ocr3/ocr3.data
CLUSTER_NAME=mycluster_1_2
HOST_NAME_LIST=node1,node2
NODE_NAME_LIST=node1,node2
PRIVATE_NAME_LIST=
VOTING_DISKS=/voting/vot1/vot1.data,/voting/vot2/vot2.data,/voting/vot3/vot3.data
#VF_DISCOVERY_STRING=%s_vfdiscoverystring%
ASM_UPGRADE=false
ASM_SPFILE=
ASM_DISK_GROUP=
ASM_DISCOVERY_STRING=
ASM_DISKS=
ASM_REDUNDANCY=
CRS_STORAGE_OPTION=2
CSS_LEASEDURATION=400
CRS_NODEVIPS='node1-vip/255.255.252.0/eth0,node2-vip/255.255.252.0/eth0'
NODELIST=node1,node2
NETWORKS="eth0"/10.10.xx.xx:public,"bond0"/192.168.164.0:cluster_interconnect
SCAN_NAME=mycluster_1_2-scan
SCAN_PORT=1521
GPNP_PA=
OCFS_CONFIG=

# GNS consts
GNS_CONF=false
GNS_ADDR_LIST=
GNS_DOMAIN_LIST=
GNS_ALLOW_NET_LIST=
GNS_DENY_NET_LIST=
GNS_DENY_ITF_LIST=

####
Required by OUI add node
NEW_HOST_NAME_LIST=
NEW_NODE_NAME_LIST=
NEW_PRIVATE_NAME_LIST=
NEW_NODEVIPS='node1-vip/255.255.252.0/eth0,node2-vip/255.255.252.0/eth0'

###############
# OCR constants
#GPNPCONFIGDIR is handled differently in dev (T_HAS_WORK for all)
#GPNPGCONFIGDIR in dev expands to T_HAS_WORK_GLOBAL
GPNPCONFIGDIR=$ORACLE_HOME
GPNPGCONFIGDIR=$ORACLE_HOME
OCRLOC=
OLRLOC=
OCRID=
CLUSTER_GUID=
CLSCFG_MISSCOUNT=

####IPD/OS
CRFHOME="/opt/ora11grid"