Remigiusz Modrzejewski
2008-Aug-05 22:54 UTC
[dtrace-discuss] Obtaining probe list requires root?
Hi, I''m working on the Tcl bindings to libdtrace. I''ve just stumbled upon something I do not quite understand: In order to use dtrace_probe_iter I need the handle to be opened with DTRACE_O_NODEV unset. Otherwise it fails with /No probe matches description/, no matter what I try to list (even when that''s trivial like dtrace:::BEGIN or a wildcard). Now, even if there''s a good technical reason for this (I guess obtaining the list actually involves accessing the device) this should read something like /Don''t have privileges to iterate probes/ or anything that''s not confusing... Kind regards, Remigiusz ''lRem'' Modrzejewski
Sébastien Bouchex Bellomié
2008-Aug-06 05:53 UTC
[dtrace-discuss] Obtaining probe list requires root?
Hi, Adding the following privileges to your user should help you : dtrace_proc dtrace_user Seb -- This message posted from opensolaris.org
Remigiusz Modrzejewski
2008-Aug-06 09:08 UTC
[dtrace-discuss] Obtaining probe list requires root?
On Wednesday 06 of August 2008 07:53:59 S?bastien Bouchex Bellomi? wrote:> Hi, > > Adding the following privileges to your user should help you : > > dtrace_proc > dtrace_userNah. I just thought, that this should be accessible to unprivileged user. Or if not, then the error message should state that, not that there are no probes matching :::entry... Kind regards, Remigiusz ''lRem'' Modrzejewski
> Nah. I just thought, that this should be accessible to unprivileged user. Or > if not, then the error message should state that, not that there are no > probes matching :::entry...The reason that no probes are available to unprivileged users is that even trivial uses of DTrace can consume extensive system resources such as memory. Initially, we wanted to take the conservative approach of disabling DTrace for all but the root user by default. Now that we''ve built up some experience with DTrace, it may be time to consider adding dtrace_proc to the default privilege set, and making sure we have the necessary resource controls. Adam -- Adam Leventhal, Fishworks http://blogs.sun.com/ahl