History log of /freebsd-current/usr.bin/ktrace/ktrace.1
Revision Date Author Comments
# f239db48 23-Apr-2024 Jake Freeland <jfree@FreeBSD.org>

ktrace: Remove CAPFAIL from default trace points

The CAPFAIL tracepoint was recently extended to report ECAPMODE
capability violations for processes that do not enter capability mode.
This allows developers that are interested in Capsicumizing their
programs to determine where violations are being raised.

Previously, CAPFAIL only produced output for processes using Capsicum(4)
capabilties. Thus, most ktrace users never received log output from the
trace point. With the recent changes, this is no longer the case.

Having this trace point enabled by default will produce output for all
processes that use syscalls that are not permitted in capability mode.
This may lead to confusion for users that are not familiar with the
feature. Remove KTRFAC_CAPFAIL from ktrace's default points to avoid
this.

Approved by: markj (mentor)
Reviewed by: markj
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D44887


# 4f2ada0d 23-Apr-2024 Jake Freeland <jfree@FreeBSD.org>

ktrace: Describe CAPFAIL trace point in man page

Update the ktrace(1) man page to describe the recently improved
capability failure tracing.

Approved by: markj (mentor)
Reviewed by: markj
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D44886


# bdcbfde3 23-Nov-2023 Warner Losh <imp@FreeBSD.org>

usr.bin: Remove ancient SCCS tags.

Remove ancient SCCS tags from the tree, automated scripting, with two
minor fixup to keep things compiling. All the common forms in the tree
were removed with a perl script.

Sponsored by: Netflix


# b2c76c41 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line nroff pattern

Remove /^\.\\"\s*\$FreeBSD\$$\n/


# 90a7bed4 26-Aug-2019 Edward Tomasz Napierala <trasz@FreeBSD.org>

Make it clear what the userland traces are in the ktrace(1) man page.

MFC after: 2 weeks


# 6e5f5f90 24-Jul-2017 Edward Tomasz Napierala <trasz@FreeBSD.org>

Improve the ktrace(1) man page to make it slightly more obvious that there
are _two_ options that control its behaviour wrt child processes; slightly
improve the example[1], and add Xrefs.

Discussed with: wblock [1]
MFC after: 2 weeks
Sponsored by: DARPA, AFRL


# c5ed2864 21-Jul-2017 Edward Tomasz Napierala <trasz@FreeBSD.org>

Use more usual formatting for the EXAMPLES section of ktrace(1).

MFC after: 2 weeks
Sponsored by: DARPA, AFRL


# fbbd9655 28-Feb-2017 Warner Losh <imp@FreeBSD.org>

Renumber copyright clause 4

Renumber cluase 4 to 3, per what everybody else did when BSD granted
them permission to remove clause 3. My insistance on keeping the same
numbering for legal reasons is too pedantic, so give up on that point.

Submitted by: Jan Schaumann <jschauma@stevens.edu>
Pull Request: https://github.com/freebsd/freebsd/pull/96


# f4864c27 31-Mar-2016 Brooks Davis <brooks@FreeBSD.org>

Add a cross reference to ktrace(2).

Obtained from: CheriBSD (9cb420d6b7f04c1b7d2006180b80932e5d3fe50e)
MFC after: 1 week
Sponsored by: DARPA, AFRL


# 0b976534 26-Aug-2014 John Baldwin <jhb@FreeBSD.org>

Clarify that the -c argument clears the list of tracepoints specified by
-t (it does not clear all tracepoints).

Submitted by: jmg, Eric van Gyzen <eric@vangyzen.net>
MFC after: 1 week


# 5c506fb0 31-May-2012 John Baldwin <jhb@FreeBSD.org>

Don't trace or dump page fault records in the default set of tracepoints
as they can be quite noisy.

Requested by: Peter Jeremy
MFC after: 3 days


# 35818d2e 05-Apr-2012 John Baldwin <jhb@FreeBSD.org>

Add new ktrace records for the start and end of VM faults. This gives
a pair of records similar to syscall entry and return that a user can
use to determine how long page faults take. The new ktrace records are
enabled via the 'p' trace type, and are enabled in the default set of
trace points.

Reviewed by: kib
MFC after: 2 weeks


# c601ad8e 11-Oct-2011 Dag-Erling Smørgrav <des@FreeBSD.org>

Add a new trace point, KTRFAC_CAPFAIL, which traces capability check
failures. It is included in the default set for ktrace(1) and kdump(1).


# da52b4ca 11-Dec-2010 Joel Dahl <joel@FreeBSD.org>

Remove the advertising clause from UCB copyrighted files in usr.bin. This
is in accordance with the information provided at
ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change

Also add $FreeBSD$ to a few files to keep svn happy.

Discussed with: imp, rwatson


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# d4523bd9 14-Jul-2010 John Baldwin <jhb@FreeBSD.org>

- Sort list of trace points.
- Note that 'y' (sysctl requests) is in the default set of trace points.

MFC after: 3 days


# fe0506d7 09-Mar-2010 Marcel Moolenaar <marcel@FreeBSD.org>

Create the altix project branch. The altix project will add support
for the SGI Altix 350 to FreeBSD/ia64. The hardware used for porting
is a two-module system, consisting of a base compute module and a
CPU expansion module. SGI's NUMAFlex architecture can be an excellent
platform to test CPU affinity and NUMA-aware features in FreeBSD.


# a56be37e 11-Mar-2009 John Baldwin <jhb@FreeBSD.org>

Add a new type of KTRACE record for sysctl(3) invocations. It uses the
internal sysctl_sysctl_name() handler to map the MIB array to a string
name and logs this name in the trace log. This can be useful to see
exactly which sysctls a thread is invoking.

MFC after: 1 month


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# da647ae9 02-Apr-2008 Ruslan Ermilov <ru@FreeBSD.org>

Spell -t option's argument by name.


# 60e15db9 22-Feb-2008 Dag-Erling Smørgrav <des@FreeBSD.org>

This patch adds a new ktrace(2) record type, KTR_STRUCT, whose payload
consists of the null-terminated name and the contents of any structure
you wish to record. A new ktrstruct() function constructs and emits a
KTR_STRUCT record. It is accompanied by convenience macros for struct
stat and struct sockaddr.

In kdump(1), KTR_STRUCT records are handled by a dispatcher function
that runs stringent sanity checks on its contents before handing it
over to individual decoding funtions for each type of structure.
Currently supported structures are struct stat and struct sockaddr for
the AF_INET, AF_INET6 and AF_UNIX families; support for AF_APPLETALK
and AF_IPX is present but disabled, as I am unable to test it properly.

Since 's' was already taken, the letter 't' is used by ktrace(1) to
enable KTR_STRUCT trace points, and in kdump(1) to enable their
decoding.

Derived from patches by Andrew Li <andrew2.li@citi.com>.

PR: kern/117836
MFC after: 3 weeks


# df449c35 06-Nov-2006 Tom Rhodes <trhodes@FreeBSD.org>

Add needed hyphens, note the KTRACE kernel option, bump doc date.

PR: 85186
Submitted by: garys


# 6c7216df 18-Jan-2005 Ruslan Ermilov <ru@FreeBSD.org>

Sort sections.


# e8937ba0 19-Apr-2002 Philippe Charnier <charnier@FreeBSD.org>

Use `The .Nm utility'


# 943c2638 02-Mar-2002 Giorgos Keramidas <keramida@FreeBSD.org>

Consistently refer to the trace file of ktrace as 'trfile'.

PR: docs/35361
Submitted by: Stefan Farfeleder <e0026813@stud3.tuwien.ac.at>


# fef3edec 11-Feb-2002 Peter Pentchev <roam@FreeBSD.org>

Describe the '+' option in the -t trace string.

PR: 34668
Submitted by: Stefan Farfeleder <e0026813@stud3.tuwien.ac.at>
Reviewed by: dd
Approved by: dd
MFC after: 1 week


# f247324d 15-Jul-2001 Dima Dorfman <dd@FreeBSD.org>

Remove whitespace at EOL.


# 62500372 10-Jul-2001 Ruslan Ermilov <ru@FreeBSD.org>

mdoc(7) police: removed HISTORY info from the .Os call.


# 33f69855 05-Jul-2001 Ruslan Ermilov <ru@FreeBSD.org>

mdoc(7) police: add missing .Ar in SYNOPSIS.


# 24b9685c 26-Jun-2001 Mike Heffner <mikeh@FreeBSD.org>

Sync manpage and usage. Also fix bug that would always interpret a -c as a
process clear.

PR: bin/15456
MFC after: 2 weeks


# 8fe908ef 20-Nov-2000 Ruslan Ermilov <ru@FreeBSD.org>

mdoc(7) police: use the new features of the Nm macro.


# c3aac50f 27-Aug-1999 Peter Wemm <peter@FreeBSD.org>

$Id$ -> $FreeBSD$


# 397e68b2 24-Nov-1997 Philippe Charnier <charnier@FreeBSD.org>

Use .Nm ktrace instead of .Nm in SYNOPSIS section: otherwise, a newline is
missing.


# 93e0d62d 27-Apr-1997 John-Mark Gurney <jmg@FreeBSD.org>

``appears'' -> ``appeared'' (closes PR#3393, Submitted-by: Josh Gilliam)

add missing Id's
other minor clean ups


# 9bedbe6c 15-Mar-1997 Joerg Wunsch <joerg@FreeBSD.org>

Fix a security problem where the ktrace.out file could have been written
over a file owned by someone else.

Pointed out by: wosch
Reviewed by: sef, imp, proff@suburbia.net, bde


# 09ac2438 19-Sep-1996 Poul-Henning Kamp <phk@FreeBSD.org>

The userland change to the utrace(2) call.


# 16964dae 10-Aug-1996 Peter Wemm <peter@FreeBSD.org>

s/trace -C/ktrace -C/

Pointed out by: zgabor@code.hu (Zahemszky Gabor) PR#1486


# 10871c98 21-Jun-1996 James Raynard <jraynard@FreeBSD.org>

Document the fact that it only works if the trace record is a regular file.


# 9b50d902 26-May-1994 Rodney W. Grimes <rgrimes@FreeBSD.org>

BSD 4.4 Lite Usr.bin Sources