#!/bin/sh echo "" > /tmp/proxylist get_fetch() { http_proxy="$1:$2" export http_proxy test=`fetch -T 10 -o /dev/null http://www.planet.nl 2>&1` if [ $? = 0 ]; then echo "`echo "$test" |grep kBps | \ sed 's/^.*(//' | awk '{print $1}'` $1" >> /tmp/proxylist fi } get_fetch proxy1.wleiden.net 3128 get_fetch proxy2.wleiden.net 3128 get_fetch proxy3.wleiden.net 3128 sort -nr /tmp/proxylist > /var/db/proxylist kill `cat /var/run/pen.pid` /usr/local/bin/pen -b 30 -r -p /var/run/pen.pid -S 3 -O \ 172.31.255.1:3128 `cat /var/db/proxylist | awk '{print $2}' | tr "\n" " "`