Hey, I'm not Trudy! Or Ben!
November 12, 2007 11:53 AM   Subscribe

Why does my Mac appear to have other people's computer names at the command line? What's up here?

I've got a 10 month old Macbook, running Tiger.

I share a web connection with a bunch of people that live in my building. The system is administered by our resident geek, and we have wireless routers throughout, all hooked up to a big 12mb pipe. It's cheap and way fast, so, score. Also, I know most of the other people in the building, and they're cool, so I have no real worries about someone accessing my computer over the air.

However, a few times in the recent past, I've booted up the terminal and seen something weird. When I got this mac, I created a top level account that I called 'Administrator'. Some of the time, when I start Terminal, it says:

Administrators-computer:~ Dave$

'Dave' being the everyday account that I'm in most of the time. However, sometimes when I open terminal, the command prompt has changed to the name of one of my neighbour's computers (I know this because I can see their computer names in the Network folder in Finder).

For example, there is a computer on the network called 'benlaptop', and once or twice when I've logged in, my command prompt looked like:

benlaptop:~ Dave$

At the moment it looks like:

trudy2:~ Dave$

What in the heck is going on here? Is my computer somehow compromised? I've got Firewall turned on.
posted by Happy Dave to Computers & Internet (8 answers total) 4 users marked this as a favorite
That is odd.

What do the following commands show?

posted by ikkyu2 at 12:11 PM on November 12, 2007

I don't think you have anything to worry about.

Most likely: Your computer gets an IP address via DHCP, each time it starts up (or wakes from sleep, or periodically re-fetches an address). Some DNS server in your local network is mapping those addresses to names, like "benlaptop" and "trudy2".

If there is no name assigned, you get whatever is showing in your Sharing system prefs pane, which was probably set to "Administrator's Computer" by default.

You might ask your 'resident geek' to verify this theory. It sounds like the intention was that certain people would always be assigned the same address via DHCP, but that isn't actually happening, since sometimes you're getting 'their' addresses.
posted by xil at 12:16 PM on November 12, 2007 [1 favorite]

The computer name you see there is actually the hostname reported by your network connection, is the thing.

Check this thread. Basically it's a DNS issue which could be caused by the network or by your computer (I think). Most likely it's the DNS lookup table on the server side that's reporting the wrong hostname to your computer. This thread may also help?
posted by wemayfreeze at 12:17 PM on November 12, 2007

Nothing to be a afraid of. It can be a few things. Here's the most likely:

Some OSes like to register its hostname with the local DNS server when it gets a DHCP lease. I'm not sure what the timeout is for your local router, but it could be the case that your computer is not updating this information like some other type of computer (Windows, most likely). When your computer boots up and grabs its address information from DHCP, it changes the hostname to whatever its own IP resolves to.

That said, don't worry. No one's haxoring your computer. You might want to talk to the resident geek and have him turn off that annoying, annoying feature. I doubt anyone in your house is actually using it.
posted by Geckwoistmeinauto at 12:19 PM on November 12, 2007

Some DNS servers get stale entries stuck in caches, so when your computer tries to figure out its name based on its IP address, weird things like this happen. wemayfreeze has the right thread, and this entry in particular solved this on my systems.
posted by mkb at 12:41 PM on November 12, 2007

Thanks folks, all great answers - I'll have a word with the guy that owns the connection.
posted by Happy Dave at 1:07 PM on November 12, 2007

Often the whole Bonjour thing gets your computer confused. Often times when waking from sleep my computer tells me that there are multiple computers on the same network with the same name and this is only the dns getting confused. Once there were 10 of my computer all with different ip addresses.
posted by ooklala at 7:41 PM on November 12, 2007

I get this a lot on my mac...

It's kinda what xil and others said: in simple terms, Windows gets assigned an address and then tells the network what name it should use to refer to it. For some reason, Mac OS X does the opposite: it gets assigned an address and then asks the network what name it should use.

I've noticed it will change as I switch around different WiFi networks... slightly odd behaviour, but certainly nothing to worry about.
posted by jon4009 at 1:48 PM on November 17, 2007

« Older How to change your life in one easy lesson   |   How to Stuff a Wild Panini Newer »
This thread is closed to new comments.