Ask Different is a question and answer site for power users of Apple hardware and software. 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

When I open my terminal it shows this:

wpa-2-602:~ david$

I just curious what the wpa-2-602 means? "david" is my user name, and sometimes it was something else. What makes it change?

share|improve this question
up vote 6 down vote accepted

That's based on the PS1 variable set in Bash's initialization. Yours appears to be the default, which is your computer's name, followed by a colon, then the current directory (in your example, that'd be the home directory for your computer [~]), then your username (david).

Here is an article about customizing your PS1, and there are plenty of questions both here and over at Super User about changing and fixing it.

share|improve this answer
The computer's name will be used unless the dhcp client get's another host name when connecting to a network. My guess is that the OP is noticing the name change when he's on a network whose dhcp server actually responds to the host name request from his computer. – ephsmith Jul 12 '12 at 1:14
Any particular complaint from the downvoter? – CajunLuke Jul 12 '12 at 18:54

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.