dasguru

Members
  • Posts

    1
  • Joined

  • Last visited

Converted

  • Gender
    Undisclosed

dasguru's Achievements

Noob

Noob (1/14)

0

Reputation

  1. Hey, I solved this by thinking a bit differently, works flawlessly to get harddrives to spin down. Atleast for me. Since RDM mapped drives is actually running on a virtualized scsi controller inside the machine S.M.A.R.T. works but sleep does not as for all you others. I installed a software called sdparm for scsi controllers/drives (not hdparm which you all try to use above) and wrote a custom made script to put harddrives to sleep when inactive. They will properly wake up when accessed as they are expected to. unRAID readings if the drives are sleeping or not will still show wrong values, but if youre listening to the drives you will hear them spin down, and the temperature readings will change. In order to use sdparm do the following: Find out the scsi link to your drive with "lsscsi" and look for the numbers in the first columt. Example [2:0:4:0] for in my case /dev/sdd [2:0:3:0] disk ATA WDC WD1002FAEX-0 05.0 /dev/sdd [2:0:4:0] disk ATA WDC WD1002FAEX-0 05.0 /dev/sde [2:0:5:0] disk ATA WDC WD1002FAEX-0 05.0 /dev/sdf Send the following commands to the controller: /path/to/sdparm --quiet --command=sync /dev/bsg/2:0:4:0 /path/to/sdparm --quiet --command=stop /dev/bsg/2:0:4:0 This will properly spin down the RDM mapped drive even if it is on the motherboard, atleast in my case. Use the statistics from /proc/diskstats in order to fetch current statistics, and save them. Save this to a temp file, for use for the next run of the script. "cat /proc/diskstats |grep sdd > /dev/shm/sdd.stats" The temp file will contain the following "cat /dev/shm/sdd.stats" 8 48 sdd 123 456 789 0123 45678 90123456 If the numbers has not changed on the second run, send the commands to the drives and they will go to sleep. Do not forget to turn of unRAID's internal hdd sleep for this to work, since running hdparm at the same time will mess things up. hdparm does not find the drives as proper ATA drives even if they are presented as such. Give it a go and good luck. ---- Currently running ESXi 5.1 Update 1 on a non supported motherboard without VT-d for passthrough so all drives are RDM mapped and this works, so it should definitly work for you, but takes a bit of tinkering. This also works under most linux distributions I have tried on that also have RDM mapped drives in the same server, each virtual host can control its own drive without further tinkering with hdparm, use sdparm.