coder1313514512456
asked on
Bash: Mac OS X 10.6.8/SL: How does Network Diagnostics fix?
I have a very easy bash Macintosh network question for you.
I'm currently in a situation where I have to unplug and replug in a Mac's ethernet cable. (Because of some network configuration which is unrelated to this question.)
When I plug the ethernet back into the Mac, I've found that the fastest way to get the OS to respond to the new network connection is to go to:
Preferences > Network > Ethernet (n) > Assist Me > Diagnostics > Ethernet > Continue.
In which case, a dialog responds that the internet connection appears to be operating. (And now it is.)
My question is, this is doing this very quickly and surely there must be some bash script I can write that can duplicate this simple procedure.
I can't simply do a
$ sudo ifconfig en0 up
(Macs use en0 instead of enth0 or something.)
What am I missing? This should be a very simple thing to do.
I'm currently in a situation where I have to unplug and replug in a Mac's ethernet cable. (Because of some network configuration which is unrelated to this question.)
When I plug the ethernet back into the Mac, I've found that the fastest way to get the OS to respond to the new network connection is to go to:
Preferences > Network > Ethernet (n) > Assist Me > Diagnostics > Ethernet > Continue.
In which case, a dialog responds that the internet connection appears to be operating. (And now it is.)
My question is, this is doing this very quickly and surely there must be some bash script I can write that can duplicate this simple procedure.
I can't simply do a
$ sudo ifconfig en0 up
(Macs use en0 instead of enth0 or something.)
What am I missing? This should be a very simple thing to do.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Early indications are that it seems to work like a champ.
Thanks again, don't know why I didn't think of bringing it down first.
Thanks again, don't know why I didn't think of bringing it down first.
ASKER
Bring the interface down before you bring it up. Right.
ASKER