I'm very new to python, and my google-fu has failed to locate an answer to
the following:

How can I find all of the (ipv4) addresses that are currently up on a host?

I realize I can call ifconfig and then munge the output with awk, but that
seems messy, and before I tried that I though I would ask around.

To give a bit more information, I'm writing a script that will use the ip
address assigned to the wifi interface to determine location (this is on a
Mac) and then mount network drives appropriate to the location. If anyone
has a better idea how to do this, I'd be happy to hear them.

Thanks in advance!

Scott Newton
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to