Listing Domain Names Your Server Is Configured To Respond To

On a Red Hat EL5 server, the ethernet interfaces (IP addresses the box’ll respond to) are defined in files in /etc/sysconfig/network-scripts/. So…

cd /etc/sysconfig/network-scripts/

The IP addresses are nice in those ifcfg-eth* files, but I still haven’t memorized what they are for, especially on a host like the one I am working on. This server does a lot. Here is a one-liner to do nslookups on all those IPs:

for i in `ls ifcfg-e*`; do echo $i; cat $i | grep IP | cut -d '=' -f2 | nslookup | grep name | cut -d '=' -f2; done

Let me know in the comments if this does or does not work for you. I have not thought very long about this but am willing to update this post with your improvements.

Unrelated: please listen to Elvis Costello’s “Punch The Clock” album twenty times and thank me later.

Related: would love to see some more sys admin tricks on this blog. I’m not much of a sysadmin and I’d love to learn.

Software Parlance Spreading

It seems like every other day I notice a bit of software parlance spreading into other walks of life; such is the new ubiquity of geekdom.

For instance, in this political/financial article that has nothing to do with software, we find this sentence: “Despite a lot of rhetoric about compromise this past week, it is a feature, not a bug, of the American system of government.”

Continuing on this theme, one might further speculate that the American system of government is barely beta, or, at a minimum, not fully implemented.

Panorama theme by Themocracy