-
Install docker
-
Install proect dependencies by running
bash install.sh
. -
Fix docker permissions with next commands:
sudo groupadd docker
sudo usermod -aG docker $USER
newgrp docker
-
Build ubuntu_delay image with:
docker build -t ubuntu_delay ./scripts/resources
-
See Core dumps section
-
See Debugging section
-
See Examples section
-
See docs folder for more start examples
Here can be situations, when something went wrong and you should have informations about this situations, core dumps will help you.
For generating core dumps, you should write core pattern by next command on your host: echo '/tmp/core.%t.%e.%p.%P' | sudo tee /proc/sys/kernel/core_pattern
.
For permanent storing core_pattern (it will be changed for next computer start), you should write rule kernel.core_pattern=/tmp/cores/core.%t.%e.%p.%P
to file /etc/sysctl.conf
.
For getting just backtrace you can use one of next methods:
-
Use
docker exec -it echonode{n} /bin/bash
to get access to container and rungdb -p $PID command
. -
You can get access to process inside container from your host using nsenter:
sudo nsenter -t $HPID -m -p gdb -p $PID
, where$HPID
- it is host pid and$PID
- it is pid inside container.
This methods give you backtrace, also there is available to put breakpoints, but no source code available. For fully debuggin use next method: -
run
gdb /path/to/echonode
and inside gdb run next command(gdb) target remote | docker exec -i echonode{n} gdbserver - --attach $PID
, this give you opportunity to debug process inside container with source code.
Starting 25 nodes per server:
./start_deployer.py -n 25 -e ./echo_node -i ubuntu_delay -sn 0 -hi '{"192.168.9.41":25, "192.168.9.42":25, "192.168.9.43":25}' -cc 100 -u "url_of_slack_app"
./start_deployer.py -n 25 -e ./echo_node -i ubuntu_delay -sn 1 -hi '{"192.168.9.40":25, "192.168.9.42":25, "192.168.9.43":25}' -cc 100 -u "url_of_slack_app"
./start_deployer.py -n 25 -e ./echo_node -i ubuntu_delay -sn 2 -hi '{"192.168.9.40":25, "192.168.9.41":25, "192.168.9.43":25}' -cc 100 -u "url_of_slack_app"
./start_deployer.py -n 25 -e ./echo_node -i ubuntu_delay -sn 3 -hi '{"192.168.9.40":25, "192.168.9.41":25, "192.168.9.42":25}' -cc 100 -u "url_of_slack_app"
Starting sender:
./start_sender.py -hi '{"192.168.9.40":25, "192.168.9.41":25, "192.168.9.42":25, "192.168.9.43":25}' -txs 200
More information about options you can get with --help
command, it available on all scripts, or see docs folder.