NAME | SYNOPSIS | DESCRIPTION | OPTIONS | OPTIONS (specific to Xen) | OPTIONS (specific to System z) | ENVIRONMENT | FILES | VERSION | SEE ALSO | COLOPHON

OPCONTROL(1)               General Commands Manual              OPCONTROL(1)

NAME         top

       opcontrol - control OProfile profiling

SYNOPSIS         top

       opcontrol [ options ]

DESCRIPTION         top

       opcontrol can be used to start profiling, end a profiling session,
       dump profile data, and set up the profiling parameters.

OPTIONS         top

       --help / -?
              Show help message.

       --version / -v
              Show version.

       --list-events / -l
              Shows the monitorable events.

       --init Load the OProfile module if required and make the OProfile
              driver interface available.

       --setup
              Followed by list options for profiling setup. Store setup in
              ~root/.oprofile/daemonrc. Optional.

       --status
              Show configuration information.

       --start-daemon
              Start the oprofile daemon without starting profiling.

       --start / -s
              Start data collection with either arguments provided by
              --setup or with information saved in ~root/.oprofile/daemonrc.

       --dump / -d
              Force a flush of the collected profiling data to the daemon.

       --stop / -t
              Stop data collection.

       --shutdown / -h
              Stop data collection and kill the daemon.

       --reset
              Clear out data from current session, but leaves saved
              sessions.

       --save=sessionname
              Save data from current session to sessionname.

       --deinit
              Shut down daemon. Unload the oprofile module and oprofilefs.

       --session-dir=dir_path
              Use sample database out of directory dir_path instead of the
              default location (/var/lib/oprofile).

       --buffer-size=num
              Set kernel buffer to num samples. The buffer watershed needs
              to be tweaked when changing this value.  Rules:  A non-zero
              value goes into effect after a '--shutdown/start' sequence.  A
              value of zero sets this parameter back to default value, but
              does not go into effect until after '--deinit/init' sequence.

       --buffer-watershed=num
              Set kernel buffer watershed to num samples. When buffer-size -
              buffer-watershed free entries remain in the kernel buffer,
              data will be flushed to the daemon.  Most useful values are in
              the range [0.25 - 0.5] * buffer-size.  Same rules as defined
              for buffer-size.

       --cpu-buffer-size=num
              Set kernel per-cpu buffer to num samples. If you profile at
              high rate it can help to increase this if the log file show
              excessive count of sample lost cpu buffer overflow. Same rules
              as defined for buffer-size.

       --event / -e [event|"default"]
              Specify an event to measure for the hardware performance
              counters, or "default" for the default event. The event is of
              the form "CPU_CLK_UNHALTED:30000:0:1:1" where the numeric
              values are count, unit mask, kernel-space counting, user-space
              counting, respectively.  Note that this over-rides all
              previous events selected; if you want to profile with two or
              more events simultaneously, you must specify them on the same
              opcontrol invocation. You can specify unit mask values using
              either a numerical value (hex values must begin with "0x") or
              a symbolic name (if the name=<um_name> field is shown in the
              ophelp output). For some named unit masks, the hex value is
              not unique; thus, OProfile tools enforce specifying such unit
              masks value by name.

       --separate / -p [none,lib,kernel,thread,cpu,all]
              Separate samples based on the given separator. 'lib' separates
              dynamically linked library samples per application. 'kernel'
              separates kernel and kernel module samples per application;
              'kernel' implies 'library'. 'thread' gives separation for each
              thread and task.  'cpu' separates for each CPU. 'all' implies
              all of the above options and 'none' turns off separation.

       --callgraph / -c [#depth]
              Enable callgraph sample collection with a maximum depth. Use 0
              to disable callgraph profiling. This option is available on
              x86 using a 2.6+ kernel with callgraph support enabled.  It is
              also available on PowerPC using a 2.6.17+ kernel.

       --image / -i [name,name...|"all"]
              Only profile the given absolute paths to binaries, or "all" to
              profile everything (the default).

       --vmlinux=file
              vmlinux kernel image.

       --no-vmlinux
              Use this when you don't have a kernel vmlinux file, and you
              don't want to profile the kernel.

       --verbose / -V [options]
              Be verbose in the daemon log. This has a high overhead.

       --kernel-range=start,end
              Set kernel range vma address in hexadecimal.

OPTIONS (specific to Xen)         top

       --xen=file
              Xen image

       --active-domains=<list>
              List of domain ids participating in a multi-domain profiling
              session. If more than one domain is specified in <list> they
              should be separated using commas. This option can only be used
              in domain 0 which is the only domain that can coordinate a
              multi-domain profiling session. Including domain 0 in the list
              of active domains is optional. (e.g. --active-domains=2,5,6
              and --active-domains=0,2,5,6 are equivalent)

OPTIONS (specific to System z)         top

       --s390hwsampbufsize=num
              Number of 2MB areas used per CPU for storing sample data.  The
              best size for the sample memory depends on the particular
              system and the workload to be measured.  Providing the sampler
              with too little memory results in lost samples. Reserving too
              much system memory for the sampler impacts the overall
              performance and, hence, also the workload to be measured.

ENVIRONMENT         top

       No special environment variables are recognised by opcontrol.

FILES         top

       /root/.oprofile/daemonrc
              Configuration file for opcontrol

       /var/lib/oprofile/samples/
              The location of the generated sample files.

VERSION         top

       This man page is current for oprofile-1.0.0git.

SEE ALSO         top

       /usr/local/share/doc/oprofile/, oprofile(1)

COLOPHON         top

       This page is part of the oprofile (a system-wide profiler for Linux)
       project.  Information about the project can be found at 
       ⟨http://oprofile.sourceforge.net/news/⟩.  If you have a bug report for
       this manual page, see ⟨http://oprofile.sourceforge.net/bugs/⟩.  This
       page was obtained from the project's upstream Git repository ⟨git⟩ on
       2017-07-05.  If you discover any rendering problems in this HTML ver‐
       sion of the page, or you believe there is a better or more up-to-date
       source for the page, or you have corrections or improvements to the
       information in this COLOPHON (which is not part of the original man‐
       ual page), send a mail to man-pages@man7.org

4th Berkeley Distribution     Sun 20 July 2014                  OPCONTROL(1)