Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I make my computer sleep but not automatically change the state of the USB flash drive I am using? I have it mounted on / because my hard drive broke, and whenever my computer wakes up it remounts as a read-only FS and I need to run fsck on reboot. haw can I avoid this? the flash drive is /dev/sda2 and the filesystem is ext4.

share|improve this question

I'm not sure it would works well with USB 'flash' drive, but here's similar question and answer from SE.

I guess that using 'hdparm' with '-B 255' option is what you want.

share|improve this answer
from the hdparm wikipedia article: hdparm is a command line utility for the Linux and Windows operating systems to set and view ATA hard disk drive hardware parameters. It can set parameters such as drive caches, sleep mode, power management, acoustic management, and DMA settings. GParted and Parted Magic both include hdparm. – Jakob Weisblat Nov 30 '12 at 13:56
so it wouldn't work with a flash drive. Also, I think (though I cannot access *.stackexchange because it is blocked at my school) that answer refers to preventing the drive itself from sleeping, not preventing the drive from being nonpeacefully disconnected when the computer sleeps. I could be wrong about that, however. Thanks anyway. – Jakob Weisblat Nov 30 '12 at 13:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .