A collection of common commands in oracle rac
1. Modify the number of sessions
Query the number of connections to the current process in the database:
Select count (*) from v$process
Modify the maximum number of connections allowed in the database:
Alter system set processes = 1500 scope = spfile
(the database needs to be restarted to modify the number of connections)
2. How to delete an error in GRID installation
Su-grid
Cd / dev/oracleasm/disks
Rm-rf vote*
Cd / dev/disk/by-label
Rm-rf vote*
Ll / g01
Rm-rf *
Chown-R grid:oinstall / G01
Rm / etc/oracle/ocr.loc
Rm-rf / etc/ora*
Ps-ef | grep oha
Kill-9 47495
Cd / etc/init.d
Ls * oha*
Rm-rf * oha*
Cd / etc/rc3.d
Rm-rf S96ohasd
Cd / etc/rc5.d
Rm-rf S96oha *
Oracleasm scandisks
Oracleasm listdisks
Oracleasm querydisk / dev/mapper/*
Dd if=/dev/zero of=/dev/mapper/sc-vote-hpp1 bs=1M count=300
Dd if=/dev/zero of=/dev/mapper/tc-vote-hpp1 bs=1M count=300
Dd if=/dev/zero of=/dev/mapper/yd-vote-netappp1 bs=1M count=300
3. Rac cluster start and stop
Stop rac
Oracle user
181srvctl status database-d prod
182 srvctl stop database-d prod
183 srvctl status database-d prod
Root user
. / crsctl start has High availability
Cd / g01/11ggrid/app/11.2.0/grid/bin
. / crsctl check cluster-all
. / crsctl stop cluster-all
. / crsctl check cluster-all
. / crs_stat-t-v
Reboot
Start rac
Root user
975 cd / g01/11ggrid/app/11.2.0/grid/bin
977. / crsctl start cluster-all
978. / crsctl check cluster-all
980. / crsctl status resource-t
Oracle user
[oracle@sc-rac1] $srvctl start database-d prod
[oracle@sc-rac1] $srvctl status database-d prod
Instance prod1 is running on node sc-rac1
Instance prod2 is running on node sc-rac2
Instance prod3 is running on node tc-rac1