Disable annoying stand by mode of Seagate FreeAgent USB Hard Drive [Fail]

-- This was the first attempt to disable tSeaGate FreeAgent Hard Drive from going to sleep
And it does not work for my drive. --

I've been using Seagate FreeAgent USB Hard Drive (2TB to be exact) for several months now.
It was really working fine with my Windows7 , but when I moved to Linux, it keeps popping up file browser window every 10 min (nautilus window)

I did many searches and found that it is caused from Stand by mode of the hard drive.

When it's idle for too long, it goes to sleep mode, and when it is trigger (which i don't know by whom), the USB get connected and Nautilus acts as it's just got plugged in.

So, the work around is to set the hard drive to disable the stand by mode.

first, install sdparm

sudo apt-get install sdparm

then, find out what device is the hard drive

dmesg | grep -3 -i seagate[ 2808.171733] scsi 7:0:0:0: Direct-Access     Seagate  FA GoFlex Desk   0155 PQ: 0 ANSI: 4[ 2808.173285] sd 7:0:0:0: Attached scsi generic sg2 type 0[ 2808.174081] sd 7:0:0:0: [sdb] 3907029167 512-byte logical blocks: (2.00 TB/1.81 TiB)[ 2808.175057] sd 7:0:0:0: [sdb] Write Protect is off

ok, now we know that it's "sdb"
we can use sdparm to see it's configurations.
sudo sdparm -a /dev/sdb

If seeing that "mode page seems malformed", like this
    /dev/sdb: Seagate   FA GoFlex Desk    0155Power condition mode page:>>> warning: mode page seems malformed   The page number field should be 0x1a, but is 0x00; try '--flexible'
meaning, the sdparm command can't figure out which mode it needs to use, either 6 bit, or 10 bit mode.
After looking into several solutions,  It seems  this hard drive is using 6 bit mode.
just adding "-6" to the command. it'll be like
sudo sdparm -a -6 /dev/sdb    /dev/sdb: Seagate   FA GoFlex Desk    0155Power condition mode page:  IDLE        0  [cha: n, def:  0, sav:  0]  STANDBY     1  [cha: y, def:  1, sav:  1]  ICT         0  [cha: n, def:  0, sav:  0]  SCT       9000  [cha: y, def:9000, sav:9000]
Seeing the STANDBY = 1
time to turn it off.
sudo sdparm --clear STANDBY -6 /dev/sdb
save it
sudo sdparm --save -6 /dev/sdb
it should be done.
seeing the config again, it will be like this
sudo sdparm -a -6 /dev/sdb    /dev/sdb: Seagate   FA GoFlex Desk    0155Power condition mode page:  IDLE        0  [cha: n, def:  0, sav:  0]  STANDBY     0  [cha: y, def:  1, sav:  1]  ICT         0  [cha: n, def:  0, sav:  0]  SCT       4294967286  [cha: y, def:9000, sav:9000]
Now, STANDBY is off (0),  
But the default (def/sav) is still 1 ...
meaning it isn't saved at all

so, possibly setup a script to run at start-up will work.

if the device is stopped, start it first by using this command
sudo sdparm --command start /dev/sdb

manually stop it moving by using this 
sudo sdparm --command stop /dev/sdb

No comments:

Post a Comment