Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

It prints :

"Last login: Tue Mar  1 17:19:48 on ttys000 ly-lanceedemacbook:~ lancee$ "

when I login terminal on my Macbook with networking.

But sometime go like this :

"229:~ lancee$"

random numbers, Is there any hackTools working within the local area network? or means what?

share|improve this question
1  
What does echo "$PS1" say? What about grep 'PS1' ~/.profile ~/.bashrc /etc/profile? –  Dennis Williamson Mar 1 '11 at 10:46
    
If PS1 contains \! then the "random number" is the command history number. –  glenn jackman Mar 1 '11 at 15:06
add comment

migrated from stackoverflow.com Mar 1 '11 at 22:53

This question came from our site for professional and enthusiast programmers.

1 Answer

Could it be that one of the networks you visit hands out hostnames that "reflect" your IP? I´ve seen this in practice before, where the hostname auto-assigned to your machine essentially is eg. 154.local (or 154.example.com) given a DHCP-provided IP of 192.0.32.154 . Since you obviously use \h and not \H in your PS1 you would then only seem to have a random number as a hostname. Network Admins tend to do that to shorten the amount of repetitive numbers they have to type (and various other reasons).

share|improve this answer
add comment

Your Answer

 
discard

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