mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andreas Dilger <adilger@turbolabs.com>
To: M G Berberich <berberic@fmi.uni-passau.de>
Cc: linux-kernel@vger.kernel.org, tytso@thunk.org
Subject: Re: 2.4.16: hda9: attempt to access beyond end of device
Date: Fri, 30 Nov 2001 15:22:07 -0700	[thread overview]
Message-ID: <20011130152207.R15936@lynx.no> (raw)
In-Reply-To: <20011129225814.A464@fmi.uni-passau.de> <20011130210734.A489@fmi.uni-passau.de>
In-Reply-To: <20011130210734.A489@fmi.uni-passau.de>; from berberic@fmi.uni-passau.de on Fri, Nov 30, 2001 at 09:07:34PM +0100

On Nov 30, 2001  21:07 +0100, M G Berberich wrote:
> Am Thursday, den 29. November 2001 22:58:14 schrieb berberic:
> > Partition boundary problem in 2.4.16 ?!
> > 
> > I just tried to make a mke2fs on my /dev/hda9 and mke2fs with kernel
> > 2.4.16 and it failed with a partial write. /var/log/messages says:
> > 
> >   kernel: 03:09: rw=0, want=289140, limit=289138
> >   kernel: attempt to access beyond end of device
> > 
> > It works fine with 2.4.13 and it works with 2.4.16 if blocksize is
> > set to 4k (fails with 1k blocks).
> 
> Now it failed with kernel 2.4.13 and mke2fs 1.25 on another partition,
> but works with kernel 2.4.13 and mke2fs 1.18. 1k-blocks again. 

To avoid issues with mke2fs, try "dd if=/dev/hda9 of=/dev/null bs=X"
where X=512,1k,2k,4k under both kernels and see if it still gives
errors.  Also, mke2fs outputs the device size that it got via the
BLKGETSIZE ioctl, so that may be informative also.  If you do an
strace of mke2fs, you should see that it is calling BLKGETSIZE (about
70 lines in, on my system).  If that ioctl is failing, then it may be
a bug elsewhere in the mke2fs code (which is rarely used), although
it is unlikely.

The likely reason it is failing with 1kB blocks and not 4kB blocks is
that mke2fs will ignore up to 3kB at the end of the device if it is
not a full multiple of the block size (i.e. 4kB).

Cheers, Andreas
--
Andreas Dilger
http://sourceforge.net/projects/ext2resize/
http://www-mddsp.enel.ucalgary.ca/People/adilger/


      reply	other threads:[~2001-11-30 22:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-11-29 21:58 M G Berberich
2001-11-29 22:12 ` Kristofer T. Karas
2001-11-30  8:37   ` janne
2001-11-30 20:07 ` M G Berberich
2001-11-30 22:22   ` Andreas Dilger [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20011130152207.R15936@lynx.no \
    --to=adilger@turbolabs.com \
    --cc=berberic@fmi.uni-passau.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tytso@thunk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®