Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-07-02 Thread Hans Petter Selasky
On Monday 02 July 2012 22:07:57 maxim naumov wrote:
> ok, done some more testing and measured throughput FreeBSD vs.
> GNU/Linux as you suggested:
> 
> # dd if=/dev/da0s1 of=/dev/null bs=1M count=1024
> 1024+0 records in
> 1024+0 records out
> 1073741824 bytes transferred in 33.181306 secs (32359842 bytes/sec)
> 
> and
> 
> # dd if=/dev/sdb1 of=/dev/null bs=1M count=1024
> 1024+0 records in
> 1024+0 records out
> 1073741824 bytes (1.1 GB) copied, 33.2969 s, 32.2 MB/s
> 
> I was doing more testing with dt, specifying different maximum and
> minimum block sizes for random transfers. the curious thing is that I
> could not fail it if the maximum block size is up to 16k. 32k and
> higher eventually kills it. it seems to require random transfer size
> to fail. the filesystem driver will do the same. doing just dd/dt with
> a specified bs works fine. also I haven't seen it fail with a transfer
> size smaller than 32k before. could this be something to do with the
> USB transfer size of 64k (32k of data plus umass command)?

Hi,

For High Speed, the software size limit is 64KBytes, because many devices 
don't support more.

--HPS
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-07-02 Thread maxim naumov
ok, done some more testing and measured throughput FreeBSD vs.
GNU/Linux as you suggested:

# dd if=/dev/da0s1 of=/dev/null bs=1M count=1024
1024+0 records in
1024+0 records out
1073741824 bytes transferred in 33.181306 secs (32359842 bytes/sec)

and

# dd if=/dev/sdb1 of=/dev/null bs=1M count=1024
1024+0 records in
1024+0 records out
1073741824 bytes (1.1 GB) copied, 33.2969 s, 32.2 MB/s

I was doing more testing with dt, specifying different maximum and
minimum block sizes for random transfers. the curious thing is that I
could not fail it if the maximum block size is up to 16k. 32k and
higher eventually kills it. it seems to require random transfer size
to fail. the filesystem driver will do the same. doing just dd/dt with
a specified bs works fine. also I haven't seen it fail with a transfer
size smaller than 32k before. could this be something to do with the
USB transfer size of 64k (32k of data plus umass command)?

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-28 Thread maxim naumov
On Thu, Jun 28, 2012 at 2:48 PM, maxim naumov
 wrote:

> I switched to using dt (http://www.scsifaq.org/RMiller_Tools/dt.html)
> for testing. I took the same source tarball and built it on GNU/Linux
> 2.6.38 x86_64 and my FreeBSD 8.3-STABLE.
>
> I run it with the following options:

oops, clicked 'send' inadvertently. so, the options:

./dt of=/dev/da0s1 min=128b max=256k incr=var enable=raw pattern=iot
enable=verify enable=verbose enable=compare enable=Debug flags=direct
iotype=random oncerr=abort

this does writes with subsequent reads of random lengths (between 128b
and 256kb) at random offsets.
on FreeBSD I also specify capacity to save detecting it with seeks.

I run two instances simultaneously, each running on it's own slice on
the Seagate in question. on GNU/Linux it doesn't fail even after hours
of testing (nor it was failing with the filesystem).
on FreeBSD it's usually within an hour or two before it fails with the
following error:

...
dt: Seeked to block 327447715 (0x138474a3) at byte position 149505536
dt: Record #30142 - Reading 168448 bytes (329 blocks) into buffer
0x28253000, lba's 327447715 - 327448043 (pos 149505536)
dt: WARNING: Record #30142, attempted to read 168448 bytes, read only
131072 bytes.
dt: Relative block number where the error occurred is 327447715,
position 149505536

dt: Error number 1 occurred on Thu Jun 28 13:55:51 2012
dt: Elapsed time since beginning of pass: 30m22.82s
dt: Elapsed time since beginning of test: dt: Seeked to block
327447715 (0x138474a3) at byte position 149505536
dt: Closing file '/dev/da0s1', fd = 3...

Total Statistics:
 Output device/file name: /dev/da0s1 (device type=character)
 Type of I/O's performed: random (rseed=0x21746c6, read-after-write)
   Random I/O Parameters: position=0, ralign=0, rlimit=15001551931422278144
Data pattern string used: 'IOT Pattern' (blocking is 512 bytes)
 Total records processed: 60284 with min=65536, max=262144, incr=variable
 Total bytes transferred: 11363891712 (11097550.500 Kbytes,
10837.452 Mbytes)
  Average transfer rates: 6233808 bytes/sec, 6087.703 Kbytes/sec
 Number I/O's per second: 33.070
  Total passes completed: 0/1
   Total errors detected: 1/1
  Total elapsed time: 30m22.94s
   Total system time: 00m10.46s
 Total user time: 01m14.00s
   Starting time: Thu Jun 28 13:25:28 2012
 Ending time: Thu Jun 28 13:55:51 2012

dt: Exiting with status code -1...
30m22.82s

I also had it fail on write:

...
dt: Seeked to block 304790691 (0x122abca3) at byte position 1434011136
dt: Record #2219 - Writing 275456 bytes (538 blocks) from buffer
0x3050, lba's 304790691 - 304791228 (pos 1434011136)
dt: Seeked to block 304790691 (0x122abca3) at byte position 1434011136
dt: Record #2219 - Reading 275456 bytes (538 blocks) into buffer
0x2c40, lba's 304790691 - 304791228 (pos 1434011136)
dt: Seeked to block 731792088 (0x2b9e42d8) at byte position 1015394304
dt: Record #2220 - Writing 63405056 bytes (123838 blocks) from buffer
0x3050, lba's 731792088 - 731915925 (pos 1015394304)
dt: Seeked to block 731792088 (0x2b9e42d8) at byte position 1015394304
dt: Record #2220 - Reading 63405056 bytes (123838 blocks) into buffer
0x2c40, lba's 731792088 - 731915925 (pos 1015394304)
dt: Seeked to block 1366206048 (0x516ea660) at byte position 3712794624
dt: Record #2221 - Writing 53971456 bytes (105413 blocks) from buffer
0x3050, lba's 1366206048 - 1366311460 (pos 3712794624)
dt: 'write', errno = 5 - Input/output error
dt: Relative block number where the error occurred is 1366295264,
position 3758473216
dt: Seeked to block 1366295265 (0x517002e1) at byte position 3758473728

dt: Error number 1 occurred on Wed Jun 27 20:12:44 2012
dt: Elapsed time since beginning of pass: 1h56m12.26s
dt: Elapsed time since beginning of test: dt: Closing file
'/dev/da0s1', fd = 3...

Total Statistics:
 Output device/file name: /dev/da0s1 (device type=character)
 Type of I/O's performed: random (rseed=0x1907816, read-after-write)
   Random I/O Parameters: position=0, ralign=0, rlimit=8660422083433464320
Data pattern string used: 'IOT Pattern' (blocking is 512 bytes)
 Total records processed: 4440 with min=65536, max=67108864, incr=variable
 Total bytes transferred: 149591452672 (146085403.000 Kbytes,
142661.526 Mbytes)
  Average transfer rates: 21432616 bytes/sec, 20930.289 Kbytes/sec
 Number I/O's per second: 0.636
  Total passes completed: 0/1
   Total errors detected: 1/1
  Total elapsed time: 1h56m19.61s
   Total system time: 00m51.47s
 Total user time: 26m54.40s
   Starting time: Wed Jun 27 18:15:43 2012
 Ending time: Wed Jun 27 20:12:52 2012

dt: Exiting with status code -1...
1h56m12.26s

it fails with a single instance too.

the sectors in question are not failing, as tested before and now. the
long smart test doesn't find errors. the Seagate seem

Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-28 Thread maxim naumov
On Mon, Jun 25, 2012 at 4:00 PM, Hans Petter Selasky  wrote:

> BTW: You could try to make a simple c-test program that reads and writes
> random LBA's from user-space, and see when it stops working.

I switched to using dt (http://www.scsifaq.org/RMiller_Tools/dt.html)
for testing. I took the same source tarball and built it on GNU/Linux
2.6.38 x86_64 and my FreeBSD 8.3-STABLE.

I run it with the following options:
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-25 Thread maxim naumov
On Mon, Jun 25, 2012 at 4:00 PM, Hans Petter Selasky  wrote:

> BTW: You could try to make a simple c-test program that reads and writes
> random LBA's from user-space, and see when it stops working.

left it running iozone -a on the block device for the whole evening.
iozone does lots of reads and writes of different sizes ("record sizes
of 4k to 16M for file sizes of 64k to 512M" from the man). observed
transfer rates in iostat smaller and larger than with previous tests.
no errors detected. 8(

however, I don't think iozone will seek further than 512M. previously
the errors appeared with higher LBAs. not sure if the failure depends
on offset, time, temperature, whatever.

will leave running iozone -A overnight.

to be honest, I was expecting it to fail much sooner. I am quite
puzzled why the fact of using a filesystem makes it fail.

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-25 Thread Denver Hull

maxim naumov wrote:

On Mon, Jun 25, 2012 at 4:29 PM, Denver Hull  wrote:



storage device.  If you're interested, I can either send you the source, or
make it available by ftp.  Might be easier than cobbling something up from
scratch.


Denver, that is very considerate of you. please do send me the source.
I was going to use iozone but so far couldn't figure out how to make
it work on block devices. I am also going to try msdosfs on that drive
in the meantime.

/max




The source is available here:
http://irresistible-images.com/files/diskrand/diskrand.tgz

For instructions, just type diskrand with no parameters.
If you have any trouble with it let me know.  It's been a while since I
used it, but I can probably still figure it out.

To build it, use gmake in the parent (diskrand) directory.  It will
figure out your platform and build diskrand in the appropriate
subdirectory: BSD, LINUX, SGI, etc.  Optional gmake targets you can use
are all, clean, install.  You may need to use clean first, then
install.  For FreeBSD, install puts the executable in /usr/local/bin.

It's mostly a tool to check for data corruption, so the normal use
automatically includes an initial data fill over the specified range
unless you disable it with -n.  The data consists of a pattern based on
the LBA.  Data compare errors result in an output of all the data that
didn't match, then it stops.  Other errors will also cause it to stop.
Reads always include a verification of the data, and writes are always a
data pattern based on the LBA.  It's unique for each LBA, but always the
same for a specific LBA.  In normal operation everything after the
initialization is random: the starting LBA, the size of the transfer,
whether it's a read or write.  You can override any of that with the
command-line switches.

You can run multiple copies of diskrand on one device by assigning a
different range within the device for each copy.  You can get a lot of
I/O activity going with that method.

I guess that's about all.  Let me know if you have any questions.

Thanks,

Denver


___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-25 Thread Mehmet Erol Sanliturk
On Mon, Jun 25, 2012 at 10:36 AM, maxim naumov
wrote:

> On Mon, Jun 25, 2012 at 4:29 PM, Denver Hull  wrote:
>
> > storage device.  If you're interested, I can either send you the source,
> or
> > make it available by ftp.  Might be easier than cobbling something up
> from
> > scratch.
>
> Denver, that is very considerate of you. please do send me the source.
> I was going to use iozone but so far couldn't figure out how to make
> it work on block devices. I am also going to try msdosfs on that drive
> in the meantime.
>
> /max
>


If the source made be available on an ftp server , the other people also
may use it .

Thank you very much .

Mehmet Erol Sanliturk
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-25 Thread maxim naumov
failed with msdosfs in the same way:

Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607370752, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607436288, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607501824, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607567360, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607632896, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607698432, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607763968, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607829504, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607895040, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607960576, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39608026112, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39608091648, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39608157184, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39608222720, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39608288256, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39608353792, length=65536)]error = 5
Jun 25 19:19:33 muxx kernel:
g_vfs_done():da0s1d[WRITE(offset=39607305216, length=65536)]error = 5

the HDD is bust, I have to powercycle it now.

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-25 Thread maxim naumov
On Mon, Jun 25, 2012 at 4:29 PM, Denver Hull  wrote:

> storage device.  If you're interested, I can either send you the source, or
> make it available by ftp.  Might be easier than cobbling something up from
> scratch.

Denver, that is very considerate of you. please do send me the source.
I was going to use iozone but so far couldn't figure out how to make
it work on block devices. I am also going to try msdosfs on that drive
in the meantime.

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-25 Thread Denver Hull

Hans Petter Selasky wrote:

BTW: You could try to make a simple c-test program that reads and writes
random LBA's from user-space, and see when it stops working.

   
Sorry to interrupt, but I have a test program that does exactly that, 
and more, that I used to use when I was testing SCSI disk arrays.  It 
works on a number of platforms, including FreeBSD, and should work on 
any type of storage device.  If you're interested, I can either send you 
the source, or make it available by ftp.  Might be easier than cobbling 
something up from scratch.


Thanks,

Denver

___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-25 Thread Hans Petter Selasky
On Monday 25 June 2012 00:22:54 maxim naumov wrote:
> On Sun, Jun 24, 2012 at 2:33 PM, Hans Petter Selasky  
wrote:
> > Ok, then it is not a USB host problem.
> 
> I am not sure I follow. to me that just proves that the HDD doesn't
> have an irrecoverable error on a particular sector. by irrecoverable I
> mean an error that would stop the HDD working altogether until power
> cycle rather than report a sector read/write error.
> 
> the question what screws up the HDD remains. the HDD can get screwed
> up by itself due to a bug in firmware, but why doesn't it happen with
> windoze or GNU/Linux? pure luck?

Hi,

You should compare things like CPU usage and number of interrupts during data 
transfer, before we could say anything for sure.

BTW: Maximum block size for USB 2.0 under FreeBSD is 64Kbytes.

BTW: You could try to make a simple c-test program that reads and writes 
random LBA's from user-space, and see when it stops working.

--HPS
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread maxim naumov
On Sun, Jun 24, 2012 at 2:33 PM, Hans Petter Selasky  wrote:

> Ok, then it is not a USB host problem.

I am not sure I follow. to me that just proves that the HDD doesn't
have an irrecoverable error on a particular sector. by irrecoverable I
mean an error that would stop the HDD working altogether until power
cycle rather than report a sector read/write error.

the question what screws up the HDD remains. the HDD can get screwed
up by itself due to a bug in firmware, but why doesn't it happen with
windoze or GNU/Linux? pure luck?

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread maxim naumov
root@muxx:/home/muxx # dd if=/dev/zero of=/dev/da0s1 bs=1M
dd: /dev/da0s1: short write on character device
dd: /dev/da0s1: end of device
767998+0 records in
767997+1 records out
805304231424 bytes transferred in 30699.477974 secs (26231854 bytes/sec)
root@muxx:/home/muxx #

no errors. this is the slice that had the filesystem on.

it looks like what breaks it is a particular sequence of operations.

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread Hans Petter Selasky
On Sunday 24 June 2012 14:33:03 maxim naumov wrote:
> On Sun, Jun 24, 2012 at 12:37 PM, Hans Petter Selasky  
wrote:
> >> 2FC2B95F
> 
> root@muxx:/home/muxx # dd if=/dev/da0 of=/dev/null bs=512
> iseek=801290500 count=1280
> 1280+0 records in
> 1280+0 records out
> 655360 bytes transferred in 0.619988 secs (1057053 bytes/sec)
> 
> no errors. tried 801290591 too.
> 
> root@muxx:/home/muxx # dd of=/dev/da0 if=/dev/zero bs=512
> oseek=801290500 count=1280
> 1280+0 records in
> 1280+0 records out
> 655360 bytes transferred in 0.646095 secs (1014340 bytes/sec)
> 
> no errors either.

Ok, then it is not a USB host problem.

--HPS
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread maxim naumov
On Sun, Jun 24, 2012 at 12:37 PM, Hans Petter Selasky  wrote:

>> 2FC2B95F

root@muxx:/home/muxx # dd if=/dev/da0 of=/dev/null bs=512
iseek=801290500 count=1280
1280+0 records in
1280+0 records out
655360 bytes transferred in 0.619988 secs (1057053 bytes/sec)

no errors. tried 801290591 too.

root@muxx:/home/muxx # dd of=/dev/da0 if=/dev/zero bs=512
oseek=801290500 count=1280
1280+0 records in
1280+0 records out
655360 bytes transferred in 0.646095 secs (1014340 bytes/sec)

no errors either.

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread Hans Petter Selasky
On Sunday 24 June 2012 13:24:50 Hans Petter Selasky wrote:
> 2FC2B95F

Correcting my self again:

LBA is 32-bit and length is 16-bit for READ/WRITE 10.

Else the size of these fields can vary.

--HPS


___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread Hans Petter Selasky
On Sunday 24 June 2012 13:22:29 maxim naumov wrote:
> On Sun, Jun 24, 2012 at 10:28 AM, Hans Petter Selasky  
wrote:
> > Here is a quick analysis:
> >     LBA = 0x2FC2B95F00, COUNT=0x80 (64K)
> 
> IIRC, LBA is a sector index. how can it be 0x2FC2B95F00 if the whole
> HDD has 0xAEA87B30 sectors?

The LBA is 24-bit Big Endian and is stored directly in the 31 bytes command 
sent to the USB device., Try removing the 00 in the end. Maybe I added one 
byte too much.

> 
> > dd if=/dev/daX of=/dev/null bs=512 iskip=205130391296 count=128
> 
> root@muxx:/home/muxx # dd if=/dev/da0 of=/dev/null bs=512
> skip=205130391296 count=128
> dd: /dev/da0: Input/output error
> 0+0 records in
> 0+0 records out
> 0 bytes transferred in 0.000318 secs (0 bytes/sec)
> 
> (no errors in logs)
> 

--HPS
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread maxim naumov
On Sun, Jun 24, 2012 at 10:28 AM, Hans Petter Selasky  wrote:

> Here is a quick analysis:
>     LBA = 0x2FC2B95F00, COUNT=0x80 (64K)

IIRC, LBA is a sector index. how can it be 0x2FC2B95F00 if the whole
HDD has 0xAEA87B30 sectors?

> dd if=/dev/daX of=/dev/null bs=512 iskip=205130391296 count=128

root@muxx:/home/muxx # dd if=/dev/da0 of=/dev/null bs=512
skip=205130391296 count=128
dd: /dev/da0: Input/output error
0+0 records in
0+0 records out
0 bytes transferred in 0.000318 secs (0 bytes/sec)

(no errors in logs)

if 0x2FC2B95F00 is a byte address,

root@muxx:/home/muxx # dd if=/dev/da0 of=/dev/null bs=512
skip=400645295 count=128
128+0 records in
128+0 records out
65536 bytes transferred in 0.062703 secs (1045183 bytes/sec)

(no errors in logs)

however, I don't see 0x2FC2B95F00 anywhere while dumping with usbdump.

I am quite puzzled. I will try and write the whole partition with
zeroes and large block size in the meantime.

/maxOn Sun, Jun 24, 2012 at 10:28 AM, Hans Petter Selasky
 wrote:

> Here is a quick analysis:
>     LBA = 0x2FC2B95F00, COUNT=0x80 (64K)

IIRC, LBA is a sector index. how can it be 0x2FC2B95F00 if the whole
HDD has 0xAEA87B30 sectors?

> dd if=/dev/daX of=/dev/null bs=512 iskip=205130391296 count=128

root@muxx:/home/muxx # dd if=/dev/da0 of=/dev/null bs=512
skip=205130391296 count=128
dd: /dev/da0: Input/output error
0+0 records in
0+0 records out
0 bytes transferred in 0.000318 secs (0 bytes/sec)

(no errors in logs)

if 0x2FC2B95F00 is a byte address,

root@muxx:/home/muxx # dd if=/dev/da0 of=/dev/null bs=512
skip=400645295 count=128
128+0 records in
128+0 records out
65536 bytes transferred in 0.062703 secs (1045183 bytes/sec)

(no errors in logs)

however, I don't see 0x2FC2B95F00 anywhere while dumping with usbdump.

I am quite puzzled. I will try and write the whole partition with
zeroes and large block size in the meantime.

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread Hans Petter Selasky
Hi,

Here is a quick analysis:

On Sunday 24 June 2012 10:43:02 maxim naumov wrote:
>  IMMED|DOING_CALLBACK|0> 01:06:03.757382 usbus3.2
> SUBM-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=32,IVAL=0 frame[0] WRITE 31
> bytes
>    55 53 42 43 80 90 06 00  00 00 01 00 00 00 0A 2A  |USBC...*|
     10 byte WRITE_10 SCSI command, len = 64K

>  0010  00 2F C2 B9 5F 00 00 80  00 00 00 00 00 00 00 --  |./.._.. |
     LBA = 0x2FC2B95F00, COUNT=0x80 (64K)

>  LLBACK|0> 01:06:03.757537 usbus3.2
> DONE-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=0,IVAL=0,ERR=0
>  frame[0] WRITE 31 bytes
>  flags 0 <0>
>  status 0xea021
>  LLBACK|0> 01:06:03.757697 usbus3.2
> SUBM-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=65536,IVAL=0 frame[0] WRITE
> 65536 bytes
>  flags 0x32 
>  status 0xea023
>  MMED|DOING_CALLBACK|0> 01:06:03.758544 usbus3.2
> DONE-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=0,IVAL=0,ERR=STALLED
>  frame[0] WRITE 20992 bytes
>  flags 0x32 
>  status 0xca021
> 
> 01:06:03.758561 usbus3.2 SUBM-CTRL-EP=,SPD=HIGH,NFR=1,SLEN=8,IVAL=0
>  frame[0] WRITE 8 bytes
>    02 01 00 00 02 00 00 00  -- -- -- -- -- -- -- --  ||

USB stack tries to clear stall on endpoint 0x02, but there is no response from 
the device. Then the USB stack tries to recover the device.

>  flags 0 <0>
>  status 0xea1a3
>  URR_DMA_SET|CAN_CANCEL_IMMED|DOING_CALLBACK|0> 01:06:03.758654 usbus3.2
> DONE-CTRL-EP=,SPD=HIGH,NFR=1,SLEN=0,IVAL=0,ERR=STALLED

Try to manually read the given LBA and COUNT:

dd if=/dev/daX of=/dev/null bs=512 iskip=205130391296 count=128

--HPS
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread maxim naumov
On Sat, Jun 23, 2012 at 7:51 PM, Warren Block  wrote:

> So it's worth trying to disable power saving on that drive. sysutils/ataidle
> can do it, and can run from rc.conf:
>  ataidle_enable="YES"
>  ataidle_devices="da0"
>  ataidle_da0="-P 0"

thanks Warren. I can't see how it would go to sleep mid-transfer. I
can see from iostat transfers going continuously and at great speeds
and then the error happens. the backup software is not stalling at the
source or anything.

I will try your suggestion later. currently every test means hanging
and rebooting a working server and is a bit of a pain. 8(

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-24 Thread maxim naumov
it took me a while to rebuild the world and reproduce the problem with
usbdump running. there goes the bit of log around the point where it
failed.

...
01:06:03.753907 usbus3.2
DONE-BULK-EP=0081,SPD=HIGH,NFR=1,SLEN=16,IVAL=0,ERR=0
 frame[0] READ 13 bytes
   55 53 42 53 7E 90 06 00  00 00 00 00 00 -- -- --  |USBS~   |
 flags 0x2 
 status 0xcb021

01:06:03.753962 usbus3.2 SUBM-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=32,IVAL=0
 frame[0] WRITE 31 bytes
   55 53 42 43 7F 90 06 00  00 00 01 00 00 00 0A 2A  |USBC...*|
 0010  00 2F C2 B8 DF 00 00 80  00 00 00 00 00 00 00 --  |./. |
 flags 0 <0>
 status 0xea023

01:06:03.754030 usbus3.2
DONE-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=0,IVAL=0,ERR=0
 frame[0] WRITE 31 bytes
 flags 0 <0>
 status 0xca021

01:06:03.754214 usbus3.2 SUBM-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=65536,IVAL=0
 frame[0] WRITE 65536 bytes
 flags 0x32 
 status 0xca023

01:06:03.756409 usbus3.2
DONE-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=0,IVAL=0,ERR=0
 frame[0] WRITE 65536 bytes
 flags 0x32 
 status 0xea021

01:06:03.756419 usbus3.2 SUBM-BULK-EP=0081,SPD=HIGH,NFR=1,SLEN=0,IVAL=0
 frame[0] READ 13 bytes
 flags 0x2 
 status 0xcb023

01:06:03.756529 usbus3.2
DONE-BULK-EP=0081,SPD=HIGH,NFR=1,SLEN=16,IVAL=0,ERR=0

 frame[0] READ 13 bytes
   55 53 42 53 7F 90 06 00  00 00 00 00 00 -- -- --  |USBS.   |
 flags 0x2 
 status 0xeb021

01:06:03.757382 usbus3.2 SUBM-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=32,IVAL=0
 frame[0] WRITE 31 bytes
   55 53 42 43 80 90 06 00  00 00 01 00 00 00 0A 2A  |USBC...*|
 0010  00 2F C2 B9 5F 00 00 80  00 00 00 00 00 00 00 --  |./.._.. |
 flags 0 <0>
 status 0xca023

01:06:03.757537 usbus3.2
DONE-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=0,IVAL=0,ERR=0
 frame[0] WRITE 31 bytes
 flags 0 <0>
 status 0xea021

01:06:03.757697 usbus3.2 SUBM-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=65536,IVAL=0
 frame[0] WRITE 65536 bytes
 flags 0x32 
 status 0xea023

01:06:03.758544 usbus3.2
DONE-BULK-EP=0002,SPD=HIGH,NFR=1,SLEN=0,IVAL=0,ERR=STALLED
 frame[0] WRITE 20992 bytes
 flags 0x32 
 status 0xca021

01:06:03.758561 usbus3.2 SUBM-CTRL-EP=,SPD=HIGH,NFR=1,SLEN=8,IVAL=0
 frame[0] WRITE 8 bytes
   02 01 00 00 02 00 00 00  -- -- -- -- -- -- -- --  ||
 flags 0 <0>
 status 0xea1a3

01:06:03.758654 usbus3.2
DONE-CTRL-EP=,SPD=HIGH,NFR=1,SLEN=0,IVAL=0,ERR=STALLED
 frame[0] WRITE 0 bytes
 flags 0 <0>
 status 0xca1a1

...

and then it is "stalled" until I rebooted the machine. I had to,
because it was totally screwed.

full log available upon request. 8)

/max
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-23 Thread Warren Block

On Sat, 23 Jun 2012, maxim naumov wrote:


I am having problems with a recently purchased external HDD:
0bc2:5031 Seagate RSS LLC, FreeAgent GoFlex 1.5TB USB 3.0.

the HDD would work fine for a while but then the kernel would lock up
and require a powercycle. after turning off soft updates on that
filesystem the lock up has disappeared, but the system still reports
lots of errors repeatedly like the following:

Jun 22 17:05:13  kernel: (da0:umass-sim0:0:0:0): AutoSense failed
Jun 22 17:05:13  kernel:
g_vfs_done():da0s1d[WRITE(offset=406613852160, length=16384)]error = 5

after getting into that state the HDD seems unresponsive. usbconfig
reset/power doesn't help, you have to physically unplug the drive and
plug it back in.

the same FreeBSD box, same USB socket, same cable, same backup
software and data, but a different USB 3.0 drive (Verbatim 1TB) shows
no errors.


Doing some research on drives lately, I saw notes from Mac users 
complaining that these drives went off-line due to power saving. 
Unfortunately I can't find those comments again.


So it's worth trying to disable power saving on that drive. 
sysutils/ataidle can do it, and can run from rc.conf:

  ataidle_enable="YES"
  ataidle_devices="da0"
  ataidle_da0="-P 0"

Failing that, the Windows software included with the drive might be able 
to disable the standby or sleep mode.  Apparently some of these drives 
ignore that and sleep anyway.  I would call that defective and return 
the drive.

___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"


Re: Seagate FreeAgent GoFlex 1.5TB external HDD problems

2012-06-23 Thread Hans Petter Selasky
On Saturday 23 June 2012 15:43:15 maxim naumov wrote:
> hi everyone
> 
> I am having problems with a recently purchased external HDD:
> 0bc2:5031 Seagate RSS LLC, FreeAgent GoFlex 1.5TB USB 3.0.
> 
> the HDD would work fine for a while but then the kernel would lock up
> and require a powercycle. after turning off soft updates on that
> filesystem the lock up has disappeared, but the system still reports
> lots of errors repeatedly like the following:
> 
> Jun 22 17:05:13  kernel: (da0:umass-sim0:0:0:0): AutoSense failed
> Jun 22 17:05:13  kernel:
> g_vfs_done():da0s1d[WRITE(offset=406613852160, length=16384)]error = 5
> Jun 22 17:05:13  kernel:
> g_vfs_done():da0s1d[WRITE(offset=406613868544, length=16384)]error = 5
> Jun 22 17:05:13  kernel:
> g_vfs_done():da0s1d[WRITE(offset=406613884928, length=16384)]error = 5
> Jun 22 17:05:13  kernel:
> g_vfs_done():da0s1d[WRITE(offset=406613901312, length=16384)]error = 5
> Jun 22 17:05:13  kernel:
> g_vfs_done():da0s1d[WRITE(offset=406613917696, length=16384)]error = 5
> Jun 22 17:05:13  kernel:
> g_vfs_done():da0s1d[WRITE(offset=406613934080, length=16384)]error = 5
> Jun 22 17:05:13  kernel:
> g_vfs_done():da0s1d[WRITE(offset=406613950464, length=16384)]error = 5
> 
> after getting into that state the HDD seems unresponsive. usbconfig
> reset/power doesn't help, you have to physically unplug the drive and
> plug it back in.
> 
> the same FreeBSD box, same USB socket, same cable, same backup
> software and data, but a different USB 3.0 drive (Verbatim 1TB) shows
> no errors.
> 
> I tried the UQ_MSC_NO_SYNC_CACHE quirk, no luck.
> 
> I initially thought the drive was failing, but the long smart test
> detected no errors.
> 
> it looks like the Seagate is getting its knickers in a twist for some
> reason, but after similar tests I found that it works fine in
> GNU/Linux 2.6.38, however, the following error is displayed from time
> to time during transfers:
> 
> [ 5633.140506] sd 7:0:0:0: [sdb]  Sense Key : Recovered Error
> [current] [descriptor]
> [ 5633.140521] Descriptor sense data with sense descriptors (in hex):
> [ 5633.140526] 72 01 04 1d 00 00 00 0e 09 0c 00 00 00 00 00 00
> [ 5633.140548] 00 4f 00 c2 40 50
> [ 5633.140560] sd 7:0:0:0: [sdb]  ASC=0x4 ASCQ=0x1d
> [ 5700.040026] [Hardware Error]: Machine check events logged
> 
> googling shows that this is a known but benign problem: "SMART
> responses for SATA disks on SAS get interpreted as errors".
> http://forums.whirlpool.net.au/archive/1881928
> https://bugzilla.kernel.org/show_bug.cgi?id=13594
> 
> I was wondering if the GNU/Linux error is somehow related to the
> problem I see with FreeBSD. perhaps it is also seen as an error but
> the umass code doesn't cope well with it.
> 
> more info about my system: 8.2-RELEASE on i386. USB2 EHCI host
> controller: Intel Corporation 82801DB/DBM.
> 
> it looks like it is more likely to fail when transferring large files.
> I use the external HDD for backups (rdiff-backup), backing up hundreds
> of GBs, with many files over 1GB.
> 
> any ideas and requests for more data are welcome.

Hi,

To figure out what is actually going on, you can try running "usbdump -i X -f 
Y -s 1024 -vvv".

Also, there are some ehci quirks under hw.usb.ehci, not sure if they will 
help. Depends on the information you get from usbdump.

--HPS
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to "freebsd-usb-unsubscr...@freebsd.org"