I got an HDD attached via dock station. Gentoo spins it down each ten minutes which leads to wearing out the disk spindle and moreover, waiting for the drive to spin up each time is inconvenient. I’ve tried hdparm -B255 and -S0, but these commands do not work on the disk, hdparm returns with an error
HDIO_DRIVE_CMD failed: Invalid argument
And reports that Advanced power management is disabled. Though the disk keeps spinning down often. If I detach the USB cable from the laptop, while the disk is running, it can work until I turn off the dock station, so the problem is in the OS. I’ve read that ATA commands cannot passed through the USB controller, but OS somehow manages to spin it down? How do I prevent that?
Update:
# hdparm -I /dev/sdb | grep Advan
Advanced power management level: disabled
# hdparm -B255 /dev/sdb
/dev/sdb:
setting Advanced Power Management level to disabled
HDIO_DRIVE_CMD failed: Invalid argument
APM_level = off
# hdparm -S0 /dev/sdb
/dev/sdb:
setting standby to 0 (off)
HDIO_DRIVE_CMD(setidle) failed: Invalid argument