Re: Kernel Tracking Question.. regarding kernel and boot files

From: Chris Richardson <chris.richardson.bsd_at_gmail.com>
Date: Sat, 9 Apr 2011 23:51:18 +0200
On Sat, Apr 9, 2011 at 10:34 PM, Chuck Swiger <cswiger_at_mac.com> wrote:

> Hi, Chris--
>
> [ ...Reply-to: set to direct towards the most appropriate list... ]
>
> On Apr 9, 2011, at 8:31 AM, Chris Richardson wrote:
> >   I am totally new to FreeBSD. I was involved within project which will
> > trace the kernel. I used ktrace but I could not get appropriate results
> > about the files being opened. I don't see any of the boot files boot0-1
> or 2
> > in the ktrace.out file. Where did they go?
>
> The bootstrap loader stages are what loads and runs the kernel.
> ktrace isn't available until afterwards, when the kernel is running.
>
> > Is ktrace the best "trace suite" for freebsd kernel?
>
> Kinda depends on what you are doing.  Setting up good logging and making
> userland
> interfaces for getting to useful information (cf vmstat, ps, iostat, etc)
> is
> more likely to be useful over the longer run.
>
>
What about if I wanna see the interaction between boot process and kernel
loading.


> > What about going through source code .. Is it better to
> > use Combination of Ecllipse/Qemu and FreeBSD Source tree?
>
> Eclipse is an editor.  If you like it in particular, free free to use it,
> otherwise pick something else you'd prefer to use for C code.
>
> > Does this method will provide us with someway to see how booting process
> invokes
> > the kernel to memory ? Any help will be appreciated.
>
> You're asking about the process here:
>
>
> http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/boot-blocks.html
>
> ...?  Frankly, none of these are especially big, start by reviewing the
> source
> code for 'em.
>
>
Yeah. this file provides me with the stages in theoretical way. How about
implementing it using qemu to emulate livecd to see what is going on boot0.
Do you have an idea about that ?

Good Luck,


> Regards,
> --
> -Chuck
>
>
>
Received on Sat Apr 09 2011 - 19:51:20 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:13 UTC