0

After installing new versions of Ruby on Rails through RailsInstaller my command line prompt changed to unknownf81edfdc0983. Why is this happening, and how do I switch it back to normal? It used to display my computer's name (i.e. gabriels-MacBook-Pro). I have rebooted and restarted my terminal, and I don't think I'm running any Ruby in my profile. My computer name on System Preferences is Gabriel’s MacBook Pro. Can somebody help?

4
  • Welcome to Stack Overflow. Have you rebooted? Have you restarted terminal? Do you run any Ruby in your profile? How does your computer identify itself? Simply installing RoR should not affect your terminal at all. Your question is in danger of being closed as 'off topic'; it is border-line on topic here in my view. You might get a more receptive response on the Apple Stack Exchange site, but they'll likely want to know answers to the questions I raised. Commented Dec 26, 2012 at 18:23
  • Thanks. I will be careful when posting my questions. Let me edit the post accordingly.
    – fenomalist
    Commented Dec 26, 2012 at 18:45
  • Based on the blog referenced in joerick's answer, it is likely that your DHCP or BootP server, or the reverse DNS lookup, is yielding the unknown<MAC address> (where that MAC is unrelated to it being a Mac). So, look to your network infrastructure for an explanation. Commented Dec 26, 2012 at 18:54
  • Hi Jonathan, thank you so much for your answers. I will look more into that.
    – fenomalist
    Commented Dec 26, 2012 at 18:57

1 Answer 1

1

It's probably nothing to do with Rails, it's probably your DHCP server giving you a hostname.

You can reset it using

$ sudo hostname gabriels-MacBookPro

EDIT: See http://excitedcuriosity.wordpress.com/2007/08/24/mac-os-x-hostname-determination/

2
  • The x-ref'd blog entry is a little dated, unfortunately. On my (slightly dated) 10.7.5, the /etc/hostconfig file contains (slash for newline): # This file is going away / AFPSERVER=-NO- / AUTHSERVER=-NO- / TIMESYNC=-NO- / QTSSERVER=-NO-. Note that there is no HOSTNAME entry as mentioned in the blog. However, the name determination sequence (DHCP or BootP, Reverse DNS, System Preferences, localhost) is likely to be close to the algorithm used. Commented Dec 26, 2012 at 18:50
  • Thanks. I got it back to what it was, and thanks for giving me more insights as to what is the main cause of the change!
    – fenomalist
    Commented Dec 26, 2012 at 18:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .