[Lguest] Loading Lguest guest - Unhandled trap 256 at x100000
Naman Muley
naman.g.muley at gmail.com
Sat Apr 27 16:37:26 EST 2013
Thanks Eviatar, I appreciate all your help. Did you see the config file? Do
you see any problems with that?
My next step would be to try with another higher kernel. I am in a team.
One of my other team mates got this problem solved with 3.6.7 kernel. I
have not the faintest idea how and why.
I've attached the shortened disassembly file for anyone who stumbles upon
this thread.
Naman
On Sat, Apr 27, 2013 at 1:28 AM, Eviatar Khen <eviatarkhen at gmail.com> wrote:
> Well after examining the code I see that Lguest sets a default trap number
> to 256 before switching to the guest.
> Hence it seems that your first switch fails. I'm not sure how to debug
> this.
> Perhaps if you'll find a way to output the registers status during the
> switch.
> Or, you can wait for Rusty to save the day again...
>
>
> On Sat, Apr 27, 2013 at 4:59 AM, Naman Muley <naman.g.muley at gmail.com>wrote:
>
>> Hello again,
>>
>> Thanks Eviatar. I have attached the the System.map and the config file
>> with this email. The disassembly.txt is pretty huge, 818 Mb, hence not on
>> this email. I'll upload it on dropbox and share the link for future use of
>> anyone.
>>
>> I tried to have the config exactly as Rusty mentions in the lguest.txt.
>> But the default values of CONFIG_PHYSICAL_ALIGN and CONFIG_PHYSICAL_START
>> were 0x1000000 and not 0x100000 i think. I changed them to 0x100000 as
>> Rusty mentions. Could you explain what both these values do? I know that
>> the new guest starts from here, but could you elaborate on that ?
>>
>> Thanks for all your help. I appreciate all the help
>>
>> Naman
>>
>>
>> On Fri, Apr 26, 2013 at 5:18 PM, Eviatar Khen <eviatarkhen at gmail.com>wrote:
>>
>>> You are wrong, the interrupt was not delivered to the guest because it
>>> in invalid. An unhanded interrupt makes the host crash the guest.
>>> It is hard to understand something from the screenshot. dSend to the
>>> mailing list the config file and the system.map.
>>>
>>>
>>> On Sat, Apr 27, 2013 at 1:04 AM, Naman Muley <naman.g.muley at gmail.com>wrote:
>>>
>>>> Hey Eviatar,
>>>>
>>>> Thank you so much. I understand what i was doing.
>>>> I've attached a screenshot of the disassembly. But i did not understand
>>>> "it is very interesting to understand who generated it". how can you figure
>>>> that out from the binary disassembly?
>>>>
>>>> Also, i did try read up on the unhandled trap, i found this:
>>>> http://wiki.debian.org/Lguest
>>>> and I understand why 256 is kind of odd because that interrupt number
>>>> is not covered by the host and so we send it as a valid number to the
>>>> guest. But the guest doesnt know how to handle this one.
>>>> But i have no idea what is causing this and how to remove this.
>>>>
>>>> Any idea?
>>>>
>>>> Naman
>>>>
>>>>
>>>> On Fri, Apr 26, 2013 at 4:33 PM, Eviatar Khen <eviatarkhen at gmail.com>wrote:
>>>>
>>>>> Hi Naman,
>>>>>
>>>>> I think what Ron meant was to disassembly of the kernel's image
>>>>> (vmlinux), not the Lguest binary (which is user space and does not generate
>>>>> directly interrupts).
>>>>> The guest crashes because the host got an invalid interrupt number,
>>>>> and it is very interesting to understand who generated it.
>>>>>
>>>>> Good luck,
>>>>>
>>>>> Eviatar
>>>>>
>>>>>
>>>>> On 04/26/2013 08:34 PM, Naman Muley wrote:
>>>>>
>>>>> Hey Ron,
>>>>>
>>>>> Thanks for reaching out. I did the following( i am not sure if
>>>>> that's what you wanted me to do) :
>>>>>
>>>>> objdump -D -b binary -m i386 Documentation/virtual/lguest/lguest >
>>>>> /home/ngm7/disassembly.txt
>>>>> Following is the screenshot: Does that make sense ?
>>>>>
>>>>> I had to take a screenshot because the disassembly.txt is inside the
>>>>> virtual machine. I'm working on ways to get that file out of the virtual
>>>>> machine.
>>>>>
>>>>> NOTE: the last line in the file was 6a1d. In the meanwhile, if you
>>>>> want to look at any specific line, let me know.
>>>>> I apologize for the raw kind of feedback.
>>>>>
>>>>> Naman
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> On Fri, Apr 26, 2013 at 11:45 AM, ron minnich <rminnich at gmail.com>wrote:
>>>>>
>>>>>> you might want to do a quick disassembly of the binary to see what's
>>>>>> at 0x100000. The 256 is (to me) kind of odd. So what's the start of
>>>>>> that image look like? Sorry, I'm rusty on lguest (i.e. I'm not Rusty)
>>>>>> so I'm not going to be as useful. But I would be curious to see the
>>>>>> disassembly.
>>>>>>
>>>>>> ron
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> Lguest mailing listLguest at lists.ozlabs.orghttps://lists.ozlabs.org/listinfo/lguest
>>>>>
>>>>>
>>>>>
>>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ozlabs.org/pipermail/lguest/attachments/20130427/0750b8dd/attachment-0001.html>
-------------- next part --------------
ffe3d: 39 5d 0c cmp %ebx,0xc(%ebp)
ffe40: 89 34 82 mov %esi,(%edx,%eax,4)
ffe43: 7f b3 jg 0xffdf8
ffe45: 8b 55 f0 mov -0x10(%ebp),%edx
ffe48: 8b 45 e0 mov -0x20(%ebp),%eax
ffe4b: 03 42 10 add 0x10(%edx),%eax
ffe4e: 8b 15 a4 06 91 c0 mov 0xc09106a4,%edx
ffe54: 03 04 3a add (%edx,%edi,1),%eax
ffe57: 8b 55 e4 mov -0x1c(%ebp),%edx
ffe5a: e8 61 e9 00 00 call 0x10e7c0
ffe5f: e9 64 ff ff ff jmp 0xffdc8
ffe64: 8b 45 08 mov 0x8(%ebp),%eax
ffe67: 3b 45 0c cmp 0xc(%ebp),%eax
ffe6a: 7d 16 jge 0xffe82
ffe6c: 8b 55 dc mov -0x24(%ebp),%edx
ffe6f: 8b 4d 0c mov 0xc(%ebp),%ecx
ffe72: 8d b6 00 00 00 00 lea 0x0(%esi),%esi
ffe78: 0f b3 02 btr %eax,(%edx)
ffe7b: 83 c0 01 add $0x1,%eax
ffe7e: 39 c1 cmp %eax,%ecx
ffe80: 7f f6 jg 0xffe78
ffe82: 83 c4 18 add $0x18,%esp
ffe85: 5b pop %ebx
ffe86: 5e pop %esi
ffe87: 5f pop %edi
ffe88: 5d pop %ebp
ffe89: c3 ret
ffe8a: ba 11 00 00 00 mov $0x11,%edx
ffe8f: b8 bb 16 80 c0 mov $0xc08016bb,%eax
ffe94: e8 17 ad f4 ff call 0x4abb0
ffe99: e9 67 ff ff ff jmp 0xffe05
ffe9e: ba b4 00 00 00 mov $0xb4,%edx
ffea3: b8 bb 16 80 c0 mov $0xc08016bb,%eax
ffea8: e8 03 ad f4 ff call 0x4abb0
ffead: e9 74 ff ff ff jmp 0xffe26
ffeb2: 8d b4 26 00 00 00 00 lea 0x0(%esi,%eiz,1),%esi
ffeb9: 8d bc 27 00 00 00 00 lea 0x0(%edi,%eiz,1),%edi
ffec0: 55 push %ebp
ffec1: 89 e5 mov %esp,%ebp
ffec3: 83 ec 18 sub $0x18,%esp
ffec6: 89 5d f4 mov %ebx,-0xc(%ebp)
ffec9: 89 75 f8 mov %esi,-0x8(%ebp)
ffecc: 89 7d fc mov %edi,-0x4(%ebp)
ffecf: e8 74 26 47 00 call 0x572548
ffed4: 8b 35 8c 13 a8 c0 mov 0xc0a8138c,%esi
ffeda: 89 c7 mov %eax,%edi
ffedc: a1 d4 06 91 c0 mov 0xc09106d4,%eax
ffee1: 89 55 f0 mov %edx,-0x10(%ebp)
ffee4: 89 ca mov %ecx,%edx
ffee6: 89 45 ec mov %eax,-0x14(%ebp)
ffee9: a1 d0 06 91 c0 mov 0xc09106d0,%eax
ffeee: 8d 48 1f lea 0x1f(%eax),%ecx
ffef1: c1 e9 05 shr $0x5,%ecx
ffef4: c1 e1 02 shl $0x2,%ecx
ffef7: 85 f6 test %esi,%esi
ffef9: 74 2d je 0xfff28
ffefb: 8b 1d 90 13 a8 c0 mov 0xc0a81390,%ebx
fff01: 85 db test %ebx,%ebx
fff03: 74 23 je 0xfff28
fff05: 8d 57 28 lea 0x28(%edi),%edx
fff08: 89 d8 mov %ebx,%eax
fff0a: e8 21 73 1b 00 call 0x2b7230
fff0f: 8b 45 f0 mov -0x10(%ebp),%eax
fff12: 89 18 mov %ebx,(%eax)
fff14: 89 f0 mov %esi,%eax
fff16: 8b 5d f4 mov -0xc(%ebp),%ebx
fff19: 8b 75 f8 mov -0x8(%ebp),%esi
fff1c: 8b 7d fc mov -0x4(%ebp),%edi
fff1f: 89 ec mov %ebp,%esp
fff21: 5d pop %ebp
fff22: c3 ret
fff23: 90 nop
fff24: 8d 74 26 00 lea 0x0(%esi,%eiz,1),%esi
fff28: 84 d2 test %dl,%dl
fff2a: 74 14 je 0xfff40
fff2c: 85 f6 test %esi,%esi
fff2e: 74 2f je 0xfff5f
fff30: 8b 1d 90 13 a8 c0 mov 0xc0a81390,%ebx
fff36: 85 db test %ebx,%ebx
fff38: 74 3e je 0xfff78
fff3a: 8b 35 8c 13 a8 c0 mov 0xc0a8138c,%esi
fff40: 85 f6 test %esi,%esi
fff42: 74 d0 je 0xfff14
fff44: 8b 1d 90 13 a8 c0 mov 0xc0a81390,%ebx
fff4a: 85 db test %ebx,%ebx
fff4c: 74 38 je 0xfff86
fff4e: 8b 0d d0 06 91 c0 mov 0xc09106d0,%ecx
fff54: 83 c1 1f add $0x1f,%ecx
fff57: c1 e9 05 shr $0x5,%ecx
fff5a: c1 e1 02 shl $0x2,%ecx
fff5d: eb a6 jmp 0xfff05
fff5f: 0f af 45 ec imul -0x14(%ebp),%eax
fff63: 89 4d e8 mov %ecx,-0x18(%ebp)
fff66: c1 e0 02 shl $0x2,%eax
fff69: e8 e2 f4 ff ff call 0xff450
fff6e: 8b 4d e8 mov -0x18(%ebp),%ecx
fff71: a3 8c 13 a8 c0 mov %eax,0xc0a8138c
fff76: eb b8 jmp 0xfff30
fff78: 89 c8 mov %ecx,%eax
fff7a: e8 d1 f4 ff ff call 0xff450
fff7f: a3 90 13 a8 c0 mov %eax,0xc0a81390
fff84: eb b4 jmp 0xfff3a
fff86: 31 f6 xor %esi,%esi
fff88: eb 8a jmp 0xfff14
fff8a: 8d b6 00 00 00 00 lea 0x0(%esi),%esi
fff90: 55 push %ebp
fff91: 89 e5 mov %esp,%ebp
fff93: 57 push %edi
fff94: 56 push %esi
fff95: 53 push %ebx
fff96: 83 ec 58 sub $0x58,%esp
fff99: e8 aa 25 47 00 call 0x572548
fff9e: 81 fa 00 10 00 00 cmp $0x1000,%edx
fffa4: 89 cb mov %ecx,%ebx
fffa6: 89 45 c0 mov %eax,-0x40(%ebp)
fffa9: 89 55 cc mov %edx,-0x34(%ebp)
fffac: 0f 87 bb 07 00 00 ja 0x10076d
fffb2: 83 e8 01 sub $0x1,%eax
fffb5: 3d ff 7f 00 00 cmp $0x7fff,%eax
fffba: 0f 87 ad 07 00 00 ja 0x10076d
fffc0: b8 b8 46 8c c0 mov $0xc08c46b8,%eax
fffc5: e8 b6 9f 46 00 call 0x569f80
fffca: b8 80 13 a8 c0 mov $0xc0a81380,%eax
fffcf: e8 0c b3 46 00 call 0x56b2e0
fffd4: 84 db test %bl,%bl
fffd6: 89 45 e0 mov %eax,-0x20(%ebp)
fffd9: 0f 84 c8 00 00 00 je 0x1000a7
fffdf: 8b 3d 84 13 a8 c0 mov 0xc0a81384,%edi
fffe5: 85 ff test %edi,%edi
fffe7: 0f 84 ba 00 00 00 je 0x1000a7
fffed: 8b 45 c0 mov -0x40(%ebp),%eax
ffff0: bb b8 3b 80 c0 mov $0xc0803bb8,%ebx
ffff5: 3b 47 0c cmp 0xc(%edi),%eax
ffff8: 77 7e ja 0x100078
ffffa: 8b 47 14 mov 0x14(%edi),%eax
ffffd: 83 c0 02 add $0x2,%eax
100000: 39 47 18 cmp %eax,0x18(%edi)
100003: 7d 56 jge 0x10005b
100005: 8b 55 e0 mov -0x20(%ebp),%edx
100008: 89 c1 mov %eax,%ecx
10000a: 8d b6 00 00 00 00 lea 0x0(%esi),%esi
100010: 83 f9 10 cmp $0x10,%ecx
100013: bb 10 00 00 00 mov $0x10,%ebx
100018: 7e 0c jle 0x100026
10001a: 8d b6 00 00 00 00 lea 0x0(%esi),%esi
100020: 01 db add %ebx,%ebx
100022: 39 d9 cmp %ebx,%ecx
100024: 7f fa jg 0x100020
100026: b8 80 13 a8 c0 mov $0xc0a81380,%eax
10002b: e8 50 b2 46 00 call 0x56b280
100030: 89 da mov %ebx,%edx
100032: 89 f8 mov %edi,%eax
100034: e8 67 f5 ff ff call 0xff5a0
100039: 85 c0 test %eax,%eax
10003b: 0f 88 86 06 00 00 js 0x1006c7
100041: b8 80 13 a8 c0 mov $0xc0a81380,%eax
100046: e8 95 b2 46 00 call 0x56b2e0
10004b: 8b 4f 14 mov 0x14(%edi),%ecx
10004e: 83 c1 02 add $0x2,%ecx
100051: 39 4f 18 cmp %ecx,0x18(%edi)
100054: 89 c2 mov %eax,%edx
100056: 7c b8 jl 0x100010
100058: 89 45 e0 mov %eax,-0x20(%ebp)
10005b: 8b 4d cc mov -0x34(%ebp),%ecx
10005e: 89 f8 mov %edi,%eax
100060: bb b8 3b 80 c0 mov $0xc0803bb8,%ebx
100065: 8b 55 c0 mov -0x40(%ebp),%edx
100068: e8 83 f9 ff ff call 0xff9f0
10006d: 85 c0 test %eax,%eax
10006f: 89 45 b0 mov %eax,-0x50(%ebp)
100072: 0f 89 ef 01 00 00 jns 0x100267
100078: 8b 55 e0 mov -0x20(%ebp),%edx
10007b: b8 80 13 a8 c0 mov $0xc0a81380,%eax
100080: e8 fb b1 46 00 call 0x56b280
100085: b8 b8 46 8c c0 mov $0xc08c46b8,%eax
10008a: e8 a1 9e 46 00 call 0x569f30
10008f: 8b 35 cc 46 8c c0 mov 0xc08c46cc,%esi
100095: 85 f6 test %esi,%esi
100097: 0f 85 85 06 00 00 jne 0x100722
10009d: 31 c0 xor %eax,%eax
10009f: 83 c4 58 add $0x58,%esp
1000a2: 5b pop %ebx
1000a3: 5e pop %esi
1000a4: 5f pop %edi
1000a5: 5d pop %ebp
1000a6: c3 ret
1000a7: 8b 75 c0 mov -0x40(%ebp),%esi
1000aa: b8 ff ff ff ff mov $0xffffffff,%eax
1000af: 0f bd 55 c0 bsr -0x40(%ebp),%edx
1000b3: 0f 44 d0 cmove %eax,%edx
1000b6: 89 55 dc mov %edx,-0x24(%ebp)
1000b9: 39 35 ac 06 91 c0 cmp %esi,0xc09106ac
1000bf: 0f 84 a0 00 00 00 je 0x100165
1000c5: 8b 45 dc mov -0x24(%ebp),%eax
1000c8: 83 e8 02 sub $0x2,%eax
1000cb: 89 45 e4 mov %eax,-0x1c(%ebp)
1000ce: 85 c0 test %eax,%eax
1000d0: b8 01 00 00 00 mov $0x1,%eax
1000d5: 0f 4f 45 e4 cmovg -0x1c(%ebp),%eax
1000d9: 89 45 e4 mov %eax,-0x1c(%ebp)
1000dc: a1 b0 06 91 c0 mov 0xc09106b0,%eax
1000e1: 8b 5d e4 mov -0x1c(%ebp),%ebx
1000e4: c1 e3 03 shl $0x3,%ebx
1000e7: 39 45 e4 cmp %eax,-0x1c(%ebp)
1000ea: 0f 8d c3 00 00 00 jge 0x1001b3
1000f0: a1 b4 06 91 c0 mov 0xc09106b4,%eax
1000f5: 01 d8 add %ebx,%eax
1000f7: 8b 38 mov (%eax),%edi
1000f9: 39 f8 cmp %edi,%eax
1000fb: 0f 84 9c 00 00 00 je 0x10019d
100101: 8d b4 26 00 00 00 00 lea 0x0(%esi,%eiz,1),%esi
100108: 3b 77 0c cmp 0xc(%edi),%esi
10010b: 77 7f ja 0x10018c
10010d: 8b 47 14 mov 0x14(%edi),%eax
100110: 83 c0 02 add $0x2,%eax
100113: 39 47 18 cmp %eax,0x18(%edi)
100116: 7d 60 jge 0x100178
100118: 83 f8 10 cmp $0x10,%eax
10011b: bb 10 00 00 00 mov $0x10,%ebx
100120: 7e 0c jle 0x10012e
100122: 8d b6 00 00 00 00 lea 0x0(%esi),%esi
100128: 01 db add %ebx,%ebx
10012a: 39 d8 cmp %ebx,%eax
10012c: 7f fa jg 0x100128
10012e: 8b 55 e0 mov -0x20(%ebp),%edx
100131: b8 80 13 a8 c0 mov $0xc0a81380,%eax
100136: e8 45 b1 46 00 call 0x56b280
10013b: 89 da mov %ebx,%edx
10013d: 89 f8 mov %edi,%eax
10013f: e8 5c f4 ff ff call 0xff5a0
100144: 85 c0 test %eax,%eax
100146: 0f 88 ad 05 00 00 js 0x1006f9
10014c: b8 80 13 a8 c0 mov $0xc0a81380,%eax
100151: e8 8a b1 46 00 call 0x56b2e0
100156: 39 35 ac 06 91 c0 cmp %esi,0xc09106ac
10015c: 89 45 e0 mov %eax,-0x20(%ebp)
10015f: 0f 85 60 ff ff ff jne 0x1000c5
100165: a1 b0 06 91 c0 mov 0xc09106b0,%eax
10016a: 8d 48 ff lea -0x1(%eax),%ecx
10016d: 89 4d e4 mov %ecx,-0x1c(%ebp)
100170: e9 6c ff ff ff jmp 0x1000e1
100175: 8d 76 00 lea 0x0(%esi),%esi
100178: 8b 4d cc mov -0x34(%ebp),%ecx
10017b: 89 f2 mov %esi,%edx
10017d: 89 f8 mov %edi,%eax
10017f: e8 6c f8 ff ff call 0xff9f0
100184: 85 c0 test %eax,%eax
100186: 0f 89 d8 00 00 00 jns 0x100264
10018c: a1 b4 06 91 c0 mov 0xc09106b4,%eax
100191: 8b 3f mov (%edi),%edi
100193: 01 d8 add %ebx,%eax
100195: 39 c7 cmp %eax,%edi
100197: 0f 85 6b ff ff ff jne 0x100108
10019d: 83 45 e4 01 addl $0x1,-0x1c(%ebp)
1001a1: 83 c3 08 add $0x8,%ebx
1001a4: 8b 55 e4 mov -0x1c(%ebp),%edx
1001a7: 39 15 b0 06 91 c0 cmp %edx,0xc09106b0
1001ad: 0f 8f 3d ff ff ff jg 0x1000f0
1001b3: 8b 55 e0 mov -0x20(%ebp),%edx
1001b6: b8 80 13 a8 c0 mov $0xc0a81380,%eax
1001bb: e8 c0 b0 46 00 call 0x56b280
1001c0: a1 b8 06 91 c0 mov 0xc09106b8,%eax
1001c5: e8 86 f2 ff ff call 0xff450
1001ca: 85 c0 test %eax,%eax
1001cc: 89 c3 mov %eax,%ebx
1001ce: 0f 84 1b 05 00 00 je 0x1006ef
1001d4: b8 40 00 00 00 mov $0x40,%eax
1001d9: e8 72 f2 ff ff call 0xff450
1001de: 85 c0 test %eax,%eax
1001e0: 89 43 1c mov %eax,0x1c(%ebx)
1001e3: 0f 84 ff 04 00 00 je 0x1006e8
1001e9: 8b 4b 14 mov 0x14(%ebx),%ecx
1001ec: 8b 15 ac 06 91 c0 mov 0xc09106ac,%edx
1001f2: c7 43 18 10 00 00 00 movl $0x10,0x18(%ebx)
1001f9: 89 14 88 mov %edx,(%eax,%ecx,4)
1001fc: a1 bc 06 91 c0 mov 0xc09106bc,%eax
100201: 83 c1 01 add $0x1,%ecx
100204: 89 4b 14 mov %ecx,0x14(%ebx)
100207: 8b 0d c0 06 91 c0 mov 0xc09106c0,%ecx
10020d: 89 53 08 mov %edx,0x8(%ebx)
100210: 89 53 0c mov %edx,0xc(%ebx)
100213: 8b 15 c4 06 91 c0 mov 0xc09106c4,%edx
100219: 89 1b mov %ebx,(%ebx)
10021b: 89 5b 04 mov %ebx,0x4(%ebx)
10021e: 89 04 24 mov %eax,(%esp)
100221: a1 c8 06 91 c0 mov 0xc09106c8,%eax
100226: e8 35 f5 00 00 call 0x10f760
10022b: 85 c0 test %eax,%eax
10022d: 0f 84 e4 04 00 00 je 0x100717
100233: 89 43 20 mov %eax,0x20(%ebx)
100236: 8b 00 mov (%eax),%eax
100238: 8b 15 c8 06 91 c0 mov 0xc09106c8,%edx
10023e: 8b 40 04 mov 0x4(%eax),%eax
100241: 2b 02 sub (%edx),%eax
100243: 89 43 10 mov %eax,0x10(%ebx)
100246: b8 80 13 a8 c0 mov $0xc0a81380,%eax
10024b: e8 90 b0 46 00 call 0x56b2e0
100250: ba ff ff ff ff mov $0xffffffff,%edx
100255: 89 45 e0 mov %eax,-0x20(%ebp)
100258: 89 d8 mov %ebx,%eax
10025a: e8 81 f4 ff ff call 0xff6e0
More information about the Lguest
mailing list