Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

in/flux

macrumors newbie
Original poster
Jan 23, 2008
27
0
Hi everyone,
I'm a huge user of Terminal and other applications that involve, this and it constantly displays my computer name as new-host:

new-host:~ davejohnson$

In System Preferences > Sharing, the Computer Name is "Dave Johnson's MacBook Pro" and the local hostname is dave-johnsons-macbook-pro.local.

Screen sharing says:
Other users can access your computer at vnc://new-host.home/ or browse for "Dave Johnson's MacBook Pro".

Same with File Sharing...
Other users can access your computer at afp://new-host.home/ or browse for "Dave Johnson's MacBook Pro".

It's really bugging me. Does anyone know how to fix this? Thanks!
 
I get something similar to this if I'm connected to my school's wireless network. In Terminal it shows me as IP-address-dash-delimited-wireless~ instead of my computer name, where IP-address-dash-delimited is my IP address, separated by dashes instead of periods, followed by -wireless.

Therefore, I suspect it's related to a setting on the network you're connected to.
 
If I remember correctly the setting is on System preferences, network, advanced, wins: netbios name

Sorry if I'm wrong....

Ciao. :)
 
use the hostname command

i think the name is coming from the router by DHCP? You can use the hostname command in the terminal to change the name. Type man hostname to get help.

sudo hostname mycomputer

I think you will have to open a new terminal window to change the prompt.
 
Try the router itself:

I figured it out here - (the 'hostname' command is nice to know but didn't work)

Access your router (usually 192.168.1.1 or something) and look for the list of devices. On my Verizon Router this is under "My Network." You should be able to rename them there.

The problem I found was that my computer had two *different* IP connections to the router: one was the ethernet, the other was the wireless connection. The wireless connection had the correct name, the other one had "new-host-5". You can't have the same name for both, so rename the wireless connection to whatever, and then change the name of the ethernet connection to what you want. (Also I just disabled the Wireless connection, because I don't need both... Don't know if that was necessary though)
Hope This helps!
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.