DNS resolution got extremly slow after issuing ipconfig commands
Could your DNS server be very slow and you are clearing the local cache of results and then seeing the delay of the actual resolution / forward / lookup after running the ipconfig

You can time DNS crudely from the command line before and after the script commands:

time host www.google.com &gt;&amp; /dev/null