Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 4 Sep 2017 19:25:14 +0530
From:      Aijaz Baig <aijazbaig1@gmail.com>
To:        Julian Elischer <julian@freebsd.org>
Cc:        Gary Palmer <gpalmer@freebsd.org>, Bakul Shah <bakul@bitblocks.com>,  Kirk McKusick <mckusick@mckusick.com>, freebsd-fs@freebsd.org
Subject:   Re: Tips on remote debugging for filesystem code
Message-ID:  <CAHB2L%2Be7UogO9fg6G_SnZDcgQnCd=z=Um=JqgXtLMeWnsGZ2yQ@mail.gmail.com>
In-Reply-To: <e1fca65c-4468-295e-277f-e2c4b916978d@freebsd.org>
References:  <CAHB2L%2BcbBTfT%2Bpvg=c_39EKBSoLAo-_2KdmCcYgURQK5Gio4Xg@mail.gmail.com> <201708250251.v7P2pwcl029687@chez.mckusick.com> <CAHB2L%2BcrbMGvwAB7zx%2BnaLC5DTbOy7RWbxyFyPCGAZmaLoQ5fg@mail.gmail.com> <20170827195428.49400124AE9F@mail.bitblocks.com> <CAHB2L%2BfWd2WBU9GKNK8XGmmwvDTSFRUGChfhxozQ-k8Lj-VPBw@mail.gmail.com> <20170828132647.GA60563@in-addr.com> <CAHB2L%2BcicR7qSTGyhhhbx4eFtMn6P9snEzn5yac9WzXPL=pDhw@mail.gmail.com> <CAHB2L%2Bcrdda9fDdRnSvrZ46Pc8vbeJTdFAz390537Nnu9RPdDQ@mail.gmail.com> <e1fca65c-4468-295e-277f-e2c4b916978d@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi Julian

Yes it just hangs. Yes it's not like it just hangs every time. It's more
intermittent. This time I was stepping through 'kern_openat', really slowly
as I am new to this, checking out the structures and the likes and finally
this hit when I was within vn_open_cred. So yes the total time between
attaching to the stub within the VM and this happening was close to 3 hours
but nonetheless I do face this eventually

is there something I should watch out for, I mean is there something time
bound in some way for any of this code? Is this the reason why the VM
becomes unresponsive if I step really slowly through the stack trace?

On Mon, Sep 4, 2017 at 10:25 AM, Julian Elischer <julian@freebsd.org> wrote:

> On 2/9/17 8:40 pm, Aijaz Baig wrote:
>
> I was finally able to deploy a FreeBSD-Current VM on Bhyve but even with
> that setup I face a similar issue
>
> For instance I put a breakpoint on 'ffs_read' and let the debugged VM
> continue but the control is neither returned to (k)gdb nor does the VM
> actually run. It appears hung.
>
> are you sure it's not stopped at the breakpoint in ddb on the console?
>
>
> Is there something within the ffs/ufs code that I need to be aware of that
> it doesn't facilitate this sort of debugging? Or is it because Bhyve is
> being run on FreeBSD which is itself run on another hypervisor? Will that
> affect this?
>
> On Mon, Aug 28, 2017 at 7:03 PM, Aijaz Baig <aijazbaig1@gmail.com> wrote:
>
>> HI Gary
>>
>> Just checked that. Indeed that was the case. In addition I was running
>> FreeBSD on top of vmware hypervisor and had not allowed hardware
>> acceleration features pass through to the FreeBSD VM. It is now working!
>> Need to explore more on getting it to connect to GDB
>>
>> Perhaps you'll see a thread soon for it (Has anything worked perfectly
>> for the first time ever?? ;) )!
>>
>> On Mon, Aug 28, 2017 at 6:56 PM, Gary Palmer <gpalmer@freebsd.org> wrote:
>>
>>> On Mon, Aug 28, 2017 at 01:12:09PM +0530, Aijaz Baig wrote:
>>> > Thanks a lot bakul. Will certain look into this
>>> >
>>> > Nevertheless I got hold of a PowerEdge 320 system which DOES have a
>>> POPCNT
>>> > instruction which shows support for V-x support via EPT but I still
>>> get the
>>> > same error there
>>> >
>>> > sh /usr/share/examples/bhyve/vmrun.sh -c 1 -m 2048M -t tap0 -d
>>> guest.img -i
>>> > -I FreeBSD-10.3-RELEASE-amd64-bootonly.iso fbsd10
>>> > Launching virtual machine "fbsd10" ...
>>> > vm_create: Device not configured
>>> >
>>> > dmesg:
>>> > vmx_init: processor does not support VMX operation
>>> >
>>> > cat /var/run/dmesg.boot | grep -i popcnt
>>> >
>>> > Features2=0xffba2203<SSE3,PCLMULQDQ,SSSE3,CX16,PCID,SSE4.1,S
>>> SE4.2,x2APIC,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND,HV>
>>> >
>>> > Features2=0xffba2203<SSE3,PCLMULQDQ,SSSE3,CX16,PCID,SSE4.1,S
>>> SE4.2,x2APIC,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND,HV>
>>> >
>>> > Any ideas?
>>>
>>> Hi,
>>>
>>> Check the BIOS for virtualisation or other related options.  Some BIOSes
>>> have
>>> the ability to turn those features off, even if the processor normally
>>> supports them
>>>
>>> Regards,
>>>
>>> Gary
>>>
>>
>>
>>
>> --
>>
>> Best Regards,
>> Aijaz Baig
>>
>
>
>
> --
>
> Best Regards,
> Aijaz Baig
>
>
>


-- 

Best Regards,
Aijaz Baig



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAHB2L%2Be7UogO9fg6G_SnZDcgQnCd=z=Um=JqgXtLMeWnsGZ2yQ>