Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
tsn-measures
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
tsn-measures
Commits
64398f3b
Commit
64398f3b
authored
Jul 29, 2020
by
Joanne Hugé
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use ip addresses from hosts file
parent
b63671b2
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
31 deletions
+22
-31
scripts/run-client
scripts/run-client
+14
-18
scripts/run-server
scripts/run-server
+8
-13
No files found.
scripts/run-client
View file @
64398f3b
...
...
@@ -13,7 +13,7 @@ interval=100000
# Default options
client_options
=
"-a -p 99 -f eth0"
qdisc_options
=
""
ip
=
"1
92.168.17
."
ip
=
"1
0.100.21
."
etf_offset
=
500
while
getopts
"bd:e:o:ghi:ptT:G"
opt
;
do
...
...
@@ -66,21 +66,17 @@ done
shift
$((
OPTIND-1
))
if
[
-n
"
$1
"
]
;
then
if
[
"
$1
"
==
"emerald"
]
;
then
ip+
=
"3"
elif
[
"
$1
"
==
"slate"
]
;
then
ip+
=
"2"
elif
[
"
$1
"
==
"onyx"
]
;
then
ip+
=
"4"
else
usage
exit
1
fi
else
ip+
=
"25"
if
[
-z
"
$1
"
]
;
then
usage
fi
board_name
=
$1
if
[
$board_name
!=
"emerald"
]
&&
[
$board_name
!=
"onyx"
]
&&
[
$board_name
!=
"slate"
]
;
then
usage
fi
board_ip
=
$(
cat
/etc/hosts |
grep
$board_name
|
awk
'{print $1}'
)
if
[
-z
"
${
use_etf
}
"
]
&&
[
-z
"
${
use_pfast
}
"
]
;
then
usage
fi
...
...
@@ -117,10 +113,10 @@ make client;
cd
$script_dir
;
if
[
-z
"
${
use_histogram
}
"
]
;
then
echo
"client
$client_options
$ip
"
;
$script_dir
/../packet-exchange/build/client
$client_options
$ip
;
echo
"client
$client_options
$
board_
ip
"
;
$script_dir
/../packet-exchange/build/client
$client_options
$
board_
ip
;
else
echo
"client
$client_options
$ip
>
$output
;mv
$output
~/"
;
$script_dir
/../packet-exchange/build/client
$client_options
$ip
>
$output
;
echo
"client
$client_options
$
board_
ip
>
$output
;mv
$output
~/"
;
$script_dir
/../packet-exchange/build/client
$client_options
$
board_
ip
>
$output
;
mv
$output
~/
;
fi
scripts/run-server
View file @
64398f3b
...
...
@@ -9,14 +9,14 @@ usage() {
# Default options
server_options
=
"-a -p 99 -f eth0"
ip
=
"1
92.168.17
."
ip
=
"1
0.100.21
."
tcpdump_interval
=
1000000
while
getopts
"b:htd:i:g:T:G"
opt
;
do
case
"
${
opt
}
"
in
b
)
use_rtt
=
1
board
=
${
OPTARG
}
board
_name
=
${
OPTARG
}
;;
d
)
use_tcpdump
=
1
...
...
@@ -51,18 +51,13 @@ done
shift
$((
OPTIND-1
))
if
[
-n
"
${
use_rtt
}
"
]
;
then
if
[
"
$board
"
==
"emerald"
]
;
then
ip+
=
"3"
elif
[
"
$board
"
==
"slate"
]
;
then
ip+
=
"2"
elif
[
"
$board
"
==
"onyx"
]
;
then
ip+
=
"4"
else
usage
exit
1
fi
server_options+
=
" -b
$ip
"
if
[
$board_name
!=
"emerald"
]
&&
[
$board_name
!=
"onyx"
]
&&
[
$board_name
!=
"slate"
]
;
then
usage
fi
board_ip
=
$(
cat
/etc/hosts |
grep
$board_name
|
awk
'{print $1}'
)
server_options+
=
" -b
$board_ip
"
fi
if
[
-z
"
${
use_histogram
}
"
]
;
then
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment