Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am using a macBook Pro I enter: new-host-2:~ Justin$ hostname And it returns: new-host-2.home

Why is this when it says in setting/sharing my computers name is "Justin's macbook pro" and computers on my local network can access my computer at "Justins-MacBook-Pro.local"

The tutorial I am reading says that the command should return one of the "many" names of your computer, I am assuming this is one, but if it is where else on my computer can I find this name or a list of names for my computer? And why did it not return "Justins-MacBook-Pro.local", this format was what the tutorials computer returned?

share|improve this question
This might be helpful: superuser.com/q/357159/151431 – terdon Jan 15 '14 at 1:44
up vote 2 down vote accepted

MAC OS X maintains at least three different names for different usages (ComputerName, HostName and LocalHostName).

You can set the command line hostname to a different value with this command:

scutil --set HostName "justins"
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.