ASM: Device is already labeled for ASM disk
ASMLib occasionally leaves partitions in a state where they can neither have disks created on them or deleted from them:
oracle@bloo$ /etc/init.d/oracleasm createdisk DATA1 /dev/sda1
Marking disk "/dev/sda1" as an ASM disk: asmtool:
Device "/dev/sda1" is already labeled for ASM disk "" [FAILED]
oracle@bloo$ /etc/init.d/oracleasm deletedisk DATA1
Removing ASM disk "DATA1" [FAILED]
To get around this problem, it is necessary to overwrite the ASM header information on the disk. This can be achieved with the UNIX command dd. The following command will write 100x1024b blocks to the specified raw device:
dd if=/dev/zero of=<your_raw_device> bs=1024 count=100
Now if we retry the create disk commands, they should work:
oracle@bloo$ dd if=/dev/zero of=/dev/sda1 bs=1024 count=100
100+0 records in
100+0 records out
oracle@bloo$ /etc/init.d/oracleasm createdisk DATA1 /dev/sda1
Marking disk "/dev/sda1" as an ASM disk: [ OK ]
oracle@bloo$
There are loads of useful ASM administration queries here
|