From mboxrd@z Thu Jan 1 00:00:00 1970 From: Anthony Liguori Subject: Re: Problems with GRUB and boot=on flag Date: Thu, 22 May 2008 19:46:49 -0500 Message-ID: <483613F9.8060104@codemonkey.ws> References: <200805221742.38609.alberto@byu.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: kvm@vger.kernel.org To: =?ISO-8859-1?Q?Alberto_Trevi=F1o?= Return-path: Received: from yw-out-2324.google.com ([74.125.46.30]:6403 "EHLO yw-out-2324.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758186AbYEWArA (ORCPT ); Thu, 22 May 2008 20:47:00 -0400 Received: by yw-out-2324.google.com with SMTP id 9so231539ywe.1 for ; Thu, 22 May 2008 17:46:59 -0700 (PDT) In-Reply-To: <200805221742.38609.alberto@byu.edu> Sender: kvm-owner@vger.kernel.org List-ID: Alberto Trevi=F1o wrote: > I am having a really weird problem. I reported about it earlier (see= =20 > http://article.gmane.org/gmane.comp.emulators.kvm.devel/15884) thinki= ng=20 > the problem was with SCSI disks, but that's not the case. Let me try= =20 > to explain. > > I have a drive that has GRUB and Linux. If I run the following comma= nd,=20 > it boots normally, even though the boot flag has been set to off: > > qemu-system-x86_64 -m 256 > -drive file=3Dhd0.qcow2,if=3Dide,bus=3D0,index=3D0,media=3Ddisk,bo= ot=3Doff > =20 How did you install grub on this drive? Is this a distro image or did=20 you install grub yourself? Regards, Anthony Liguori > If I run the following, qemu crashes when GRUB loads: > > qemu-system-x86_64 -m 256 > -drive file=3Dhd0.qcow2,if=3Dide,bus=3D0,index=3D0,media=3Ddisk,bo= ot=3Don > > Qemu reports the following when it crashes: > > exception 13 (33) > rax 0000000000000000 rbx 0000000000000800 rcx 0000000000000000 rdx=20 > 00000000000000e0 > rsi 00000000ffff7d98 rdi 000000000008f788 rsp 0000000000002018 rbp=20 > 0000000000000001 > r8 0000000000000000 r9 0000000000000000 r10 0000000000000000 r11=20 > 0000000000000000 > r12 0000000000000000 r13 0000000000000000 r14 0000000000000000 r15=20 > 0000000000000000 > rip 0000000000000003 rflags 00033202 > cs 0000 (00000000/0000ffff p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0) > ds 0000 (00000000/0000ffff p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0) > es 0800 (00008000/0000ffff p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0) > ss 0000 (00000000/0000ffff p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0) > fs 0000 (00000000/0000ffff p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0) > gs 0000 (00000000/0000ffff p 1 dpl 3 db 0 s 1 type 3 l 0 g 0 avl 0) > tr 0000 (fffbd000/00002088 p 1 dpl 0 db 0 s 0 type b l 0 g 0 avl 0) > ldt 0000 (00000000/0000ffff p 1 dpl 0 db 0 s 0 type 2 l 0 g 0 avl 0) > gdt fb1f2/30 > idt 0/3ff > cr0 10 cr2 0 cr3 0 cr4 0 cr8 0 efer 0 > code: 53 ff 00 --> f0 53 ff 00 f0 53 ff 00 f0 53 ff 00 f0 53 ff 00 f0= 53=20 > ff 00 f0 53 ff 00 f0 53 ff 00 f0 a5 fe 00 f0 87 e9 00 f0 53 ff 00 f0 = 53=20 > ff 00 f0 53 ff > Aborted > > If I change the interface to SCSI and set the boot flag to off, Qemu=20 > can't find a valid boot drive and does not boot. If I change the=20 > interface to SCSI and set the boot flag to on, I get the same crash. > > According to Anthony Liguori's original extboot post, "boot=3Don" tur= ns on=20 > the extboot code, so my problem is the combination of extboot and GRU= B. =20 > A response on my original post suggested this might be a real mode=20 > issue. However, it seems more of an extboot problem with some of the= =20 > calls from GRUB. > > What's the status of the extboot in C project? Perhaps I could try t= hat=20 > to see if it fixes the problem. Does anyone have any other=20 > suggestions? > > =20