#!/bin/bash defgw=$(netstat -nrf inet | grep default | cut -d " " -f 13 | tail -1) route delete 0.0.0.0/0 $defgw -ifscope en1 route add 0.0.0.0/0 $defgw cp /etc/resolv.conf /var/run/vpnc/resolv.conf-backup2 mv /var/run/vpnc/resolv.conf-backup /etc/resolv.conf scutil <