I did some further investigation. This is *exactly* the same issue as with hdparm. sg_start and sdparm both open the device file in read-write (O_RDWR) mode even though they only need to do it on read-only in order to do ioctls. Ubuntu's udev configuration watches the device files for being closed by a program that had them in open in O_RDWR mode and runs a helper which inspects the disk to add more information about the for udev. This triggers the disk to spin up right after it had been sent the command to spin down.
The solution is to change sg3-utils & sdparm to open on read only as they should have done to begin with. I tried it by compiling a version of sg_start with that modification and it worked as expected. It's hard to believe that this wouldn't have been done by any distribution after all this time. -- External disk won't spindown https://bugs.launchpad.net/bugs/444818 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs