Skip to main content
Question

Resetting Network Adapters/Services

  • May 9, 2017
  • 0 replies
  • 0 views

Forum|alt.badge.img+5

Hey everyone,

I have seen a few old posts on resetting network adapters but looking for a better way. My current script does ok but how do you add any new detected adapters back in. Seems like my current method only adds Apples standard/default adapters.

#!/bin/sh
networksetup -createlocation TempLocation populate && networksetup -switchtolocation TempLocation
networksetup -deletelocation Automatic
networksetup -createlocation Automatic populate && networksetup -switchtolocation Automatic
networksetup -deletelocation TempLocation