Sunday, December 13, 2015

Exadata Storage Cell Commands Cheat Sheet

It is not an easy to remember the commands since most of the UNIX administrators are working on multiple Operating systems and different  OS flavors. Exadata and ZFS appliance are adding additional responsibility to Unix administrator and need to remember those appliance commands as well. This article will provide the reference to all Exadata storage cell commands with examples for some complex command options.

All the below mentioned commands will work only on cellcli prompt.

Listing the Exadata Storage cell Objects (LIST)

CommandDescriptionExamples
cellcliTo Manage the Exadata  cell Storage[root@uaexacell1 init.d]# cellcli
CellCLI: Release 11.2.3.2.1 – Production on Tue Nov 18 02:16:03 GMT+05:30 2014
Copyright (c) 2007, 2012, Oracle.  All rights reserved.
Cell Efficiency Ratio: 1CellCLI>
LIST CELLList the Cell StatusCellCLI> LIST CELL
uaexacell1      online
CellCLI>
LIST LUNTo list all the physical Drive & Flash drives
LIST PHYSICALDISKTo list all the physical Drive & Flash drives
 LIST LUN where celldisk = <celldisk>To list the LUN which is mapped to specific diskCellCLI> LIST LUN where celldisk = FD_13_uaexacell1
FLASH13  FLASH13   normal
LIST CELL DETAILList the cell Status with all attributesCellCLI> LIST CELL DETAIL
name:                   uaexacell1
bbuTempThreshold:       60
bbuChargeThreshold:     800
bmcType:                absent
LIST CELL attributes  <attribute>To list the specific cell attributesCellCLI> LIST CELL attributes flashCacheMode
WriteThrough
LIST CELLDISKList all the cell DisksCellCLI> LIST CELLDISK
CD_DISK00_uaexacell1    normal
CD_DISK01_uaexacell1    normal
LIST CELLDISK DETAILList all the cell Disks with Detailed informationCellCLI> LIST CELLDISK detail
name:                   FD_13_uaexacell1
comment:
creationTime:           2014-11-15T01:46:57+05:30
deviceName:             0_0
devicePartition:        0_0
diskType:               FlashDisk
LIST CELLDISK <CELLDISK> detailTO list the Specific celldisk detailCellCLI>  LIST CELLDISK FD_00_uaexacell1 detail
name:                   FD_00_uaexacell1
comment:
creationTime:           2014-11-15T01:46:56+05:30
LIST CELLDISK where disktype=harddiskTo list the celldisk which are created using harddiskCellCLI> LIST CELLDISK where disktype=harddisk
CD_DISK00_uaexacell1    normal
CD_DISK01_uaexacell1    normal
CD_DISK02_uaexacell1    normal
LIST CELLDISK where disktype=flashdiskTo list the celldisk which are created using FlashdiskCellCLI> LIST CELLDISK where disktype=flashdisk
FD_00_uaexacell1        normal
FD_01_uaexacell1        normal
FD_02_uaexacell1        normal
LIST CELLDISK where freespace > SIZETo list the celldisks which has more than specificed sizeCellCLI>  LIST CELLDISK where freespace > 50M
FD_00_uaexacell1        normal
FD_01_uaexacell1        normal
LIST FLASHCACHETo list the configured FLASHCACHE
LIST FLASHCACHE DETAILTo list the configured FLASHCACHE in detail
LIST FLASHLOGTo list the configured FLASHLOG
LIST FLASHLOG DETAILTo list the configured FLASHLOG in detail
LIST FLASHCACHECONTENTTo list the Flashcache content
LIST GRIDDISKTo list the griddisksCellCLI> LIST GRIDDISK
DATA01_CD_DISK00_uaexacell1     active
DATA01_CD_DISK01_uaexacell1     active
LIST GRIDDISK DETAILTo list the griddisks in detailCellCLI>  LIST GRIDDISK DETAIL
name:                   DATA01_CD_DISK00_uaexacell1
availableTo:
cachingPolicy:          default
cellDisk:               CD_DISK00_uaexacell1
LIST GRIDDISK <GRIDDISK_NAME>To list the specific GriddiskCellCLI> LIST GRIDDISK DATA01_CD_DISK00_uaexacell1
DATA01_CD_DISK00_uaexacell1     active
LIST GRIDDISK <GRIDDISK_NAME> detailTo list the specific Griddisk in detailCellCLI>  LIST GRIDDISK DATA01_CD_DISK00_uaexacell1 detail
name:                   DATA01_CD_DISK00_uaexacell1
availableTo:
cachingPolicy:          default
cellDisk:               CD_DISK00_uaexacell1
LIST GRIDDISK where size > SIZETo list the griddisk which size is higher than specified valueCellCLI> LIST GRIDDISK where size > 750M
DATA01_CD_DISK00_uaexacell1     active
LIST IBPORTTo list the inifiniband Port
LIST IORMPLANTo list the IORMPLANCellCLI> LIST IORMPLAN
uaexacell1_IORMPLAN     active
LIST IORMPLAN DETAILTo list the IORMPLAN  in DETAILCellCLI> LIST IORMPLAN DETAIL
name:                   uaexacell1_IORMPLAN
catPlan:
dbPlan:
objective:              basic
status:                 active
LIST METRICCURRENTTo get the I/O’s second for all the objectsCellCLI>  LIST METRICCURRENT
CD_BY_FC_DIRTY                  CD_DISK00_uaexacell1                            0.000 MB
CD_BY_FC_DIRTY                  CD_DISK01_uaexacell1                            0.000 MB
CD_BY_FC_DIRTY                  CD_DISK02_uaexacell1                            0.000 MB
CD_BY_FC_DIRTY                  CD_DISK03_uaexacell1                            0.000 MB
LIST METRICCURRENT cl_cput, cl_runq detailTo list the RUNQCellCLI> list metriccurrent cl_cput, cl_runq detail
name:                   CL_CPUT
alertState:             normal
collectionTime:         2014-11-18T02:42:26+05:30
metricObjectName:       uaexacell1
metricType:             Instantaneous
metricValue:            4.7 %
objectType:             CELLname:                   CL_RUNQ
alertState:             normal
collectionTime:         2014-11-18T02:42:26+05:30
metricObjectName:       uaexacell1
metricType:             Instantaneous
metricValue:            12.2
objectType:             CELL
LIST QUARANTINETo list the QUARANTINE disk
LIST QUARANTINE detailTo list the QUARANTINE disk in detail
 LIST THRESHOLDTo list the thersold limits
LIST THRESHOLD DETAILTo list the thersold limits in detail
LIST ACTIVEREQUESTTo list the active Requests
LIST ALERTHISTORYTo list the alerts

CREATING the Exadata Storage cell Objects (CREATE)

The below commands will be used most commonly on exadata storage to create the virtual objects.
CREATE CELL  <CELL_NAME> interconnect1=<ethx>Configures the cell networkCellCLI> CREATE CELL uaexacell1  interconnect1=eth1
Cell uaexacell1 successfully created
Starting CELLSRV services…
The STARTUP of CELLSRV services was successful.
Flash cell disks, FlashCache, and FlashLog will be created.
CREATE CELLDISK <CELLDISK_NAME>  <LUN>Creates cell disk(s) according to attributes provided. CREATE CELLDISK UADBG1  LUN=00_00
CREATE CELLDISK ALL HARDISKCreates cell disk(s) on all the harddisksCellCLI> CREATE CELLDISK ALL HARDDISK
CellDisk CD_DISK00_uaexacell1 successfully created
CellDisk CD_DISK01_uaexacell1 successfully created
CellDisk CD_DISK02_uaexacell1 successfully created
CREATE CELLDISK ALLCreates cell disk(s) on all the harddisks & flashdisksCellCLI> CREATE CELLDISK ALL
CellDisk CD_DISK00_uaexacell1 successfully created
CREATE CELLDISK ALL FLASHDISKCreates cell disk(s) on all the  flashdisksCellCLI> CREATE CELLDISK ALL FLASHDISK
CellDisk FD_00_uaexacell1 successfully created
CREATE FLASHCACHE celldisk=”Flash_celldisk1″Creates flash cache for IO requests on specific flashdiskCellCLI> CREATE FLASHCACHE celldisk=”FD_00_uaexacell1,FD_01_uaexacell1″, size=500M
CREATE FLASHCACHE  ALL size = <size>Creates flash cache for IO requests on all devices
with specific size
CREATE FLASHCACHE  ALL size = 10G
CREATE FLASHLOG  celldisk=”Flash_celldisk1″Creates flash log for logging requests on specified flashdiskCellCLI> CREATE FLASHLOG celldisk=”FD_00_uaexacell1,FD_01_uaexacell1″, size=500M
CREATE FLASHLOG  ALL size = <size>Creates flash log for logging requests on all devices
with specific size
CREATE FLASHLOG  ALL size = 252M
CREATE GRIDDISK  <GRIDDISK_NAME> CELLDISK=<celldisk>Creates grid disk on specific diskCellCLI> CREATE GRIDDISK UADBDK1 CELLDISK=CD_DISK00_uaexacell1
GridDisk UADBDK1 successfully created
CellCLI>
CREATE GRIDDISK  <GRIDDISK_NAME> CELLDISK=<celldisk>, size=<size>Creates grid disk  on specific disk with specific sizeCellCLI> CREATE GRIDDISK UADBDK2 CELLDISK=CD_DISK02_uaexacell1, SIZE=100M
GridDisk UADBDK2 successfully created
CellCLI>
CREATE GRIDDISK ALL  HARDDISK PREFIX=<Disk_Name>, size=<size>Create Grid disks on all the harddisk with specific size.CellCLI> CREATE GRIDDISK ALL  HARDDISK PREFIX=UADBPROD, size=100M
Cell disks were skipped because they had no freespace for grid disks: CD_DISK00_uaexacell1.
GridDisk UADBPROD_CD_DISK01_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK02_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK03_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK04_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK05_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK06_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK07_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK08_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK09_uaexacell1 successfully created
GridDisk UADBPROD_CD_DISK10_uaexacell1 successfully created
CREATE GRIDDISK ALL  FLASHDISK PREFIX=<Disk_Name>, size=<size>Create Grid disks on all the flashdisk with specific size.CellCLI> CREATE GRIDDISK ALL FLASHDISK PREFIX=UAFLSHDB, size=100M
GridDisk UAFLSHDB_FD_00_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_01_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_02_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_03_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_04_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_05_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_06_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_07_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_08_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_09_uaexacell1 successfully created
GridDisk UAFLSHDB_FD_10_uaexacell1 successfully created
CREATE KEYCreates and displays random key for use in assigning client keys.CellCLI> CREATE KEY
1820ef8f9c2bafcd12e15ebfe267abad
CellCLI>
CREATE QUARANTINE quarantineType=<“SQLID” or “DISK REGION” or \
“SQL PLAN” or “CELL OFFLOAD”> attributename=value
Define the attributes for a new quarantine entityCellCLI> CREATE QUARANTINE quarantineType=”SQLID”, sqlid=”5xnjp4cutc1s8″
Quarantine successfully created.
CellCLI>
CREATE THRESHOLD <Thersold1>   attributename=valueDefines conditions for generation of a metric alert.CellCLI> CREATE THRESHOLD db_io_rq_sm_sec.db123  comparison=’>’, critical=120
Threshold db_io_rq_sm_sec.db123 successfully created
CellCLI>

DELETING the Exadata Storage cell Objects (DROP)

The below mentioned cellcli commands will help you to remove the various objects on the exadata storage cell. Be carefully with “force” option since it can remove the object even though it is in use.
DROP ALERTHISTORY <ALER1>, <ALERT2>Removes the specific alert from the cell’s alert history.CellCLI> DROP ALERTHISTORY 2
Alert 2 successfully dropped
CellCLI>
DROP ALERTHISTORY ALLRemoves all alert from the cell’s alert history.CellCLI> DROP ALERTHISTORY ALL
Alert 1_1 successfully dropped
Alert 1_2 successfully dropped
Alert 1_3 successfully dropped
Alert 1_4 successfully dropped
Alert 1_5 successfully dropped
Alert 1_6 successfully dropped
DROP THRESHOLD <THERSOLD>Removes specific threshold from the cellCellCLI> DROP THRESHOLD db_io_rq_sm_sec.db123
Threshold db_io_rq_sm_sec.db123 successfully dropped
CellCLI>
DROP THRESHOLD ALLRemoves all  threshold from the cellCellCLI> DROP THRESHOLD ALL
DROP QUARANTINE <quarantine1>Removes quarantine from the cellCellCLI> DROP QUARANTINE QADB1
DROP QUARANTINE ALLRemoves all the quarantine from the cellCellCLI> DROP QUARANTINE ALL
DROP GRIDDISK <Griddisk_Name>Removes the specific grid disk from the cellCellCLI> DROP GRIDDISK UADBDK1
GridDisk UADBDK1 successfully dropped
CellCLI>
DROP GRIDDISK ALL PREFIX=<GRIDDISK_STARTNAME>Removes the set of grid disks from the cell by using the prefixCellCLI> DROP GRIDDISK ALL PREFIX=UAFLSHDB
GridDisk UAFLSHDB_FD_00_uaexacell1 successfully dropped
GridDisk UAFLSHDB_FD_01_uaexacell1 successfully dropped
GridDisk UAFLSHDB_FD_02_uaexacell1 successfully dropped
GridDisk UAFLSHDB_FD_03_uaexacell1 successfully dropped
GridDisk UAFLSHDB_FD_04_uaexacell1 successfully dropped
GridDisk UAFLSHDB_FD_05_uaexacell1 successfully dropped
DROP GRIDDISK  <GRIDDISK> ERASE=1passRemoves the specific  grid disks from the cell and Performs secure data deletion on the grid diskCellCLI> DROP GRIDDISK  UADBPROD_CD_DISK10_uaexacell1 ERASE=1pass
GridDisk UADBPROD_CD_DISK10_uaexacell1 successfully dropped
CellCLI>
DROP GRIDDISK  <GRIDDISK> FORCEDrops grid disk even if it is currently active.CellCLI> DROP GRIDDISK  UADBPROD_CD_DISK08_uaexacell1 FORCE
GridDisk UADBPROD_CD_DISK08_uaexacell1 successfully dropped
DROP GRIDDISK ALL HARDDISKDrops griddisks which are created on top of hardiskDROP GRIDDISK ALL HARDDISK

Modifying  the Exadata Storage cell Objects (ALTER)

The below mentioned commands will help you to modify the cell attributes and various objects setting. ALTER command will be used to perform the start/stop/restart the MS/RS/CELLSRV services as well.
ALTER ALERTHISTORY 123 examinedby=<user_name>Sets the examinedby attribute of alerts ALTER ALERTHISTORY 123 examinedby=lingesh
ALTER CELL RESTART SERVICES ALLAll(RS+CELLSRV+MS) services are restartedCellCLI>ALTER CELL RESTART SERVICES ALL
ALTER CELL RESTART SERVICES < RS | MS | CELLSRV >To restart specific servicesCellCLI>ALTER CELL RESTART SERVICES RS
CellCLI>ALTER CELL RESTART SERVICES MS
CellCLI>ALTER CELL RESTART SERVICES CELLSRV
ALTER CELL SHUTDOWN SERVICES ALLAll(RS+CELLSRV+MS) services will be haltedCellCLI>ALTER CELL SHUTDOWN SERVICES
ALTER CELL SHUTDOWN SERVICES < RS | MS | CELLSRV >To shutdown specfic serviceCellCLI>ALTER CELL SHUTDOWN SERVICES RS
CellCLI>ALTER CELL SHUTDOWN SERVICES MS
CellCLI>ALTER CELL SHUTDOWN SERVICES CELLSRV
ALTER CELL STARTUP SERVICES ALLAll(RS+CELLSRV+MS) services will be startedCellCLI>ALTER CELL STARTUP SERVICES
ALTER CELL STARTUP SERVICES < RS | MS | CELLSRV >To start specific ServiceCellCLI>ALTER CELL STARTUP SERVICES RS
CellCLI>ALTER CELL STARTUP SERVICES MS
CellCLI>ALTER CELL STARTUP SERVICES CELLSRV
ALTER CELL NAME=<Name>To Set the Name/Re-name to the Exadata Storage CellCellCLI> ALTER CELL NAME=UAEXACELL1
Cell UAEXACELL1 successfully altered
CellCLI>
ALTER CELL flashCacheMode=WriteBackTo Modify the flashcache mode to writeback from writethrough. To perform this,You need to drop the flashcache & Stop the cellsrv .Then you need to create the new FlashcacheCellCLI> DROP flashcache
Flash cache UAEXACELL1_FLASHCACHE successfully dropped
CellCLI>
CellCLI> ALTER CELL SHUTDOWN SERVICES CELLSRV
Stopping CELLSRV services…
The SHUTDOWN of CELLSRV services was successful.
CellCLI>
CellCLI>  ALTER CELL flashCacheMode=WriteBack
Cell UAEXACELL1 successfully altered
CellCLI>
CellCLI> CREATE FLASHCACHE celldisk=”FD_00_uaexacell1,FD_01_uaexacell1″, size=500M
ALTER CELL interconnect1=<Network_Interface>To set the network interface for cell stroage.CellCLI> ALTER CELL INTERCONNECT1=eth1
A restart of all services is required to put new network configuration into effect. MS-CELLSRV communication may be hampered until restart.Cell UAEXACELL1 successfully altered
ALTER CELL LED OFFThe chassis LED is turned   off.CellCLI> ALTER CELL LED OFF
ALTER CELL LED ONThe chassis LED is turned   on.CellCLI> ALTER CELL LED ON
ALTER CELL smtpServer='<SMTP_SERVER>’Set the SMTP serverCellCLI> ALTER CELL smtpServer=’myrelay.unixarena.com’
ALTER CELL smtpFromAddr='<myaddress@mydomain.com>’Set the Email From AddressCellCLI> ALTER CELL smtpFromAddr=’uacell@unixarena.com’
ALTER CELL smtpToAddr='<myemail@mydomain.com>’Send the alrets to this Email  AddressCellCLI> ALTER CELL smtpToAddr=’lingeshwaran.rangasamy@gmail.com’
ALTER CELL smtpFrom='<myhostname>’Alias host name for emailCellCLI> ALTER CELL smtpFrom=’uaexacell1′
ALTER CELL smtpPort=’25’Set the SMTP portCellCLI> ALTER CELL smtpPort=’25’
ALTER CELL smtpUseSSL=’TRUE’Make the smtp to use SLLCellCLI> ALTER CELL smtpUseSSL=’TRUE’
ALTER CELL notificationPolicy=’critical,warning,clear’Send the alrets for critical,warning and clearCellCLI> ALTER CELL notificationPolicy=’critical,warning,clear’
ALTER CELL notificationMethod=’mail’Set the notification method as emailCellCLI> ALTER CELL notificationMethod=’mail’
ALTER CELLDISK <existing_celldisk_name> name='<new_cell_name>’,Modify’s the celldisk nameCellCLI> ALTER CELLDISK CD_DISK00_uaexacell1 name=’UACELLD’, comment=’Re-named for UnixArena’
comment='<comments>’CellDisk UACELLD successfully altered
ALTER CELLDISK ALL HARDDISK FLUSHDirty blocks for all harddisk will be flushedCellCLI> ALTER CELLDISK ALL HARDDISK FLUSH
ALTER CELLDISK ALL HARDDISK FLUSH NOWAITAllows alter command to complete while flush operation continues on all harddisksCellCLI> ALTER CELLDISK ALL HARDDISK FLUSH NOWAIT
Flash cache flush is in progress
CellCLI>
ALTER CELLDISK ALL HARDDISK CANCEL FLUSHPrevious flush operation on all harddisk will be terminatedCellCLI> ALTER CELLDISK ALL HARDDISK CANCEL FLUSH
CellDisk CD_DISK02_uaexacell1 successfully altered
CellDisk CD_DISK03_uaexacell1 successfully altered
CellDisk CD_DISK04_uaexacell1 successfully altered
CellDisk CD_DISK05_uaexacell1 successfully altered
ALTER CELLDISK <CELLDISK> FLUSHDirty blocks for specific  celldisk will be flushedCellCLI> ALTER CELLDISK  CD_DISK02_uaexacell1
ALTER CELLDISK  <CELLDISK> FLUSH  NOWAITAllows alter command to complete while flush operation continues on specific celldiskCellCLI> ALTER CELLDISK  CD_DISK02_uaexacell1 FLUSH NOWAIT
Flash cache flush is in progress
 ALTER FLASHCACHE ALL size=<size>Resize the all Flash celldisks to specified size ALTER FLASHCACHE ALL size=100G
ALTER FLASHCACHE ALLAll the flashsdisks will be assigned to FlashcacheCellCLI> ALTER FLASHCACHE ALL
Flash cache uaexacell1_FLASHCACHE altered successfully
ALTER FLASHCACHE
CELLDISK='<Flashcelldisk1>,<Flashcelldisk2>’
The specified Flashcell disks be assigned to Flashcache &CellCLI>  ALTER FLASHCACHE CELLDISK=’FD_09_uaexacell1,FD_04_uaexacell1′
other flashdisks will be removedFlash cache uaexacell1_FLASHCACHE altered successfully
ALTER FLASHCACHE ALL FLUSHDirty blocks for all Flashdisks will be flushedCellCLI> ALTER FLASHCACHE ALL
ALTER FLASHCACHE ALL  CANCEL FLUSHPrevious flush operation on all Flashdisk will be terminatedCellCLI> ALTER FLASHCACHE ALL CANCEL FLUSH
Flash cache uaexacell1_FLASHCACHE altered successfully
ALTER FLASHCACHE ALL FLUSH NOWAITAllows alter command to complete while flush operationCellCLI> ALTER FLASHCACHE ALL FLUSH NOWAIT
continues on all the flash celldiskFlash cache flush is in progress
ALTER FLASHCACHE CELLDISK=<FLASH-CELLDISK> FLUSHDirty blocks for specific  flash celldisk will be flushedCellCLI> ALTER FLASHCACHE CELLDISK=FD_04_uaexacell1 FLUSH
Flash cache uaexacell1_FLASHCACHE altered successfully
ALTER FLASHCACHE
CELLDISK=<FLASH-CELLDISK> CANCEL FLUSH
Previous flush operation on specific flash celldisk will be terminatedCellCLI> ALTER FLASHCACHE CELLDISK=FD_04_uaexacell1 CANCEL FLUSH
Flash cache uaexacell1_FLASHCACHE altered successfully

No comments:

Post a Comment