All of lore.kernel.org
 help / color / mirror / Atom feed
* pata_via with software raid1: "attempt to access beyond end of device"
@ 2007-07-19  2:23 Dâniel Fraga
  2007-07-19 23:17 ` Alan Cox
  0 siblings, 1 reply; 15+ messages in thread
From: Dâniel Fraga @ 2007-07-19  2:23 UTC (permalink / raw)
  To: linux-ide

Linux 2.6.22
Intel(R) Celeron(R) CPU 2.26GHz
00:0f.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT8233/A/C/VT8235 PIPC Bus Master IDE (rev 06)
Reiserfs3

	I have 2 PATA HDs and they always worked perfectly with
software (kernel) raid1 using the old IDE kernel drivers. Now I use
the new libata drivers (VIA), and it keep giving those erros messages:

attempt to access beyond end of device
md1: rw=0, want=155284112, limit=155284096

	Is it raid's fault? Or libata's fault? The raid1 is ok:

/dev/md1:
        Version : 00.90.03
  Creation Time : Wed Jul 11 03:38:05 2007
     Raid Level : raid1
     Array Size : 77642048 (74.05 GiB 79.51 GB)
  Used Dev Size : 77642048 (74.05 GiB 79.51 GB)
   Raid Devices : 2
  Total Devices : 2
Preferred Minor : 1
    Persistence : Superblock is persistent

    Update Time : Wed Jul 18 23:22:24 2007
          State : clean
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

           UUID : 6aed7615:3574770f:268e26d7:19872c99
         Events : 0.29260

    Number   Major   Minor   RaidDevice State
       0       8        2        0      active sync   /dev/sda2
       1       8       18        1      active sync   /dev/sdb2

-- 
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net
The Pointer Sisters - "Automatic" (Platinum & Gold Collection Series)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* pata_via with software raid1: "attempt to access beyond end of device"
@ 2007-07-19  2:24 Dâniel Fraga
  2007-07-19  3:54 ` Neil Brown
  2007-07-30 19:01 ` Cry Regarder
  0 siblings, 2 replies; 15+ messages in thread
From: Dâniel Fraga @ 2007-07-19  2:24 UTC (permalink / raw)
  To: linux-raid

Linux 2.6.22
Intel(R) Celeron(R) CPU 2.26GHz
00:0f.1 IDE interface: VIA Technologies, Inc.
VT82C586A/B/VT82C686/A/B/VT8233/A/C/VT8235 PIPC Bus Master IDE (rev 06)
Reiserfs3

	I have 2 PATA HDs and they always worked perfectly with
software (kernel) raid1 using the old IDE kernel drivers. Now I use
the new libata drivers (VIA), and it keep giving those erros messages:

attempt to access beyond end of device
md1: rw=0, want=155284112, limit=155284096

	Is it raid's fault? Or libata's fault? The raid1 is ok:

/dev/md1:
        Version : 00.90.03
  Creation Time : Wed Jul 11 03:38:05 2007
     Raid Level : raid1
     Array Size : 77642048 (74.05 GiB 79.51 GB)
  Used Dev Size : 77642048 (74.05 GiB 79.51 GB)
   Raid Devices : 2
  Total Devices : 2
Preferred Minor : 1
    Persistence : Superblock is persistent

    Update Time : Wed Jul 18 23:22:24 2007
          State : clean
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

           UUID : 6aed7615:3574770f:268e26d7:19872c99
         Events : 0.29260

    Number   Major   Minor   RaidDevice State
       0       8        2        0      active sync   /dev/sda2
       1       8       18        1      active sync   /dev/sdb2

-- 
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net
Maroon 5 - "Shiver" (Songs About Jane)
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net
The Pointer Sisters - "Automatic" (Platinum & Gold Collection Series)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-19  2:24 pata_via with software raid1: "attempt to access beyond end of device" Dâniel Fraga
@ 2007-07-19  3:54 ` Neil Brown
  2007-07-19 18:23   ` Dâniel Fraga
  2007-07-30 19:01 ` Cry Regarder
  1 sibling, 1 reply; 15+ messages in thread
From: Neil Brown @ 2007-07-19  3:54 UTC (permalink / raw)
  To: Dâniel Fraga; +Cc: linux-raid

On Wednesday July 18, fragabr@gmail.com wrote:
> Linux 2.6.22
> Intel(R) Celeron(R) CPU 2.26GHz
> 00:0f.1 IDE interface: VIA Technologies, Inc.
> VT82C586A/B/VT82C686/A/B/VT8233/A/C/VT8235 PIPC Bus Master IDE (rev 06)
> Reiserfs3
> 
> 	I have 2 PATA HDs and they always worked perfectly with
> software (kernel) raid1 using the old IDE kernel drivers. Now I use
> the new libata drivers (VIA), and it keep giving those erros messages:
> 
> attempt to access beyond end of device
> md1: rw=0, want=155284112, limit=155284096

The resierfs filesystem is trying to access beyond the end of the
raid1 array.  Maybe some indexing information in the array is
corrupted.
Did you recreate the array (mdadm --create) after changing to the new
drivers?  If so, could you have accidentally made it a little smaller?

Possibly try running fsck and see if it finds anything to fix.

NeilBrown

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-19  3:54 ` Neil Brown
@ 2007-07-19 18:23   ` Dâniel Fraga
  2007-07-20  2:14     ` Neil Brown
  0 siblings, 1 reply; 15+ messages in thread
From: Dâniel Fraga @ 2007-07-19 18:23 UTC (permalink / raw)
  To: linux-raid

On Thu, 19 Jul 2007 13:54:50 +1000
Neil Brown <neilb@suse.de> wrote:

> The resierfs filesystem is trying to access beyond the end of the
> raid1 array.  Maybe some indexing information in the array is
> corrupted.
> Did you recreate the array (mdadm --create) after changing to the new
> drivers?  If so, could you have accidentally made it a little smaller?
> 
> Possibly try running fsck and see if it finds anything to fix.

	Hi Neil, I recreated the array after changing to libata. I
checked the whole filesystem with reiserfsck --rebuild-tree, then
started it again and the problem happens suddenly.

	And regarding the size of array, I just added the whole
partition to the array:

Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/md1              77639736  30127524  47512212  39% /

     Array Size : 77642048 (74.05 GiB 79.51 GB)
  Used Dev Size : 77642048 (74.05 GiB 79.51 GB)

	Can I compare both values (77639736 with 77642048)? If so,
there is a difference, if not, I don't know.

	Thank you!

	Ps: the error is difficult to appear, but I'll keep looking on
it and try to ellaborate a more detailed report. 

-- 
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-19  2:23 Dâniel Fraga
@ 2007-07-19 23:17 ` Alan Cox
  2007-07-20  0:25   ` Dâniel Fraga
  0 siblings, 1 reply; 15+ messages in thread
From: Alan Cox @ 2007-07-19 23:17 UTC (permalink / raw)
  To: Dâniel Fraga; +Cc: linux-ide

On Wed, 18 Jul 2007 23:23:19 -0300
Dâniel Fraga <fragabr@gmail.com> wrote:

> Linux 2.6.22
> Intel(R) Celeron(R) CPU 2.26GHz
> 00:0f.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT8233/A/C/VT8235 PIPC Bus Master IDE (rev 06)
> Reiserfs3
> 
> 	I have 2 PATA HDs and they always worked perfectly with
> software (kernel) raid1 using the old IDE kernel drivers. Now I use
> the new libata drivers (VIA), and it keep giving those erros messages:
> 
> attempt to access beyond end of device
> md1: rw=0, want=155284112, limit=155284096

Are their host protected areas on the two disks ?

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-19 23:17 ` Alan Cox
@ 2007-07-20  0:25   ` Dâniel Fraga
  2007-07-20  2:38     ` Dâniel Fraga
  2007-07-20 15:37     ` Alan Cox
  0 siblings, 2 replies; 15+ messages in thread
From: Dâniel Fraga @ 2007-07-20  0:25 UTC (permalink / raw)
  To: linux-ide

On Fri, 20 Jul 2007 00:17:14 +0100
Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:

> Are their host protected areas on the two disks ?

	I don't know, but hdparm returns this:

/dev/sda:

ATA device, with non-removable media
        Model Number:       ST3802110A                              
        Serial Number:      5LR2DA69
        Firmware Revision:  3.AAE   
Standards:
        Supported: 7 6 5 4 
        Likely used: 7
Configuration:
        Logical         max     current
        cylinders       16383   16383
        heads           16      16
        sectors/track   63      63
        --
        CHS current addressable sectors:   16514064
        LBA    user addressable sectors:  156301488
        LBA48  user addressable sectors:  156301488
        device size with M = 1024*1024:       76319 MBytes
        device size with M = 1000*1000:       80026 MBytes (80 GB)
Capabilities:
        LBA, IORDY(can be disabled)
        Queue depth: 1
        Standby timer values: spec'd by Standard, no device specific minimum
        R/W multiple sector transfer: Max = 16  Current = 1
        Recommended acoustic management value: 208, current value: 0
        DMA: mdma0 mdma1 mdma2 udma0 udma1 *udma2 udma3 udma4 udma5 
             Cycle time: min=120ns recommended=120ns
        PIO: pio0 pio1 pio2 pio3 pio4 
             Cycle time: no flow control=240ns  IORDY flow control=120ns
Commands/features:
        Enabled Supported:
           *    READ BUFFER cmd
           *    WRITE BUFFER cmd
           *    Host Protected Area feature set
           *    Look-ahead
           *    Write cache
           *    Power Management feature set
                Security Mode feature set
           *    SMART feature set
           *    FLUSH CACHE EXT command
           *    Mandatory FLUSH CACHE command 
           *    Device Configuration Overlay feature set 
           *    48-bit Address feature set 
                SET MAX security extension
           *    DOWNLOAD MICROCODE cmd
           *    General Purpose Logging feature set
           *    SMART self-test 
           *    SMART error logging 
Security: 
        Master password revision code = 65534
                supported
        not     enabled
        not     locked
        not     frozen
        not     expired: security count
        not     supported: enhanced erase
HW reset results:
        CBLID- above Vih
        Device num = 0 determined by the jumper
Checksum: correct

	***

/dev/sdb:

ATA device, with non-removable media
        Model Number:       ST3802110A                              
        Serial Number:      5LR3ZQ6A
        Firmware Revision:  3.AAE   
Standards:
        Supported: 7 6 5 4 
        Likely used: 7
Configuration:
        Logical         max     current
        cylinders       16383   16383
        heads           16      16
        sectors/track   63      63
        --
        CHS current addressable sectors:   16514064
        LBA    user addressable sectors:  156301488
        LBA48  user addressable sectors:  156301488
        device size with M = 1024*1024:       76319 MBytes
        device size with M = 1000*1000:       80026 MBytes (80 GB)
Capabilities:
        LBA, IORDY(can be disabled)
        Queue depth: 1
        Standby timer values: spec'd by Standard, no device specific minimum
        R/W multiple sector transfer: Max = 16  Current = 1
        Recommended acoustic management value: 208, current value: 0
        DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 *udma5 
             Cycle time: min=120ns recommended=120ns
        PIO: pio0 pio1 pio2 pio3 pio4 
             Cycle time: no flow control=240ns  IORDY flow control=120ns
Commands/features:
        Enabled Supported:
           *    READ BUFFER cmd
           *    WRITE BUFFER cmd
           *    Host Protected Area feature set
           *    Look-ahead
           *    Write cache
           *    Power Management feature set
                Security Mode feature set
           *    SMART feature set
           *    FLUSH CACHE EXT command
           *    Mandatory FLUSH CACHE command 
           *    Device Configuration Overlay feature set 
           *    48-bit Address feature set 
                SET MAX security extension
           *    DOWNLOAD MICROCODE cmd
           *    General Purpose Logging feature set
           *    SMART self-test 
           *    SMART error logging 
Security: 
        Master password revision code = 65534
                supported
        not     enabled
        not     locked
        not     frozen
        not     expired: security count
        not     supported: enhanced erase
HW reset results:
        CBLID- above Vih
        Device num = 0 determined by the jumper
Checksum: correct

	***

	Both HDs are identical. How can I determine if it's a Host
Protected Area?

	SMART information, if needed:

fraga@abusar ~$ sudo ide-smart /dev/sda
Id=  1  Status=15  {Prefailure  Online }  Value=100  Threshold=  6  Passed
Id=  3  Status= 3  {Prefailure  Online }  Value= 99  Threshold=  0  Passed
Id=  4  Status=50  {Advisory    Online }  Value=100  Threshold= 20  Passed
Id=  5  Status=51  {Prefailure  Online }  Value=100  Threshold= 36  Passed
Id=  7  Status=15  {Prefailure  Online }  Value= 85  Threshold= 30  Passed
Id=  9  Status=50  {Advisory    Online }  Value= 93  Threshold=  0  Passed
Id= 10  Status=19  {Prefailure  Online }  Value=100  Threshold= 97  Passed
Id= 12  Status=50  {Advisory    Online }  Value=100  Threshold= 20  Passed
Id=187  Status=50  {Advisory    Online }  Value=  1  Threshold=  0  Passed
Id=189  Status=58  {Advisory    Online }  Value=100  Threshold=  0  Passed
Id=190  Status=34  {Advisory    Online }  Value= 66  Threshold= 45  Passed
Id=194  Status=34  {Advisory    Online }  Value= 34  Threshold=  0  Passed
Id=195  Status=26  {Advisory    Online }  Value= 69  Threshold=  0  Passed
Id=197  Status=18  {Advisory    Online }  Value=100  Threshold=  0  Passed
Id=198  Status=16  {Advisory    OffLine}  Value=100  Threshold=  0  Passed
Id=199  Status=62  {Advisory    Online }  Value=200  Threshold=  0  Passed
Id=200  Status= 0  {Advisory    OffLine}  Value=100  Threshold=  0  Passed
Id=202  Status=50  {Advisory    Online }  Value=100  Threshold=  0  Passed
OffLineStatus=130 {Completed}, AutoOffLine=Yes, OffLineTimeout=7 minutes
OffLineCapability=91 {Immediate Auto SuspendOnCmd}
SmartRevision=10, CheckSum=177, SmartCapability=3 {SaveOnStandBy AutoSave}

fraga@abusar ~$ sudo ide-smart /dev/sdb
Id=  1  Status=15  {Prefailure  Online }  Value=104  Threshold=  6  Passed
Id=  3  Status= 3  {Prefailure  Online }  Value= 99  Threshold=  0  Passed
Id=  4  Status=50  {Advisory    Online }  Value=100  Threshold= 20  Passed
Id=  5  Status=51  {Prefailure  Online }  Value=100  Threshold= 36  Passed
Id=  7  Status=15  {Prefailure  Online }  Value= 84  Threshold= 30  Passed
Id=  9  Status=50  {Advisory    Online }  Value= 94  Threshold=  0  Passed
Id= 10  Status=19  {Prefailure  Online }  Value=100  Threshold= 97  Passed
Id= 12  Status=50  {Advisory    Online }  Value=100  Threshold= 20  Passed
Id=187  Status=50  {Advisory    Online }  Value=100  Threshold=  0  Passed
Id=189  Status=58  {Advisory    Online }  Value=100  Threshold=  0  Passed
Id=190  Status=34  {Advisory    Online }  Value= 66  Threshold= 45  Passed
Id=194  Status=34  {Advisory    Online }  Value= 34  Threshold=  0  Passed
Id=195  Status=26  {Advisory    Online }  Value= 66  Threshold=  0  Passed
Id=197  Status=18  {Advisory    Online }  Value=100  Threshold=  0  Passed
Id=198  Status=16  {Advisory    OffLine}  Value=100  Threshold=  0  Passed
Id=199  Status=62  {Advisory    Online }  Value=200  Threshold=  0  Passed
Id=200  Status= 0  {Advisory    OffLine}  Value=100  Threshold=  0  Passed
Id=202  Status=50  {Advisory    Online }  Value=100  Threshold=  0  Passed
OffLineStatus=130 {Completed}, AutoOffLine=Yes, OffLineTimeout=7 minutes
OffLineCapability=91 {Immediate Auto SuspendOnCmd}
SmartRevision=10, CheckSum=193, SmartCapability=3 {SaveOnStandBy AutoSave}

	Thank you very much.

-- 
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net
Dave Matthews Band - "When the World Ends" (Everyday)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-19 18:23   ` Dâniel Fraga
@ 2007-07-20  2:14     ` Neil Brown
  2007-07-20  2:32       ` Dâniel Fraga
  0 siblings, 1 reply; 15+ messages in thread
From: Neil Brown @ 2007-07-20  2:14 UTC (permalink / raw)
  To: Dâniel Fraga; +Cc: linux-raid

On Thursday July 19, fragabr@gmail.com wrote:
> On Thu, 19 Jul 2007 13:54:50 +1000
> Neil Brown <neilb@suse.de> wrote:
> 
> > The resierfs filesystem is trying to access beyond the end of the
> > raid1 array.  Maybe some indexing information in the array is
> > corrupted.
> > Did you recreate the array (mdadm --create) after changing to the new
> > drivers?  If so, could you have accidentally made it a little smaller?
> > 
> > Possibly try running fsck and see if it finds anything to fix.
> 
> 	Hi Neil, I recreated the array after changing to libata. I
> checked the whole filesystem with reiserfsck --rebuild-tree, then
> started it again and the problem happens suddenly.
> 
> 	And regarding the size of array, I just added the whole
> partition to the array:
> 
> Filesystem           1K-blocks      Used Available Use% Mounted on
> /dev/md1              77639736  30127524  47512212  39% /
> 
>      Array Size : 77642048 (74.05 GiB 79.51 GB)
>   Used Dev Size : 77642048 (74.05 GiB 79.51 GB)
> 
> 	Can I compare both values (77639736 with 77642048)? If so,
> there is a difference, if not, I don't know.

Filesystems always reserve some space for internal use, so the size
reported by df is always smaller than the total number of block on the
devices.

What does
      od -D -j 65536 -N 4 /dev/md1
show.  This is the size the reiserfs thinks it is using.  Multiply by
4 and you should get 77642048 or maybe a little less.  If you get
more, then reiserfs think the device is bigger than it is.  If don't
then I have no idea what the problem is.

NeilBrown

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-20  2:14     ` Neil Brown
@ 2007-07-20  2:32       ` Dâniel Fraga
  2007-07-20  2:59         ` Neil Brown
  0 siblings, 1 reply; 15+ messages in thread
From: Dâniel Fraga @ 2007-07-20  2:32 UTC (permalink / raw)
  To: linux-raid

On Fri, 20 Jul 2007 12:14:31 +1000
Neil Brown <neilb@suse.de> wrote:

> What does
>       od -D -j 65536 -N 4 /dev/md1
> show.  This is the size the reiserfs thinks it is using.  Multiply by
> 4 and you should get 77642048 or maybe a little less.  If you get
> more, then reiserfs think the device is bigger than it is.  If don't
> then I have no idea what the problem is.

	The output is:

0200000   19410528
0200004

	so...

19410528 x 4 = 77642112

	The difference (77642048 - 77642112) is 64.

	Does it help? What could I do now? Thanks!

-- 
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net
Exodus - "I Am Abomination" (Shovel Headed Kill Machine - 2005)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-20  0:25   ` Dâniel Fraga
@ 2007-07-20  2:38     ` Dâniel Fraga
  2007-07-20 15:37     ` Alan Cox
  1 sibling, 0 replies; 15+ messages in thread
From: Dâniel Fraga @ 2007-07-20  2:38 UTC (permalink / raw)
  To: linux-ide

On Thu, 19 Jul 2007 21:25:24 -0300
Dâniel Fraga <fragabr@gmail.com> wrote:

> 	Thank you very much.

	Neil Brown from raid mailing-list asked me to:

fraga@abusar ~$ sudo od -D -j 65536 -N 4 /dev/md1
Password:
0200000   19410528
0200004

	Then multiply 19410528 by 4 which is equal to 77642112.

	As 77642112 is higher than 77642048 (from mdadm -D /dev/md1:
array size), reiserfs thinks the device is bigger than what it really
is. Does it help? Thanks.

	Ps: the difference is small: 77642112 - 77642048 = 64

-- 
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net
Exodus - "I Am Abomination" (Shovel Headed Kill Machine - 2005)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-20  2:32       ` Dâniel Fraga
@ 2007-07-20  2:59         ` Neil Brown
  2007-07-21 21:18           ` Dâniel Fraga
  0 siblings, 1 reply; 15+ messages in thread
From: Neil Brown @ 2007-07-20  2:59 UTC (permalink / raw)
  To: Dâniel Fraga; +Cc: linux-raid

On Thursday July 19, fragabr@gmail.com wrote:
> On Fri, 20 Jul 2007 12:14:31 +1000
> Neil Brown <neilb@suse.de> wrote:
> 
> > What does
> >       od -D -j 65536 -N 4 /dev/md1
> > show.  This is the size the reiserfs thinks it is using.  Multiply by
> > 4 and you should get 77642048 or maybe a little less.  If you get
> > more, then reiserfs think the device is bigger than it is.  If don't
> > then I have no idea what the problem is.
> 
> 	The output is:
> 
> 0200000   19410528
> 0200004
> 
> 	so...
> 
> 19410528 x 4 = 77642112
> 
> 	The difference (77642048 - 77642112) is 64.

So reiserfs thinks the devices is 64K larger than it really is. I
wonder how that happened.

> 
> 	Does it help? What could I do now? Thanks!

It helps that we know why you get these errors.  It looks like you
should be able to fix it with resize_reiserfs.
Looking at the man page I have, you could
   umount /whatever
   resize_reiserfs -s -64K /dev/md1
   mount /whatever

However I recommend reading the man page yourself, as this isn't the
sort of thing you want to get wrong.

NeilBrown

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-20  0:25   ` Dâniel Fraga
  2007-07-20  2:38     ` Dâniel Fraga
@ 2007-07-20 15:37     ` Alan Cox
  2007-07-20 21:11       ` Dâniel Fraga
  1 sibling, 1 reply; 15+ messages in thread
From: Alan Cox @ 2007-07-20 15:37 UTC (permalink / raw)
  To: Dâniel Fraga; +Cc: linux-ide

On Thu, 19 Jul 2007 21:25:24 -0300
Dâniel Fraga <fragabr@gmail.com> wrote:

> On Fri, 20 Jul 2007 00:17:14 +0100
> Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:
> 
> > Are their host protected areas on the two disks ?
> 
> 	I don't know, but hdparm returns this:

Ok try booting with

	libata.ignore_hpa=1

Alan

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-20 15:37     ` Alan Cox
@ 2007-07-20 21:11       ` Dâniel Fraga
  2007-07-21  0:13         ` Alan Cox
  0 siblings, 1 reply; 15+ messages in thread
From: Dâniel Fraga @ 2007-07-20 21:11 UTC (permalink / raw)
  To: linux-ide

On Fri, 20 Jul 2007 16:37:09 +0100
Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:

> Ok try booting with
> 
> 	libata.ignore_hpa=1

	I used that option:

fraga@abusar ~$ dmesg|grep hpa
Kernel command line: auto BOOT_IMAGE=linux rw root=902 panic=5 libata.ignore_hpa=1

	and tried to makereiserfs again, but got the same results:

Guessing about desired format.. Kernel 2.6.22 is running.
Format 3.6 with standard journal
Count of blocks on the device: 19410528
Number of blocks consumed by mkreiserfs formatting process: 8804
Blocksize: 4096
Hash function used to sort names: "r5"
Journal Size 8193 blocks (first block 18)
Journal Max transaction length 1024
inode generation number: 0

	19410528 x 4 = 77642112

	which is higher than 

Used Dev Size : 77642048 (74.05 GiB 79.51 GB)

	The "solution" was to reduce 64K from the reiser partition, as
suggested by Neil Brown. This way the raid stopped to complain.

	But I really don't know why mkreiserfs is creating a filesystem
with 64k more than allowed by the device... maybe a bug in mkreiserfs?

	The strange is that it didn't happen with the OLD IDE
drivers... could it be a pata_via bug?

	To determine if it is mkreiserfs' fault I used mke2fs just
to see if it will create the same number of blocks as reiserfs:

fraga@abusar ~$ sudo mke2fs /dev/sda2
mke2fs 1.19, 13-Jul-2000 for EXT2 FS 0.5b, 95/08/09
Filesystem label=
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
9715712 inodes, 19410536 blocks
970526 blocks (5.00%) reserved for the super user
First data block=0
593 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
Superblock backups stored on blocks: 
        32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208, 
        4096000, 7962624, 11239424

Writing inode tables: done                            
Writing superblocks and filesystem accounting information: done

	***
	
	As you can see it created 19410536 blocks (19410536 x 4 =
77642144, exactly as mkreiserfs did).

	So I suppose it's a bug in some other place.

	Or mdadm is determining the incorrect size of the device,
64K less than the real size? Just for your convenience, mdadm returns:

     Array Size : 77642048 (74.05 GiB 79.51 GB)
  Used Dev Size : 77642048 (74.05 GiB 79.51 GB)

	and mkreiserfs, mke2fs etc return 77642144. In other words, 64K
more. Which one is correct? mkreiserfs/mke2fs or mdadm?

	According Neil Brown, mdadm is correct and we don't know why
mkreiserfs is creating a filesystem 64k larger than the device... so it
could be a pata_via bug... is there any other test I can do to
get rid of the possibility of a pata_via bug? If you need i can apply
patches in the kernel or activate some other option.

	And it seems that mdadm's method to determine the size of the
partition is different from mkreiserfs/mke2fs etc, right?

	Thank you!

-- 
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net
Marilyn Manson - "Cruci-Fiction in Space" (Holy Wood (In the Shadow of
the Valley of Death) - 2000)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-20 21:11       ` Dâniel Fraga
@ 2007-07-21  0:13         ` Alan Cox
  0 siblings, 0 replies; 15+ messages in thread
From: Alan Cox @ 2007-07-21  0:13 UTC (permalink / raw)
  To: Dâniel Fraga; +Cc: linux-ide

> 	But I really don't know why mkreiserfs is creating a filesystem
> with 64k more than allowed by the device... maybe a bug in mkreiserfs?
> 
> 	The strange is that it didn't happen with the OLD IDE
> drivers... could it be a pata_via bug?

pata_via doesn't deal with disk sizes. That is handled by the core libata
code (and on the whole by the scsi midlayer)

Once you've created a raid volume the sizing is however handled by the
raid code not by the underlying code at all so it suggests a bug (or some
kind of shared misbehaviour) in the various mk* tools. However I've no
idea what that should suddenly show up now, and not with every scsi user.

> 	And it seems that mdadm's method to determine the size of the
> partition is different from mkreiserfs/mke2fs etc, right?

You would need to ask someone familiar with those applications or take a
look at the source.

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-20  2:59         ` Neil Brown
@ 2007-07-21 21:18           ` Dâniel Fraga
  0 siblings, 0 replies; 15+ messages in thread
From: Dâniel Fraga @ 2007-07-21 21:18 UTC (permalink / raw)
  To: linux-raid

On Fri, 20 Jul 2007 12:59:41 +1000
Neil Brown <neilb@suse.de> wrote:

> So reiserfs thinks the devices is 64K larger than it really is. I
> wonder how that happened.

>    resize_reiserfs -s -64K /dev/md1

	Neil, I discovered how the "64k larger" issue happened...

	It was my fault.. I created the Reiser filesystem *before* the
raid device. So when I create the raid device, it warns about a
existing reiserfs filesystem and if I want to continue. This way, the
underlying filesystem will be always 64k large than the raid device.

	If, instead, I use the correct method of creating the raid
device *before*, everything is ok, because then I can "mkreiserfs" the
raid device and the filesystem will have the correct size the raid
device expects.

	Sorry for my mistake and thanks again!

-- 
Linux 2.6.22: Holy Dancing Manatees, Batman!
http://www.lastfm.pt/user/danielfraga
http://u-br.net
Marilyn Manson - "Dried Up, Tied and Dead to the World" (Antichrist
Superstar - 1996)


^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: pata_via with software raid1: "attempt to access beyond end of device"
  2007-07-19  2:24 pata_via with software raid1: "attempt to access beyond end of device" Dâniel Fraga
  2007-07-19  3:54 ` Neil Brown
@ 2007-07-30 19:01 ` Cry Regarder
  1 sibling, 0 replies; 15+ messages in thread
From: Cry Regarder @ 2007-07-30 19:01 UTC (permalink / raw)
  To: linux-raid

Dâniel Fraga <fragabr <at> gmail.com> writes:

> 	I have 2 PATA HDs and they always worked perfectly with
> software (kernel) raid1 using the old IDE kernel drivers. Now I use
> the new libata drivers (VIA), and it keep giving those erros messages:
> 
> attempt to access beyond end of device
> md1: rw=0, want=155284112, limit=155284096

Isn't this the standard problem that some hard drives have reserved
areas that the operating system isn't supposed to use?  The old IDE
drivers didn't honor the drive's request not to use.  libata, however,
now behaves correctly and honors it.

libata.ignore_hpa=1

https://www.redhat.com/archives/fedora-devel-list/2007-May/msg01695.html

and

http://fedoraproject.org/wiki/Bugs/F7Common


Now if someone can explain to me if it is safe to write the partition table
saying I only have one partition when I built a raid-5 on /dev/sd? instead of
/dev/sd?1

Thanks!

Cry

-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2007-07-30 19:01 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-19  2:24 pata_via with software raid1: "attempt to access beyond end of device" Dâniel Fraga
2007-07-19  3:54 ` Neil Brown
2007-07-19 18:23   ` Dâniel Fraga
2007-07-20  2:14     ` Neil Brown
2007-07-20  2:32       ` Dâniel Fraga
2007-07-20  2:59         ` Neil Brown
2007-07-21 21:18           ` Dâniel Fraga
2007-07-30 19:01 ` Cry Regarder
  -- strict thread matches above, loose matches on Subject: below --
2007-07-19  2:23 Dâniel Fraga
2007-07-19 23:17 ` Alan Cox
2007-07-20  0:25   ` Dâniel Fraga
2007-07-20  2:38     ` Dâniel Fraga
2007-07-20 15:37     ` Alan Cox
2007-07-20 21:11       ` Dâniel Fraga
2007-07-21  0:13         ` Alan Cox

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.