mirror of
https://github.com/zrepl/zrepl.git
synced 2024-11-22 00:13:52 +01:00
Updated Debugging (markdown)
parent
576cf0c19d
commit
2c14ad8607
36
Debugging.md
36
Debugging.md
@ -7,9 +7,39 @@
|
||||
### Tasks:
|
||||
|
||||
* Reduce network bandwidth between the VMs:
|
||||
* Use https://github.com/thombashi/tcconfig instead of Linux `tc`
|
||||
* `tcset eth0 --rate 100Mbps --direction incoming --src-network 192.168.124.233/32 --overwrite`
|
||||
|
||||
* Use https://github.com/thombashi/tcconfig instead of Linux `tc`
|
||||
* `tcset eth0 --rate 100Mbps --direction incoming --src-network 192.168.124.233/32 --overwrite`
|
||||
* Fake zfs errors
|
||||
* Create a wrapper shell script and add its director to the zrepl daemon's `PATH`
|
||||
* Example Script: <details>
|
||||
```
|
||||
root@zrepl-dev-debian-2:[~]: cat mockpath/zfs
|
||||
#!/usr/bin/env bash
|
||||
set -eu
|
||||
args=("$@")
|
||||
|
||||
ZREPL_MOCK_ZFS_PATH=/usr/local/sbin/zfs
|
||||
|
||||
|
||||
#if echo "${args[@]}" | egrep 'list.*snapshot' > /dev/null; then
|
||||
# echo "sleeping ${args[@]}" >> /tmp/mocklog
|
||||
# sleep 700
|
||||
#fi
|
||||
if echo "${args[@]}" | egrep 'recv -s' 2>&1 >/dev/null; then
|
||||
echo foo
|
||||
echo bar 1>&2
|
||||
sleep 10
|
||||
dd bs=1M count=1
|
||||
exit 23
|
||||
#echo "unenced is blocked to be received by this mock" 1>&2
|
||||
#exit 23
|
||||
sleep 1
|
||||
fi
|
||||
|
||||
|
||||
exec "$ZREPL_MOCK_ZFS_PATH" "${args[@]}"
|
||||
```
|
||||
</details>
|
||||
|
||||
## Memory Leaks & Goroutine Leaks
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user