nat-netperf-server.rcS revision 1196:5e20797f314a
1#!/bin/sh
2SERVER=192.168.0.1
3CLIENT=10.0.0.2
4NATBOX=192.168.0.2
5
6echo "setting up network..."
7ifconfig lo 127.0.0.1
8ifconfig eth0 $SERVER txqueuelen 1000
9
10echo "0" > /proc/sys/net/ipv4/tcp_timestamps
11echo "0" > /proc/sys/net/ipv4/tcp_sack
12echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_rmem
13echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_wmem
14echo "5000000 5000000 5000000" > /proc/sys/net/ipv4/tcp_mem
15echo "262143" > /proc/sys/net/core/rmem_max
16echo "262143" > /proc/sys/net/core/wmem_max
17echo "262143" > /proc/sys/net/core/rmem_default
18echo "262143" > /proc/sys/net/core/wmem_default
19echo "262143" > /proc/sys/net/core/optmem_max
20echo "100000" > /proc/sys/net/core/netdev_max_backlog
21
22echo "running netserver..."
23/benchmarks/netperf/netserver
24
25echo -n "signal client to begin..."
26echo "server ready" | /usr/bin/netcat -c $NATBOX 8000
27echo "done."
28
29echo "starting bash..."
30exec /bin/bash
31