surge-client.rcS revision 1648
11142Shsul@eecs.umich.edu#!/bin/sh
21142Shsul@eecs.umich.edu#
31142Shsul@eecs.umich.edu# /etc/init.d/rcS
41142Shsul@eecs.umich.edu#
51142Shsul@eecs.umich.edu
61142Shsul@eecs.umich.eduecho -n "mounting swap..."
71242Ssaidi@eecs.umich.edu/sbin/swapon /dev/hdc
81142Shsul@eecs.umich.eduecho "done."
91142Shsul@eecs.umich.edu
101142Shsul@eecs.umich.eduecho -n "setting up network..."
111142Shsul@eecs.umich.edu/sbin/ifconfig eth0 192.168.0.10 txqueuelen 1000
121142Shsul@eecs.umich.edu/sbin/ifconfig lo 127.0.0.1
131142Shsul@eecs.umich.edu
141142Shsul@eecs.umich.eduecho "1" > /proc/sys/net/ipv4/tcp_tw_recycle
151142Shsul@eecs.umich.eduecho "1" > /proc/sys/net/ipv4/tcp_tw_reuse
161142Shsul@eecs.umich.eduecho "1" > /proc/sys/net/ipv4/tcp_window_scaling
171142Shsul@eecs.umich.eduecho "0" > /proc/sys/net/ipv4/tcp_timestamps
181142Shsul@eecs.umich.eduecho "0" > /proc/sys/net/ipv4/tcp_sack
191142Shsul@eecs.umich.eduecho "15" > /proc/sys/net/ipv4/tcp_fin_timeout
201142Shsul@eecs.umich.eduecho "16384" > /proc/sys/net/ipv4/tcp_max_syn_backlog
211648Sbinkertn@umich.eduecho "262144" > /proc/sys/net/ipv4/ip_conntrack_max
221142Shsul@eecs.umich.eduecho "1024 65535" > /proc/sys/net/ipv4/ip_local_port_range
231142Shsul@eecs.umich.eduecho "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_rmem
241142Shsul@eecs.umich.eduecho "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_wmem
251142Shsul@eecs.umich.eduecho "10000000 10000000 10000000" > /proc/sys/net/ipv4/tcp_mem
261142Shsul@eecs.umich.eduecho "524287" > /proc/sys/net/core/rmem_max
271142Shsul@eecs.umich.eduecho "524287" > /proc/sys/net/core/wmem_max
281142Shsul@eecs.umich.eduecho "524287" > /proc/sys/net/core/optmem_max
291142Shsul@eecs.umich.eduecho "300000" > /proc/sys/net/core/netdev_max_backlog
301142Shsul@eecs.umich.eduecho "131072" > /proc/sys/fs/file-max
311142Shsul@eecs.umich.eduecho "done."
321142Shsul@eecs.umich.edu
331196Shsul@eecs.umich.eduecho "waiting for server..."
341196Shsul@eecs.umich.edu/usr/bin/netcat -c -l -p 8000
351142Shsul@eecs.umich.edu
361142Shsul@eecs.umich.eduecho -n "running surge client..."
371142Shsul@eecs.umich.edu/bin/bash -c "cd /benchmarks/surge && ./Surge 2 100 1 192.168.0.1 5"
381142Shsul@eecs.umich.eduecho "done."
391142Shsul@eecs.umich.edu
401142Shsul@eecs.umich.eduecho -n "halting machine"
411142Shsul@eecs.umich.edum5 exit
421142Shsul@eecs.umich.edu
431142Shsul@eecs.umich.eduecho -n "starting bash shell..."
441142Shsul@eecs.umich.edu/bin/bash
45