here is a script for if you don't want to apply this patch yourself, or you don't like the idea of losing dynamic DNS updates. it must be run as root (sudo), and started up as soon as you have connected to your VPN:
#!/bin/bash
if [ "$1" = "restore" ]; then
if [ `grep -c "# forcibly restored" /etc/resolv.conf` = "0" ]; then
cat resolv.conf.orig > /etc/resolv.conf
fi
else
# uncomment this line to set the default domain on the remote network
#echo "domain acme.com" >> /etc/resolv.conf
here is a script for if you don't want to apply this patch yourself, or you don't like the idea of losing dynamic DNS updates. it must be run as root (sudo), and started up as soon as you have connected to your VPN:
#!/bin/bash
if [ "$1" = "restore" ]; then
if [ `grep -c "# forcibly restored" /etc/resolv.conf` = "0" ]; then
cat resolv.conf.orig > /etc/resolv.conf
fi
else
# uncomment this line to set the default domain on the remote network
#echo "domain acme.com" >> /etc/resolv.conf
echo "# forcibly restored" >> /etc/resolv.conf
cp /etc/resolv.conf resolv.conf.orig
dnotify -M /etc -e `pwd`/$0 restore
fi