configure ocfs
TRANSCRIPT
8/3/2019 Configure OCFS
http://slidepdf.com/reader/full/configure-ocfs 1/2
Create the OCFS2 foldermkdir -p /etc/ocfs2 << On BOTH nodes
Creat the OCFS2 Cluster configuration file:touch /etc/ocfs2/cluster.conf << On BOTH nodes
####################################################################
Place this content into the above created conf file and save it << On BOTH nodes
node:ip_port = 7777ip_address = 172.16.11.125number = 0name = 11grac01cluster = ocfs2
node:ip_port = 7777
ip_address = 172.16.11.127number = 1name = 11grac02cluster = ocfs2
cluster:node_count = 2name = ocfs2
####################################################################
Finally, commands to configure the OCFS2 Cluster services << On BOTH nodes
/etc/init.d/o2cb status/etc/init.d/o2cb load/etc/init.d/o2cb online ocfs2/etc/init.d/o2cb offline ocfs2/etc/init.d/o2cb unload/etc/init.d/o2cb configure
Load O2CB driver on boot (y/n) [n]: y << Enter YCluster stack backing O2CB [o2cb]: << Just press enterCluster to start on boot (Enter "none" to clear) [ocfs2]: << If the correc
t cluster name is shown just press tnter, else type the correct name and press enterSpecify heartbeat dead threshold (>=7) [31]: << Just press enterSpecify network idle timeout in ms (>=5000) [30000]: << Just press enterSpecify network keepalive delay in ms (>=1000) [2000]: << Just press enterSpecify network reconnect delay in ms (>=2000) [2000]: << Just press enterWriting O2CB configuration: OKLoading filesystem "configfs": OKMounting configfs filesystem at /sys/kernel/config: OK
Loading filesystem "ocfs2_dlmfs": OKMounting ocfs2_dlmfs filesystem at /dlm: OKStarting O2CB cluster ocfs2: OK
8/3/2019 Configure OCFS
http://slidepdf.com/reader/full/configure-ocfs 2/2
####################################################################
Format the necessary disks as OCFS2 filesystems; OCFS2 cluster makes them available for all the cluster nodes << On only ONE node
mkfs.ocfs2 -b 4K -C 32K -N 4 -L ARCHIVELOGS /dev/xvdh
mkfs.ocfs2 -b 4K -C 32K -N 4 -L GGSHOME /dev/xvdi
####################################################################
Create the necessary mount points (folders) to mount the OFCS2 devices << On BOTH nodes
mkdir /u02mkdir /ggs
####################################################################
<<<<< CAUTION: Don´t use the datavolume option for the mount options otherwise theexecution<<<<< of some of the sqls files that are located on such drives will throw the below error
ERROR 45 INITIALIZING SQL*PLUSINTERNAL ERROR
Mount the formatted notes << On BOTH nodes
mount -t ocfs2 -o datavolume,nointr -L "archivelogs" /u02 xxxx> mount -tocfs2 -o nointr -L "ARCHIVELOGS" /archmount -t ocfs2 -o datavolume,nointr -L "ggshome" /ggs xxxx> mount -t
ocfs2 -o nointr -L "GGSHOME" /ggs
update the /etc/fstab file with the below entries << On BOTH nodes
LABEL=archivelogs /u02 ocfs2 _netdev,datavolume,nointr 0 0xxxx> LABEL=ARCHIVELOGS /u02 ocfs2 _netdev,nointr 0 0LABEL=ggshome /ggs ocfs2 _netdev,datavolume,nointr 0 0xxxx> LABEL=GGSHOME /ggs ocfs2 _netdev,nointr 0 0
####################################################################
Check and change the permissions on the mounted devices << On BOTH nodes
chown -R oracle:oinstall /archchmod -R 775 /arch
chown -R oracle:oinstall /ggschmod -R 775 /ggs
####################################################################