Re: Trying to Simulate a disk failure for one of the disks used by ASM disk group

  • From: Hanan Hit <hithanan@xxxxxxxxx>
  • To: Seth Miller <sethmiller.sm@xxxxxxxxx>
  • Date: Thu, 28 Aug 2014 17:40:30 -0700

Hi All, 

Thanks for the group assistance. 

Seth had it 

Here is what I have done 



# echo offline > /sys/block/sdd/device/state 


At this point I saw that the failure:

ASMCMD commands to gather complementary metadata information:
==================================
                                  
State    Type    Rebal  Sector  Block       AU  Total_MB  Free_MB  
Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
MOUNTED  NORMAL  N         512   4096  4194304   8576580  1310328           
571772          369278              1             N  DATADG/
MOUNTED  NORMAL  N         512   4096  4194304   4574176  4567552           
571772         1997890              0             N  FRADG/
==================================


In order to recover from that on the Linux side just run 

echo running  > /sys/block/sdd/device/state


For “Fixing” the failure in the ASM instance just:

alter diskgroup datadg online disk DATA03; 


Once the above is done DATADG no disk would be reported as failed. 

Thx,
        Hanan


On Aug 28, 2014, at 2:59 PM, Hanan Hit <hithanan@xxxxxxxxx> wrote:

> Ha Got it. 
> 
> Thanks for your help.
> 
> Will try that and will keep you posted.
> 
> Best,
>       Hanan
> 
> On Aug 28, 2014, at 2:57 PM, Seth Miller <sethmiller.sm@xxxxxxxxx> wrote:
> 
>> The command I used would delete the "/dev/sdc" block device (along with its 
>> partition devices) but you would replace that with whichever block device 
>> you want to make go away.
>> 
>> Seth Miller
>> 
>> 
>> On Thu, Aug 28, 2014 at 4:54 PM, Hanan Hit <hithanan@xxxxxxxxx> wrote:
>> I can I choose only a single drive - or maybe I didn’t understand that.
>> 
>> Thanks,
>>      Hanan
>> 
>> On Aug 28, 2014, at 2:52 PM, Seth Miller <sethmiller.sm@xxxxxxxxx> wrote:
>> 
>>> Hanan,
>>> 
>>> You can simply delete the virtual representation of the device from the 
>>> scsi subsystem.
>>> 
>>> echo 1 > /sys/block/sdc/device/delete
>>> 
>>> Seth Miller
>>> 
>>> 
>>> On Thu, Aug 28, 2014 at 1:34 PM, Mark W. Farnham <mwf@xxxxxxxx> wrote:
>>> doh. right you are.
>>> 
>>>  
>>> 
>>> From: oracle-l-bounce@xxxxxxxxxxxxx [mailto:oracle-l-bounce@xxxxxxxxxxxxx] 
>>> On Behalf Of Matthew Zito
>>> Sent: Thursday, August 28, 2014 1:08 PM
>>> To: Mark W. Farnham
>>> Cc: hithanan@xxxxxxxxx; Chitale, Hemant K; ORACLE-L
>>> 
>>> 
>>> Subject: Re: Trying to Simulate a disk failure for one of the disks used by 
>>> ASM disk group
>>> 
>>>  
>>> 
>>> Remember, it's ASM, so there's no mounting or unmounting!
>>> 
>>> 
>>> Changing the permissions *might* work, but on Linux, since you still do an 
>>> open() and get a file descriptor even when you're doing direct I/O, I think 
>>> it would bypass it if the database is already running (since it already has 
>>> a valid FD it's writing to/from).
>>> 
>>>  
>>> 
>>>  
>>> 
>>>  
>>> 
>>> On Thu, Aug 28, 2014 at 1:03 PM, Mark W. Farnham <mwf@xxxxxxxx> wrote:
>>> 
>>> If this is Linux or Unix, then probably umount followed by a mount readonly 
>>> would do the trick if you’re writing to that disk at all.
>>> 
>>>  
>>> 
>>> Possibly changing the permissions would intervene, but I think that varies 
>>> about whether that will stop a running application that already has a file 
>>> open.
>>> 
>>>  
>>> 
>>> Heh. It was easier when there was a button on each drive you could toggle 
>>> to make it read only.
>>> 
>>>  
>>> 
>>>  
>>> 
>>> 
>> 
>> 
> 

Other related posts: