Subject: admin/18018: "ktrace -C" fails if ktrace.out not present
To: None <>
From: None <>
List: netbsd-bugs
Date: 08/21/2002 11:30:45
>Number:         18018
>Category:       admin
>Synopsis:       "ktrace -C" fails if ktrace.out not present
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    netbsd-admin
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Aug 21 11:31:00 PDT 2002
>Originator:     Ed Ravin
>Release:        1.5.2
Public Access Networks Corp
NetBSD 1.6_BETA4 NetBSD 1.6_BETA4 (PANIX-USER) #0: Thu Jul 25 15:59:49 EDT 2002 i386

If you call "ktrace -C" without a file named "ktrace.out" in the
current directory, or without otherwise specifying a valid trace
file, tracing is not canceled for all processes as it's supposed to

On both NetBSD 1.5.2 and NetBSD 1.6_BETA4, when I start a ktrace with:

  # ktrace -f some.file -p PID

I won't be able to shut off tracing the normal way:

  # ktrace -C
  ktrace: ktrace.out: No such file or directory

Looking at the trace file shows that it continues to grow, until:

  # ktrace -f some.file -C

Which finally stops the tracing.

workaround is to specify "ktrace -f valid-file -C".  It doesn't seem
to matter what's in the file.