Feed for discussion General in project dtrace.
http://community.qnx.com/sf/discussion/do/listTopics/projects.dtrace/discussion.general
Posts for Generalpost97617: Backtrace from signal handler
http://community.qnx.com/sf/go/post97617
I'm not sure if this is the right location, but please move it if I'm wrong.
I am developing a program on QNX Neutrino 6.4.1 and sometimes I get a signal and the program crashes.
I already have a signal handler implemented, but what I want to have is a printed back-trace in my logging.
I have read : http://www.qnx.com/developers/docs/6.4.1/neutrino/technotes/backtrace.html
and still have a few questions.
My program is multi-threaded, but I hope that the thread that enters the signal handler is the same as the one that caused the problem, can anyone verify this?
I hope I can use "backtrace the calling thread"
In a multi-threaded application, can I use:
[code]
bt_init_accessor(&acc_sighandler1, BT_SELF);
[/code]
in the main once for ALL threads?
Or does the function needs to be called for each thread?
The function:
[code]
cnt_sighandler1 =
bt_get_backtrace(&acc_sighandler1, pc_sighandler1,
sizeof(pc_sighandler1)/sizeof(bt_addr_t));
[/code]
Gets the backtrace, but does anyone know if it delivers readable data, of function pointers?Rob Deckers2012-11-29T14:49:31Zpost28270: Re: InitialPrototype build issues (newbie)
http://community.qnx.com/sf/go/post28270
Thanks for helping out, Aaron. I'm sorry missed your questions, William, I've been ever so flat out with 6.4.1
I'll try to keep more on top of any questions that come in, so please do keep posting.
Colin
Aaron Cripps wrote:
> Hey William.
> What you are seeing when you build right now is the dtrace module to be included in the IFS; This was the *original* way of including DTrace in neutrino, but Colin now has it running in a rousource manager instead. The reason you're get this is because you aren't compiling the source code from the correct location; the InitialPrototype page instructs you to get the source from <SVN_ROOT>/dtrace_pub/branches/old_dev_dtrace
>
> Currently the dtrace_pub trunk is missing things, and the ctf_utils_dev is horribly broken (I really should get around to fixing that). Good luck with your project. Write back to let us know how you fare.
>
> -Aaron Cripps
>
>
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post28268
>
--
cburgess@qnx.comColin Burgess2009-04-28T18:35:19Zpost28268: Re: InitialPrototype build issues (newbie)
http://community.qnx.com/sf/go/post28268
Hey William.
What you are seeing when you build right now is the dtrace module to be included in the IFS; This was the *original* way of including DTrace in neutrino, but Colin now has it running in a rousource manager instead. The reason you're get this is because you aren't compiling the source code from the correct location; the InitialPrototype page instructs you to get the source from <SVN_ROOT>/dtrace_pub/branches/old_dev_dtrace
Currently the dtrace_pub trunk is missing things, and the ctf_utils_dev is horribly broken (I really should get around to fixing that). Good luck with your project. Write back to let us know how you fare.
-Aaron CrippsAaron Cripps2009-04-28T18:27:08Zpost23944: Re: Wow, not too much going on here...
http://community.qnx.com/sf/go/post23944
That would be neat... :-)
Rennie Allen wrote:
> Perhaps uou guys could hire Paul Fox to work on this...
>
> Dtrace for QNX, would be killer...
>
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post23940
>
--
cburgess@qnx.comColin Burgess2009-03-09T18:41:13Zpost23940: Wow, not too much going on here...
http://community.qnx.com/sf/go/post23940
Perhaps uou guys could hire Paul Fox to work on this...
Dtrace for QNX, would be killer...Rennie Allen2009-03-09T18:34:40Zpost23865: Re: InitialPrototype build issues (newbie)
http://community.qnx.com/sf/go/post23865
BumpWilliam Gibson2009-03-08T16:46:40Zpost22697: InitialPrototype build issues (newbie)
http://community.qnx.com/sf/go/post22697
First off I just wanted to say Hi to the people working on DTrace.. My friends and I going to be using it as a basis for our fourth year design project in university.
That said, I'm fairly new to *nix in general, especially so with building parts of an OS, so please don't be too harsh when I ask silly questions :P
I've literally been trying to get DTrace for 12 hours.. Finally I got it downloaded (I know that sounds terrible... I tried using 6.2.1 and 6.3 but neither came SVN installed, and tried downloading and building a copy of that, to no avail) so now I'm on 6.4, trying to make DTrace on self-hosted Neutrino, x86.
BTW I'm using Microsoft VirtualPC to run my QNX box.
Oh, and I got the source from the SVN checkout /svn/repos/dtrace_pub
That is InitialPrototype, correct? Or have I been screwing with the old dtrace source... If so, please point me to the correct checkout
My dtrace source is in /root/dtrace_pub, which is where I happened to be when I called svn checkout
I set up the staging directory as specified:
1. Made the 'stage' directory (/root/dtrace_pub/stage)
2. Created the qconf-override.mk file, but since I'm using 6.4 I set the VERSION_REL to 6.4.0 instead of 6.3.0
Not sure if that's the right thing to do...
3. set the QCONF_OVERRIDE environment variable to the .mk file in 2.
- Question about the environment variables...
Sometimes my box crashes (probably due to being a virtual machine) and when I restart, the environment variables are reset to their defaults, so I have to re-set the QCONF_OVERRIDE. Why are these not being saved correctly?
4. I tried to run make in /trunk but as was mentioned in another post on this forum, we shouldn't be making the trunk of DTrace.. Besides there is no 'Makefile' there, so I couldn't even if I wanted to.
So, what folder should we be calling make inside? (read on for my attempt)
I've tried to make inside dtrace_pub/trunk/lib/dtrace
make CPULIST=x86 hinstall
results:
make -j 1 -Cx86 -fMakefile hinstall
make[1]: Entering directory 'root/dtrace_pub/trunk/lib/x86'
make -j 1 -Ca -fMakefile hinstall
make[2] Entering directory 'root/dtrace_pub/trunk/lib/x86/a'
make[2] Nothing to be done for 'hinstall'.
make[2] Leaving directory 'root/dtrace_pub/trunk/lib/x86/a'
make[1] Leaving directory 'root/dtrace_pub/trunk/lib/x86'
and then make CPULIST=x86 install
at which point the results are very similar, except when hinstall says nothing to be done, install does this:
/bin/cp -vfpc libdtrace.a /usr/qnx640/target/qnx6/x86/lib/libdtrace.a
cp: Copying libdtrace.a to /usr/qnx640/target/qnx6/x86/lib/libdtrace.a
Then when I go into my staging directory, obviously all I find is /root/dtrace_pub/stage/x86/lib/libdtrace.a
So there are several places I could be going wrong here... hoping for some tips to get me started.
I've been reading documents in the community, like "Understanding the Neutrino Build Process" and "Build It -- Downloading the Neutrino OS/Kernel Source" to no avail..
All they bring up is more questions.. Like when I examine the Makefiles in the /trunk/lib/dtrace and /trunk/lib/dtrace/x86 directories, they reference recurse.mk. According to "U t N B P" (at the bottom), the 'magic' files should be:
$QNX_TARGET/usr/include/recurse.mk
$QNX_TARGET/usr/include/qconfig.mk
$QNX_TARGET/usr/include/buildlist.mk
With support of the $QNX_TARGET/usr/include/mk
But these directories and files do not exist in the DTrace source..
Am I not looking correctly, or do I need to get these from somewhere else?
Please help me out. Your responses are *greatly* appreciated.
Thanks!
William GibsonWilliam Gibson2009-02-22T20:52:23Zpost14046: subscribe
http://community.qnx.com/sf/go/post14046
Giovani Gracioli2008-09-25T18:21:59Zpost10407: How to create new provider ?????
http://community.qnx.com/sf/go/post10407
Can i create my own provider with a set of my own probes (in dtrace intial prototype)?
If so how to do it ?samir kumar2008-07-11T13:48:51Zpost9980: Re: dtrace build issue
http://community.qnx.com/sf/go/post9980
Hi Grunush,
You shouldn't need to build the kernel source.
However you should not build the 'trunk' of dtrace - it's not in a sane state. If you want to play around
and get to know the source, use branches/old_dev_dtrace - that should build for you. Make sure to do a make
hinstall; make install - and setup a stage directory! (see the QNX OS Project for details on how to do that
if you don't know how)
Cheers,
Colin
Grunush D wrote:
> Hi,
>
> My setup has a standalone x86 qnx machine.
>
> I have downloaded qnx dtrace source code through svn and followed the instructions for dtrace source build. I couldn't successfully build dtrace source code. Could you please clarify the following?
>
> a. Should I be building QNX OS/Kernel source before building dtrace?
>
> b. Though both the OS and dtrace source have "trunk" folders, I couldn't find Makefile within dtrace/trunk. Should we explicitly create a Makefile within dtrace/trunk for its build to succeed? If so, what should be its contents for "make CPULIST=x86 hinstall" in dtrace build to work?
>
> Thanks and Regards,
> Grunush
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post9979
>
--
cburgess@qnx.comColin Burgess2008-07-03T01:36:49Zpost9979: dtrace build issue
http://community.qnx.com/sf/go/post9979
Hi,
My setup has a standalone x86 qnx machine.
I have downloaded qnx dtrace source code through svn and followed the instructions for dtrace source build. I couldn't successfully build dtrace source code. Could you please clarify the following?
a. Should I be building QNX OS/Kernel source before building dtrace?
b. Though both the OS and dtrace source have "trunk" folders, I couldn't find Makefile within dtrace/trunk. Should we explicitly create a Makefile within dtrace/trunk for its build to succeed? If so, what should be its contents for "make CPULIST=x86 hinstall" in dtrace build to work?
Thanks and Regards,
GrunushGrunush D2008-07-03T01:33:22Zpost7764: Re: libmod_dtrace.a
http://community.qnx.com/sf/go/post7764
Ah joy! :-)
Hans-Peter Reicher wrote:
> hmm hmmm hmmm hmm hmm
> was it realy that easy? or did I an UTS?
> I have a libelf.a but now libdtrace is failing in dt_link.c
> and after two more ifdef __sh__ I had to strike my sails on
> dt_modtext
> I hate assembler!!!
> /hp
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post7763
>
--
cburgess@qnx.comColin Burgess2008-05-06T19:29:10Zpost7763: Re: libmod_dtrace.a
http://community.qnx.com/sf/go/post7763
hmm hmmm hmmm hmm hmm
was it realy that easy? or did I an UTS?
I have a libelf.a but now libdtrace is failing in dt_link.c
and after two more ifdef __sh__ I had to strike my sails on
dt_modtext
I hate assembler!!!
/hpHans-Peter Reichert2008-05-06T19:27:39Zpost7759: Re: libmod_dtrace.a
http://community.qnx.com/sf/go/post7759
The core body of code doesn't actually have any dependencies, it's mainly
the headers need setting up.
Colin
Hans-Peter Reicher wrote:
> hmmmmm
> I am not an ELF wise man - man
> your talking about branches/old_dev_dtrace/lib/elf ?
> so do you have a hint what to do there?
> What i see is that the SH env is missing at all, has this to be
> configured or is it a start copying x86 and replace with SH?
>
> /hp
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post7757
>
--
cburgess@qnx.comColin Burgess2008-05-06T18:44:34Zpost7757: Re: libmod_dtrace.a
http://community.qnx.com/sf/go/post7757
hmmmmm
I am not an ELF wise man - man
your talking about branches/old_dev_dtrace/lib/elf ?
so do you have a hint what to do there?
What i see is that the SH env is missing at all, has this to be configured or is it a start copying x86 and replace with SH?
/hpHans-Peter Reichert2008-05-06T18:37:28Zpost7756: Re: libmod_dtrace.a
http://community.qnx.com/sf/go/post7756
No, and no. :-)
The main reason it hasn't been committed yet is that it required hacks
to mkxfs to make it work.
Until I get that sorted out I likely won't be able to commit these changes.
However since this is getting in the way it's my number 1 dtrace prio right
now.
In the meantime you could port libelf to SH! :-)
Colin
Hans-Peter Reicher wrote:
> Hi Colin,
> but this is yet not comitted? or?
> BTW: is there kind a "how to" on writing kernel modules?
>
> /hp
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post7755
>
--
cburgess@qnx.comColin Burgess2008-05-06T17:48:38Zpost7755: Re: libmod_dtrace.a
http://community.qnx.com/sf/go/post7755
Hi Colin,
but this is yet not comitted? or?
BTW: is there kind a "how to" on writing kernel modules?
/hpHans-Peter Reichert2008-05-06T17:37:04Zpost7583: libmod_dtrace.a
http://community.qnx.com/sf/go/post7583
Well after a fair amount of head scratching I managed to hack up a
libmod_dtrace.a kernel module.
The main issue (make issues aside) was getting the dtrace resource manager
to play ball with
procnto. It turns out that you can't use a lot of the iofunc_*default
routines!
So now I have a basic dtrace device running within procnto. The main
impetus for this was that
I wanted to get the ustack() provider running. This is arguably one of the
more useful bits
of info you can get, and running the probes in an event handler, you don't
have access to the
user context of the probed process (because the kernel switched the address
space to your
context before calling your function).
Up next - a kercall provider and hopefully then the stack() and ustack()
actions. Cool bananas!
Oh, and cleaning up my resmgr mess! :-)
Colin
--
cburgess@qnx.comColin Burgess2008-05-02T03:47:21Zpost7392: Re: dtrace: process aborted
http://community.qnx.com/sf/go/post7392
Meh, it was bad timer creation code. You need to set an initial value, even
for an interval timer. :-)
Hans-Peter Reicher wrote:
> yep, I am running this in a vm ware session.
> I will try this the next days on a native x86 installation
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post7382
>
--
cburgess@qnx.comColin Burgess2008-04-28T14:59:02Zpost7388: Re: dtrace: process aborted
http://community.qnx.com/sf/go/post7388
It appears to be a issue with the deadman timer being implemented as a user
thread,
whereas the check for deadman timeout is done at kernel time in the
dtrace_probe function.
Hans-Peter Reicher wrote:
> yep, I am running this in a vm ware session.
> I will try this the next days on a native x86 installation
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post7382
>
--
cburgess@qnx.comColin Burgess2008-04-28T14:50:41Zpost7386: Re: dtrace: process aborted
http://community.qnx.com/sf/go/post7386
I'm looking into it. Cheers,
Colin
Hans-Peter Reicher wrote:
> yep, I am running this in a vm ware session.
> I will try this the next days on a native x86 installation
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post7382
>
--
cburgess@qnx.comColin Burgess2008-04-28T14:46:11Zpost7382: Re: RE: dtrace: process aborted
http://community.qnx.com/sf/go/post7382
yep, I am running this in a vm ware session.
I will try this the next days on a native x86 installationHans-Peter Reichert2008-04-28T14:18:33Zpost7367: Re: just to let you know
http://community.qnx.com/sf/go/post7367
Cool - my first bug reports! :-)
Jeevan Mathew wrote:
> <<< Incoming Message Inspected due to ZIP attachment >> <<Sourceforge
> Attachment>> >
> it does indeed work :-) , doh !
>
> And following the Solaris 10 Software Developer Collection >> Solaris
> Dynamic Tracing Guide >> 1. Introduction
>
> here:
> http://docs.sun.com/app/docs/doc/817-6223/chp-intro?a=view
>
> is helpful too.
>
> Jeevan
>
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post7361
>
--
cburgess@qnx.comColin Burgess2008-04-28T13:15:33Zpost7361: just to let you know
http://community.qnx.com/sf/go/post7361
it does indeed work :-) , doh !
And following the Solaris 10 Software Developer Collection >> Solaris Dynamic Tracing Guide >> 1. Introduction
here:
http://docs.sun.com/app/docs/doc/817-6223/chp-intro?a=view
is helpful too.
JeevanJeevan Mathew2008-04-28T11:18:55Zpost7351: RE: dtrace: process aborted
http://community.qnx.com/sf/go/post7351
Are you running this in a vmware session? I saw this too, recently. I have
yet to nail it down though, but will be looking into it...
But basically is means that io-dtrace is not getting a chance to process
it's watchdog timer.
I believe Thomas set this up to be a pulse event. I'll look into the code.
Thanks,
Colin
_____
From: Hans-Peter Reicher [mailto:hpreichert@harmanbecker.com]
Sent: Sat 26/04/2008 3:18 PM
To: general-dtrace
Subject: dtrace: process aborted
when I run the example from the wiki page
dtrace -n "kercalls::enter { @count[execname,probefunc] = count(); }"
and let this run without doing ctrl-c I get an error message after some
seconds
dtrace:process aborted: Abort due to systemic unresponsiveness
whereas when I ctrl-c it, I get the expected output
Do you have a hint for me what's going wrong?
/hp
_______________________________________________
General
http://community.qnx.com/sf/go/post7346
<http://community.qnx.com/sf/go/post7346>Colin Burgess2008-04-27T00:59:14Zpost7350: RE: staging dir and x86 build
http://community.qnx.com/sf/go/post7350
Hmmm, can you post your base directory layout, and your override
settings/files?
Cheers,
Colin
_____
From: Hans-Peter Reicher [mailto:hpreichert@harmanbecker.com]
Sent: Sat 26/04/2008 3:13 PM
To: general-dtrace
Subject: staging dir and x86 build
I tried to build the x86 version, it works quite fine except taht the result
or not in the staging dir.
I am not used to this kind of build process so maybe or quite sure it's an
UTS
but as an info for others: the build is working
_______________________________________________
General
http://community.qnx.com/sf/go/post7345
<http://community.qnx.com/sf/go/post7345>Colin Burgess2008-04-27T00:57:39Zpost7349: RE: wiki page
http://community.qnx.com/sf/go/post7349
Thanks, I've updated the page. Und es sei doch "Korinthenkacker"
buchstabiert, nicht wahr? (Danke Leo!) :-)
_____
From: Hans-Peter Reicher [mailto:hpreichert@harmanbecker.com]
Sent: Sat 26/04/2008 3:11 PM
To: general-dtrace
Subject: wiki page
Hi Colin,
I gave it chance.
Maybe you'd like to correct some minors on
http://community.qnx.com/sf/wiki/do/viewPage/projects.dtrace/wiki/InitialPro
totype
<http://community.qnx.com/sf/wiki/do/viewPage/projects.dtrace/wiki/InitialPr
ototype>
under "Run it"
maybe somebody needs the hint to start io-dtrace first.
and the line
dtrace -n "kercalls::enter { @count[execname,probefunc] = count(); }
is missing the closing "
but don't call me a Korintenkacker ;-)
/hp
_______________________________________________
General
http://community.qnx.com/sf/go/post7344
<http://community.qnx.com/sf/go/post7344>Colin Burgess2008-04-27T00:57:05Zpost7346: dtrace: process aborted
http://community.qnx.com/sf/go/post7346
when I run the example from the wiki page
dtrace -n "kercalls::enter { @count[execname,probefunc] = count(); }"
and let this run without doing ctrl-c I get an error message after some seconds
dtrace:process aborted: Abort due to systemic unresponsiveness
whereas when I ctrl-c it, I get the expected output
Do you have a hint for me what's going wrong?
/hpHans-Peter Reichert2008-04-26T19:18:42Zpost7345: staging dir and x86 build
http://community.qnx.com/sf/go/post7345
I tried to build the x86 version, it works quite fine except taht the result or not in the staging dir.
I am not used to this kind of build process so maybe or quite sure it's an UTS
but as an info for others: the build is workingHans-Peter Reichert2008-04-26T19:13:55Zpost7344: wiki page
http://community.qnx.com/sf/go/post7344
Hi Colin,
I gave it chance.
Maybe you'd like to correct some minors on http://community.qnx.com/sf/wiki/do/viewPage/projects.dtrace/wiki/InitialPrototype
under "Run it"
maybe somebody needs the hint to start io-dtrace first.
and the line
dtrace -n "kercalls::enter { @count[execname,probefunc] = count(); }
is missing the closing "
but don't call me a Korintenkacker ;-)
/hpHans-Peter Reichert2008-04-26T19:11:36Zpost7266: Re: ready made build
http://community.qnx.com/sf/go/post7266
Tsk tsk
There's no ready-made build as yet, no.
The trunk will be of no use to you yet, but you should be able to build the
prototype
just fine.
Just make sure to follow the instructions for setting up a staging dir,
checkout the
branch branches/old_dev_dtrace and then type make CPULIST=x86 install
Colin
Jeevan Mathew wrote:
> Hello Colin,
>
> Because I am absolut starter-user and
> because of notoric lazyness I was searching for some ready made build,
> but exploring this pages I failed to find some package.
>
> Given that there is no package can anybody ( including me) give this
> some try building the stuff just from [dtrace_pub] / branches /
> old_dev_dtrace ?
>
> Sure that I did missed many things more sofar :-) .
>
> Regards,
> -Jeevan
>
> _______________________________________________
> General
> http://community.qnx.com/sf/go/post7261
>
--
cburgess@qnx.comColin Burgess2008-04-24T17:54:07Zpost7261: ready made build
http://community.qnx.com/sf/go/post7261
Hello Colin,
Because I am absolut starter-user and
because of notoric lazyness I was searching for some ready made build, but exploring this pages I failed to find some package.
Given that there is no package can anybody ( including me) give this some try building the stuff just from [dtrace_pub] / branches / old_dev_dtrace ?
Sure that I did missed many things more sofar :-) .
Regards,
-JeevanJeevan Mathew2008-04-24T17:31:57Zpost7224: Welcome to the Dtrace Project!
http://community.qnx.com/sf/go/post7224
It's early days but it's time to get this cool tool going!
There's build instructions for the initial prototype on the wiki
pages - go get it!
Colin
--
cburgess@qnx.comColin Burgess2008-04-23T19:34:18Z