I have several orphaned/ghost community interfaces on my Mac Mini M1 2020, which is running macOS 15.1, and I’d like to clean them out. They appear in various locations, akin to within the System Settings panel, as well as within the Terminal output itself. networksetup -listallhardwareports
.
The command under reveals these community interfaces, some of which no longer physically exist.
networksetup -listallhardwareports | awk '
/^{Hardware}/{sub("{Hardware} Port: ","",$0); n=$0}
/^Gadget/{sub("Gadget: ","",$0); d=$0}
/^Ethernet/{sub("Ethernet Deal with: ","",$0); m=$0}
/^$/ && n!="" && m!="" && d!="" {
printf "%stpercentstpercentsn",d,m,n
n=m=d=""
}' | type
Output
eth0 14:98:77:64:11:0d Ethernet
eth1 14:98:77:5a:8b:1b Wi-Fi
thn1 36:32:32:20:15:00 Thunderbolt 1
thn2 36:32:32:20:15:04 Thunderbolt 2
eth4 82:03:9a:33:94:72 Ethernet Adapter (en4)
eth5 82:03:9a:33:94:73 Ethernet Adapter (en5)
usb1 00:e0:4c:68:13:10 USB 10/100/1000 LAN
In my case, en2
, en3
, en4
, en5
and en9
don’t exist. I wish to purge them. I’ve attempted to eliminate the problematic preferences file.
sudo rm /Library/Preferences/SystemConfiguration/NetworkInterfaces.plist
Despite this fact, they remain uninvited guests in our lives. Associated query with no reply: