Convert `ifconfig` handling code to use the Linux `ip` command.