DBA Hub

📋Steps in this guide1/3

Useful Asmcmd Commands

This blog contains the list of useful asmcmd commands which are important in your day to day operations.

oracle configurationintermediate
by OracleDba
15 views
1

Overview

This blog contains the list of useful asmcmd commands which are important in your day to day operations. - List all diskgroups: List all diskgroups:

Code/Command (click line numbers to comment):

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
ASMCMD> lsdg


-- Include dismounted diskgroups:

ASMCMD> lsdg --discovery

-- List diskgroups across all nodes of cluster:

ASMCMD> lsdg -g --discovery

a.List all asm disks

ASMCMD> lsdsk -k 

 b. List disks of a diskgroup(CDATA) with free and total MB
ASMCMD> lsdsk -k -G CDATA

 c. List disks of a diskgroup(CDATA) with group and disk number
ASMCMD> lsdsk -p -G CDATA

 d. List disks with disk creation date 
ASMCMD> lsdsk -t -G CDATA

 e. List candidiate disks only

ASMCMD>  lsdsk --candidate -k

 f. List member disks only
ASMCMD>  lsdsk --candidate -p

a. List attribute of all diskgroups:

ASMCMD> lsattr -lm 

b. List attribute of specific diskgroup(DMARCH)

ASMCMD> lsattr -lm -G  DMARCH
Group_Name  Name                     Value       RO  Sys
DMARCH      access_control.enabled   FALSE       N   Y
DMARCH      access_control.umask     066         N   Y
DMARCH      au_size                  1048576     Y   Y
DMARCH      cell.smart_scan_capable  FALSE       N   N


c. List attributes with specific pattern

ASMCMD> lsattr -lm %au_size%

a. unmount all diskgroups
ASMCMD> umount -a

b. unmount specific diskgroup(ARCH)
ASMCMD> umount ARCH
2

Section 2

Mount command works only on the local node. So if you want to Mount the diskgroup from all nodes of cluster, then run this command from all the nodes.

Code/Command (click line numbers to comment):

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
a. mount all diskgroups on local node
ASMCMD> mount -a

b. mount a specific diskgroup on local node
ASMCMD> mount ARCH

a. here asm_power_limit is 8 and diskgroup is ARCH

ASMCMD> rebal --power 8 ARCH
Rebal on progress.

b. Monitor progress

ASMCMD> lsop

ASMCMD> pwget --dbuniquename PRIM

ASMCMD> pwget --asm

ASMCMD> lstmpl -l -G ARCH
3

Section 3

Code/Command (click line numbers to comment):

1
ASMCMD> showclustermode

Comments (0)

Please to add comments

No comments yet. Be the first to comment!