qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Alexander (Sasha) Sirotkin" <sasha.sirotkin@gmail.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] "A disk read error occurred"
Date: Wed, 2 Jul 2008 22:47:30 +0300	[thread overview]
Message-ID: <478c82f00807021247q282f3169h14f732e46c04a6e9@mail.gmail.com> (raw)
In-Reply-To: <20080702143424.GC2993@shareable.org>

On Wed, Jul 2, 2008 at 5:34 PM, Jamie Lokier <jamie@shareable.org> wrote:
> Alexander (Sasha) Sirotkin wrote:
>> On Tue, Jul 1, 2008 at 2:05 AM, Jamie Lokier <jamie@shareable.org> wrote:
>> > Avi Kivity wrote:
>> >> Alexander (Sasha) Sirotkin wrote:
>> >> >For some reason when I try to boot qemu with -hda /dev/sda (or -hda
>> >> >/dev/hda), i.e. to use the whole disk, it fails with the above error
>> >> >"A disk read error occurred". This happens only on IBM/Lenovo laptops
>> >> >(tried a few models), while it works just fine on any desktop I can
>> >> >get my hands on. Probably has something to do with bios...
>> >> >
>> >> >
>> >>
>> >> Can you add some printfs displaying the sector numbers being read?  Some
>> >> disks have trouble accessing the last sector.
>> There are no printfs, no sector numbers, nothing. Just the above error.
>> >>
>> >> Also, an strace can help show the problem.
>> The whole strace is too big, attaching last 1000 lines
>> >
>> > Also, sometimes when booting the BIOS can print a disk read error
>> > message, and an appropriate -hdachs will fix it.  I found that out
>> > when rebooting Windows 2000 after installing it from CD (both in
>> > QEMU), on a virtual disk 1GB in size.
>> >
>>
>> I must say that I don't understand what chs values I should give to
>> qemu. hdparm  shows 9729/255/63, but fdisk insists on 10337,240,63.
>> Both versions do not work with qemu, it says "invalid physical CHS
>> format"
>> BTW, hdparm -i shows yet another version - RawCHS=16383/16/63
>
> Try -hdachs 1023,16,63,lba.
> If that doesn't work, try it without lba.
> If those don't work, try 255 for the middle number, with/without lba.
>

According to the DiskEXplorer for NTFS the correct heads number is
240, however qemu does not allow to set it. Any idea why ? Can I just
remove this limitation in the source code ?

> -- Jamie
>
>
>

      parent reply	other threads:[~2008-07-02 19:47 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-28 19:42 [Qemu-devel] "A disk read error occurred" Alexander (Sasha) Sirotkin
2008-06-29  3:48 ` Avi Kivity
2008-06-30 23:05   ` Jamie Lokier
2008-07-01  9:03     ` Mark Cave-Ayland
2008-07-01  9:08       ` Jamie Lokier
2008-07-01  9:31         ` Mark Cave-Ayland
2008-07-01 21:37     ` Alexander (Sasha) Sirotkin
2008-07-02 14:34       ` Jamie Lokier
2008-07-02 19:39         ` Alexander (Sasha) Sirotkin
2008-07-02 19:47         ` Alexander (Sasha) Sirotkin [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=478c82f00807021247q282f3169h14f732e46c04a6e9@mail.gmail.com \
    --to=sasha.sirotkin@gmail.com \
    --cc=qemu-devel@nongnu.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;
as well as URLs for NNTP newsgroup(s).