| 1 | #################################################################### |
| 2 | # Copyright (c) 2012 Ericsson |
| 3 | # |
| 4 | # All rights reserved. This program and the accompanying materials are |
| 5 | # made available under the terms of the Eclipse Public License v1.0 which |
| 6 | # accompanies this distribution, and is available at |
| 7 | # http://www.eclipse.org/legal/epl-v10.html |
| 8 | # |
| 9 | # Contributors: |
| 10 | # Bernd Hufmann - Initial API and implementation |
| 11 | #################################################################### |
| 12 | #################################################################### |
| 13 | # Scenario: Test lttng list <name> with sample outputs |
| 14 | #################################################################### |
| 15 | <SCENARIO> |
| 16 | ListInfoTest |
| 17 | |
| 18 | <COMMAND_INPUT> |
| 19 | lttng version |
| 20 | </COMMAND_INPUT> |
| 21 | <COMMAND_RESULT> |
| 22 | 0 |
| 23 | </COMMAND_RESULT> |
| 24 | <COMMAND_OUTPUT> |
| 25 | lttng version 2.1.0 - Basse Messe |
| 26 | Web site: http://lttng.org/ |
| 27 | |
| 28 | lttng is free software and under the GPL license and part LGPL |
| 29 | </COMMAND_OUTPUT> |
| 30 | |
| 31 | <COMMAND_INPUT> |
| 32 | lttng list |
| 33 | </COMMAND_INPUT> |
| 34 | <COMMAND_RESULT> |
| 35 | 0 |
| 36 | </COMMAND_RESULT> |
| 37 | <COMMAND_OUTPUT> |
| 38 | Available tracing sessions: |
| 39 | 1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928) [inactive] |
| 40 | 2) mysession (/home/user/lttng-traces/mysession-20120123-083318) [inactive] |
| 41 | |
| 42 | Use lttng list <session_name> for more details |
| 43 | </COMMAND_OUTPUT> |
| 44 | |
| 45 | <COMMAND_INPUT> |
| 46 | lttng list mysession |
| 47 | </COMMAND_INPUT> |
| 48 | <COMMAND_RESULT> |
| 49 | 0 |
| 50 | </COMMAND_RESULT> |
| 51 | <COMMAND_OUTPUT> |
| 52 | Tracing session mysession: [active] |
| 53 | Trace path: /home/user/lttng-traces/mysession-20120129-084256 |
| 54 | |
| 55 | === Domain: Kernel === |
| 56 | |
| 57 | Channels: |
| 58 | ------------- |
| 59 | - channel0: [enabled] |
| 60 | |
| 61 | Attributes: |
| 62 | overwrite mode: 0 |
| 63 | subbufers size: 262144 |
| 64 | number of subbufers: 4 |
| 65 | switch timer interval: 0 |
| 66 | read timer interval: 200 |
| 67 | output: splice() |
| 68 | |
| 69 | Events: |
| 70 | block_rq_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled] |
| 71 | block_bio_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [disabled] |
| 72 | myevent2 (type: probe) [enabled] |
| 73 | addr: 0xc0101340 |
| 74 | myevent0 (type: probe) [enabled] |
| 75 | offset: 0x0 |
| 76 | symbol: init_post |
| 77 | syscalls (type: syscall) [enabled] |
| 78 | |
| 79 | - channel1: [disabled] |
| 80 | |
| 81 | Attributes: |
| 82 | overwrite mode: 1 |
| 83 | subbufers size: 524288 |
| 84 | number of subbufers: 4 |
| 85 | switch timer interval: 100 |
| 86 | read timer interval: 400 |
| 87 | output: splice() |
| 88 | |
| 89 | Events: |
| 90 | None |
| 91 | |
| 92 | === Domain: UST global === |
| 93 | |
| 94 | Channels: |
| 95 | ------------- |
| 96 | - mychannel1: [disabled] |
| 97 | |
| 98 | Attributes: |
| 99 | overwrite mode: 1 |
| 100 | subbufers size: 8192 |
| 101 | number of subbufers: 8 |
| 102 | switch timer interval: 200 |
| 103 | read timer interval: 100 |
| 104 | output: mmap() |
| 105 | |
| 106 | Events: |
| 107 | None |
| 108 | |
| 109 | - channel0: [enabled] |
| 110 | |
| 111 | Attributes: |
| 112 | overwrite mode: 0 |
| 113 | subbufers size: 4096 |
| 114 | number of subbufers: 4 |
| 115 | switch timer interval: 0 |
| 116 | read timer interval: 200 |
| 117 | output: mmap() |
| 118 | |
| 119 | Events: |
| 120 | ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_LINE (13)) (type: tracepoint) [disabled] [with filter] |
| 121 | * (type: tracepoint) [enabled] |
| 122 | |
| 123 | </COMMAND_OUTPUT> |
| 124 | <COMMAND_INPUT> |
| 125 | lttng list mysession1 |
| 126 | </COMMAND_INPUT> |
| 127 | <COMMAND_RESULT> |
| 128 | 0 |
| 129 | </COMMAND_RESULT> |
| 130 | <COMMAND_OUTPUT> |
| 131 | Tracing session mysession1: [inactive] |
| 132 | Trace path: /home/user/lttng-traces/mysession1-20120203-133225 |
| 133 | |
| 134 | </COMMAND_OUTPUT> |
| 135 | |
| 136 | <COMMAND_INPUT> |
| 137 | lttng list -k |
| 138 | </COMMAND_INPUT> |
| 139 | <COMMAND_RESULT> |
| 140 | 0 |
| 141 | </COMMAND_RESULT> |
| 142 | <COMMAND_OUTPUT> |
| 143 | Kernel events |
| 144 | ------------- |
| 145 | sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) |
| 146 | sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) |
| 147 | sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) |
| 148 | |
| 149 | </COMMAND_OUTPUT> |
| 150 | |
| 151 | <COMMAND_INPUT> |
| 152 | lttng list -u -f |
| 153 | </COMMAND_INPUT> |
| 154 | <COMMAND_RESULT> |
| 155 | 0 |
| 156 | </COMMAND_RESULT> |
| 157 | <COMMAND_OUTPUT> |
| 158 | UST events: |
| 159 | ------------- |
| 160 | |
| 161 | PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello |
| 162 | ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint) |
| 163 | ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint) |
| 164 | field: doublefield (float) |
| 165 | field: floatfield (float) |
| 166 | field: stringfield (string) |
| 167 | |
| 168 | PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello |
| 169 | ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint) |
| 170 | ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint) |
| 171 | field: doublefield (float) |
| 172 | field: floatfield (float) |
| 173 | field: stringfield (string) |
| 174 | |
| 175 | </COMMAND_OUTPUT> |
| 176 | |
| 177 | </SCENARIO> |
| 178 | |
| 179 | |
| 180 | #################################################################### |
| 181 | # Scenario: Test "lttng list -k" with no kernel and no session daemon |
| 182 | #################################################################### |
| 183 | <SCENARIO> |
| 184 | ListInfoTestNoKernel |
| 185 | |
| 186 | <COMMAND_INPUT> |
| 187 | lttng version |
| 188 | </COMMAND_INPUT> |
| 189 | <COMMAND_RESULT> |
| 190 | 0 |
| 191 | </COMMAND_RESULT> |
| 192 | <COMMAND_OUTPUT> |
| 193 | lttng version 2.0.0 - Annedd'ale |
| 194 | Web site: http://lttng.org/ |
| 195 | |
| 196 | lttng is free software and under the GPL license and part LGPL |
| 197 | </COMMAND_OUTPUT> |
| 198 | |
| 199 | <COMMAND_INPUT> |
| 200 | lttng list |
| 201 | </COMMAND_INPUT> |
| 202 | <COMMAND_RESULT> |
| 203 | 0 |
| 204 | </COMMAND_RESULT> |
| 205 | <COMMAND_OUTPUT> |
| 206 | Currently no available tracing session |
| 207 | </COMMAND_OUTPUT> |
| 208 | |
| 209 | <COMMAND_INPUT> |
| 210 | lttng list -k |
| 211 | </COMMAND_INPUT> |
| 212 | <COMMAND_RESULT> |
| 213 | 1 |
| 214 | </COMMAND_RESULT> |
| 215 | <COMMAND_OUTPUT> |
| 216 | Error: Unable to list kernel events |
| 217 | </COMMAND_OUTPUT> |
| 218 | |
| 219 | <COMMAND_INPUT> |
| 220 | lttng list -u |
| 221 | </COMMAND_INPUT> |
| 222 | <COMMAND_RESULT> |
| 223 | 0 |
| 224 | </COMMAND_RESULT> |
| 225 | <COMMAND_OUTPUT> |
| 226 | UST events: |
| 227 | ------------- |
| 228 | |
| 229 | PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello |
| 230 | ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint) |
| 231 | ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint) |
| 232 | |
| 233 | </COMMAND_OUTPUT> |
| 234 | |
| 235 | </SCENARIO> |
| 236 | |