diff --git a/r/lightning_begin.R b/r/lightning_begin.R index 5ed5f68..65c54ed 100644 --- a/r/lightning_begin.R +++ b/r/lightning_begin.R @@ -10,7 +10,7 @@ ggplot(data=link_info, aes(x=timestamp, y=link, color=speed)) + theme_classic() -xx <- read.csv("../res/tmp_light/k.csv") +xx <- read.csv("../res/tmp_light/o.csv") xx2 <- sqldf("select packet_id,1.0 * MIN(latency) / 1000.0 as lat,way from xx group by packet_id,way") ggplot(data=xx2, aes(x=packet_id, y=lat, color=way)) + geom_line() + diff --git a/scripts/lightning-client b/scripts/lightning-client new file mode 100755 index 0000000..923210a --- /dev/null +++ b/scripts/lightning-client @@ -0,0 +1,15 @@ +#!/bin/bash +mkdir -p $6/{log,shared,res} +donar \ + -a lightning \ + -c \ + -o $6/shared/onion_services.pub \ + -l $4 \ + -p $5 \ + -b \ + -r 9000 \ +> $6/log/client-donar-stdout.log 2> $6/log/client-donar-stderr.log & +sleep 2 + +measlat -h 127.13.3.7 -p 9000 -r > /dev/null 2>&1 # Used to wait for connections +measlat -h 127.13.3.7 -p 9000 -c $1 -i $2 -s $3 > $6/log/client-measlat-stdout.log 2> $6/log/client-measlat-stderr.log diff --git a/scripts/lightning-server b/scripts/lightning-server new file mode 100755 index 0000000..7e815af --- /dev/null +++ b/scripts/lightning-server @@ -0,0 +1,14 @@ +#!/bin/bash +mkdir -p $6/{log,shared} +cd $6/shared + +donar \ + -a lightning \ + -s \ + -l $1 \ + -p $2 \ + -b \ + -e 9000 \ +> ../log/server-donar-stdout.log 2> ../log/server-donar-stderr.log & + +measlat -h 127.0.0.1 -p 9000 -l -c $3 -i $4 -s $5 > ../log/server-measlat-stdout.log 2> ../log/server-measlat-stderr.log