зеркало из https://github.com/microsoft/msquic.git
logging wrapper for linux (#2889)
This commit is contained in:
Родитель
80f4742d50
Коммит
939b04c0c1
|
@ -129,6 +129,14 @@ As already indicated, there are lots of ways to collect ETW traces. Feel free to
|
|||
|
||||
## Linux
|
||||
|
||||
This script wraps steps bellows
|
||||
**WARN**: This wrapper doesn't work with `./scripts/test.ps1` etc. as it is also creating lttng session internally.
|
||||
```
|
||||
./scripts/log_wrapper.sh ${Your binary}
|
||||
# e.g.
|
||||
./scripts/log_wrapper.sh ./artifacts/bin/linux/x64_Debug_openssl/msquictest --gtest_filter=Basic.*
|
||||
```
|
||||
|
||||
To start collecting a trace, you can use the following commands:
|
||||
|
||||
```
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
# This is for Linux
|
||||
|
||||
lttng destroy msquic 2> /dev/null
|
||||
|
||||
dirname="msquic_lttng"
|
||||
num=`find ./* -maxdepth 0 -name "$dirname*" | wc -l`
|
||||
mkdir $dirname$num && lttng create msqui -o=./$dirname$num && sessionCreated=$? && lttng enable-event --userspace "CLOG_*" && lttng add-context --userspace --type=vpid --type=vtid && lttng start
|
||||
if [ $? -eq 0 ]; then
|
||||
$*
|
||||
lttng stop
|
||||
fi
|
||||
|
||||
if [ $sessionCreated -eq 0 ]; then
|
||||
lttng destroy msquic
|
||||
fi
|
Загрузка…
Ссылка в новой задаче