How can you get the date and time, when a particluar process starts running, along with the user name. Pls help me out in this regard. Arun DK This message posted from opensolaris.org
Arun wrote:> How can you get the date and time, when a particluar process starts running, along with the user name. > Pls help me out in this regard.search for various forms of "timestamp" (i think walltimestamp is the correct one) in the Solaris Dynamic Tracing Guide. HTH Michael -- Michael Schuster Sun Microsystems, Inc.
I think some of the more conventional observability tools like prstat(1M) and ps(1) will solve this particular problem. DTrace is best for observing the _dynamic_ behavior of the system; other tools do a better job at querying the relatively static state of the system. Adam On Mon, Jan 15, 2007 at 10:11:51PM -0800, Arun wrote:> How can you get the date and time, when a particluar process starts running, along with the user name. > Pls help me out in this regard. > > Arun DK > > > This message posted from opensolaris.org > _______________________________________________ > dtrace-discuss mailing list > dtrace-discuss at opensolaris.org-- Adam Leventhal, Solaris Kernel Development http://blogs.sun.com/ahl
Arun. How about this: #pragma D option quiet proc:::exec-success / execname == "myprog" / { printf ("Program %s started as PID %d at %Y by user %d\n", execname, pid, walltimestamp, uid); } Chip Arun wrote:> How can you get the date and time, when a particluar process starts running, along with the user name. > Pls help me out in this regard. > > Arun DK > > > This message posted from opensolaris.org > _______________________________________________ > dtrace-discuss mailing list > dtrace-discuss at opensolaris.org >