What is the most efficient way to get all of the external ip address of a machine with multiple nics, using python? I understand that an external server is neeeded (I have o
Use the subprocess module to connect to your usual systems tools like ifconfig or netstat:
>>> import subprocess >>> print subprocess.check_output(['ifconfig'])