Unknown user in terminal

Posted by Giles B on Super User See other posts from Super User or by Giles B
Published on 2012-09-05T14:52:21Z Indexed on 2012/09/07 9:40 UTC
Read the original article Hit count: 427

Filed under:
|
|

Im having a strange problem with the terminal in OS X.

When I open the terminal the username at the command prompt is:

unknown-04-0c-ce-e3-0d-c2: ~

I can't pinpoint when this first started or why unfortunately. I usually use iTerm for web development purposes but this also occurs in the normal OS X Terminal app.

Any ideas/help would be really appreciated.

Thanks

Update: Thanks to @fayadfami and @aliasgar for the correct answers and steering me in the right direction. Also this forum post helped http://forums.macrumors.com/showthread.php?t=152407 The extract from the right post:

Having run into the exact same issue myself, and having come across this thread while >attempting to figure it out, I thought I'd post the answer.

OS X is initially setting your hostname to what's set for your Computer Name in Sharing; >however, if you're set up for DHCP and you match a current lease on your DHCP server (i.e., >match the IP address of another recent user), OS X will then set your hostname to whatever >the DHCP server currently has for that lease.

This freaked me out incredibly at first, as I had just reformatted (having just purchased my >first Mac and wanting to see how the installer worked) and knew I had not yet changed the >Computer Name in Sharing -- yet my system hostname at the Terminal prompt was indeed changed >to what I had previously set, pre-format. I grepped around, not finding the name anywhere >save log entries; I thought either the format didn't actually properly wipe everything, or I >was losing my mind. Finally I logged into my router (it's a Linksys WRT54GS running >OpenWRT), and found the hostname in the current leases file. I then manually set my Mac's IP >to something different, and volia! -- the hostname was back to what I expected.

I hope this helps save someone from the same paranoia I went through.

© Super User or respective owner

Related posts about osx

Related posts about mac