* Tracing through init transitions
@ 2010-05-03 14:12 Alan D. Brunelle
2010-05-03 19:58 ` Jim Keniston
2010-05-04 16:58 ` Frank Ch. Eigler
0 siblings, 2 replies; 3+ messages in thread
From: Alan D. Brunelle @ 2010-05-03 14:12 UTC (permalink / raw)
To: systemtap
[-- Attachment #1: Type: text/plain, Size: 590 bytes --]
I'm trying to trace the opening of files under /proc & /sys during the
transition from single-user to run level 3, but either the tracing
doesn't start or gets killed. I've tried various means of trying to
daemonize the systemtap run (including starting this via an rc script
utilizing the "daemon" function, and trying the -F option), but nothing
I've tried seems to work.
Any suggestions?
Thanks (please CC me as I'm no longer on the systemtap mailing list),
Alan
PS. I've attached the script, although I doubt there's anything
particular in there that would make a difference...
[-- Attachment #2: opens.stp --]
[-- Type: text/plain, Size: 425 bytes --]
#! /usr/bin env stap
global opens[4000]
function print_opens() {
foreach ([exe, fn, wr] in opens-) {
if (wr) str = "WR"
else str = "RD"
printf("%4d %-20s: %s %s\n", opens[exe, fn, wr], exe, str, fn)
}
}
probe kernel.function("sys_open") {
fn = user_string($filename)
if (substr(fn, 0, 6) == "/proc/" || substr(fn, 0, 5) == "/sys/")
opens[execname(), fn, $flags & 1] ++
}
probe end {
print_opens()
exit()
}
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Tracing through init transitions
2010-05-03 14:12 Tracing through init transitions Alan D. Brunelle
@ 2010-05-03 19:58 ` Jim Keniston
2010-05-04 16:58 ` Frank Ch. Eigler
1 sibling, 0 replies; 3+ messages in thread
From: Jim Keniston @ 2010-05-03 19:58 UTC (permalink / raw)
To: Alan D. Brunelle; +Cc: systemtap
On Fri, 2010-04-30 at 15:44 -0400, Alan D. Brunelle wrote:
> I'm trying to trace the opening of files under /proc & /sys during the
> transition from single-user to run level 3, but either the tracing
> doesn't start or gets killed. I've tried various means of trying to
> daemonize the systemtap run (including starting this via an rc script
> utilizing the "daemon" function, and trying the -F option), but nothing
> I've tried seems to work.
>
> Any suggestions?
>
> Thanks (please CC me as I'm no longer on the systemtap mailing list),
> Alan
> PS. I've attached the script, although I doubt there's anything
> particular in there that would make a difference...
> plain text document attachment (opens.stp)
> #! /usr/bin env stap
"bin env" should be "bin/env", right?
>
> global opens[4000]
Jim
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Tracing through init transitions
2010-05-03 14:12 Tracing through init transitions Alan D. Brunelle
2010-05-03 19:58 ` Jim Keniston
@ 2010-05-04 16:58 ` Frank Ch. Eigler
1 sibling, 0 replies; 3+ messages in thread
From: Frank Ch. Eigler @ 2010-05-04 16:58 UTC (permalink / raw)
To: Alan D. Brunelle; +Cc: systemtap
"Alan D. Brunelle" <alan.brunelle@hp.com> writes:
> I'm trying to trace the opening of files under /proc & /sys during the
> transition from single-user to run level 3, but either the tracing
> doesn't start or gets killed. [...]
The script looks fine. If that #! path fixing doesn't help, please
supply more data regarding the commands you've tried and errors you've
seen. "stap --vp 00005 ..." for example.
- FChE
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-05-01 20:28 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-05-03 14:12 Tracing through init transitions Alan D. Brunelle
2010-05-03 19:58 ` Jim Keniston
2010-05-04 16:58 ` Frank Ch. Eigler
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).