Editorial review of Implementation Differences in DTrace.
Need to collaborate with someone who knows more about DTrace to finish the review of the rest of this chapter. Sponsored by: iXsystems
This commit is contained in:
parent
b401c109ca
commit
ced11fe2e7
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=44464
1 changed files with 23 additions and 25 deletions
|
@ -103,52 +103,50 @@ that might make this chapter too large.
|
|||
<sect1 xml:id="dtrace-implementation">
|
||||
<title>Implementation Differences</title>
|
||||
|
||||
<para>While the &dtrace; in &os; is very similar to that found
|
||||
in &solaris;, differences exist that should be explained before
|
||||
continuing. The primary difference users will notice is that
|
||||
on &os;, &dtrace; needs to be specifically enabled. There are
|
||||
kernel options and modules which must be enabled for &dtrace; to
|
||||
work properly. These will be explained later.</para>
|
||||
<para>While the &dtrace; in &os; is similar to that found
|
||||
in &solaris;, differences do exist.
|
||||
The primary difference is that
|
||||
on &os;, &dtrace; needs to be specifically enabled by loading
|
||||
kernel modules or by compiling a custom kernel with specific
|
||||
options.</para>
|
||||
|
||||
<para>There is a <literal>DDB_CTF</literal> kernel option which
|
||||
is used to enable support for loading the <acronym>CTF</acronym>
|
||||
<para>&os; uses the <literal>DDB_CTF</literal> kernel option
|
||||
to enable support for loading <acronym>CTF</acronym>
|
||||
data from kernel modules and the kernel itself.
|
||||
<acronym>CTF</acronym> is the &solaris; Compact C Type Format
|
||||
which encapsulates a reduced form of debugging information
|
||||
similar to <acronym>DWARF</acronym> and the venerable stabs.
|
||||
This <acronym>CTF</acronym> data is added to the binaries by the
|
||||
<acronym>CTF</acronym> data is added to binaries by the
|
||||
<command>ctfconvert</command> and <command>ctfmerge</command>
|
||||
build tools. The <command>ctfconvert</command> utility parses
|
||||
<acronym>DWARF</acronym> <acronym>ELF</acronym> debug sections
|
||||
created by the compiler and <command>ctfmerge</command> merges
|
||||
<acronym>CTF</acronym> <acronym>ELF</acronym> sections from
|
||||
objects into either executables or shared libraries. More on
|
||||
how to enable this for the kernel and &os; build is
|
||||
forthcoming.</para>
|
||||
objects into either executables or shared libraries.</para>
|
||||
|
||||
<para>Some different providers exist for &os; than for &solaris;.
|
||||
Most notable is the <literal>dtmalloc</literal> provider, which
|
||||
allows tracing <function>malloc()</function> by type in the
|
||||
&os; kernel.</para>
|
||||
|
||||
<para>Only <systemitem class="username">root</systemitem> may use &dtrace; on &os;.
|
||||
This is related to security differences, &solaris; has a few
|
||||
<para>Due to security differences, only <systemitem
|
||||
class="username">root</systemitem> may use &dtrace; on &os;.
|
||||
&solaris; has a few
|
||||
low level security checks which do not yet exist in &os;. As
|
||||
such, the <filename>/dev/dtrace/dtrace</filename> is
|
||||
strictly limited to <systemitem class="username">root</systemitem> users only.</para>
|
||||
strictly limited to <systemitem class="username">root</systemitem>.</para>
|
||||
|
||||
<para>Finally, the &dtrace; software falls under &sun;'s
|
||||
<acronym>CDDL</acronym> license. The <literal>Common
|
||||
Development and Distribution License</literal> comes with &os;,
|
||||
see the
|
||||
<para>&dtrace; falls under &sun;'s Common
|
||||
Development and Distribution License
|
||||
(<acronym>CDDL</acronym>) license. To view this license on &os;,
|
||||
see
|
||||
<filename>/usr/src/cddl/contrib/opensolaris/OPENSOLARIS.LICENSE</filename>
|
||||
or view it online at
|
||||
<uri xlink:href="http://www.opensolaris.org/os/licensing">http://www.opensolaris.org/os/licensing</uri>.</para>
|
||||
|
||||
<para>This license means that a &os; kernel with the &dtrace;
|
||||
options is still <acronym>BSD</acronym> licensed; however
|
||||
the <acronym>CDDL</acronym> kicks in when the modules are
|
||||
distributed in binary form, or the binaries are loaded.</para>
|
||||
<uri xlink:href="http://www.opensolaris.org/os/licensing">http://www.opensolaris.org/os/licensing</uri>.
|
||||
While a &os; kernel with &dtrace; support
|
||||
is <acronym>BSD</acronym> licensed,
|
||||
the <acronym>CDDL</acronym> is used when the modules are
|
||||
distributed in binary form or the binaries are loaded.</para>
|
||||
</sect1>
|
||||
|
||||
<sect1 xml:id="dtrace-enable">
|
||||
|
|
Loading…
Reference in a new issue