Re: dummy file read periodically for external USB Hard Disk

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 7 Jul 2014 22:42:29 +0800 loody <miloody@xxxxxxxxx> wrote:

> hi all:
>     we met a USB Hard Disk that will go to suspend if host stop
> sending scsi read command over 5mins.
>     To save the IO, kernel will keep the file in page cache as much as
> he can and under this circumstances, the read command may disappear
> for a while longer enough to cause the device suspend.
> 
>     is there any kernel config or module parameter can do the dummy
> read periodically, even the sector 0 (MBR) is fine.
>     or is there any kernel api I can use to read sector 0(MBR) maybe
> every 4mins?
> 
> appreciate your help in advance,
> --
> To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

Open the device with O_DIRECT and read a block every 4 minutes.
That should keep it awake.

NeilBrown

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux