Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Possible Duplicate:
sudo: unable to resolve host (none)

My Ubuntu 12.04 LTS lost Internet connection. It just acts like it has lost Internet connection.

When I go to terminal in says: user@(none). When I run any sudo command, it says

sudo: unable to resolve host (none)

If I try Firefox, nothing happens. But when I try pinging, it responds fine (but only if it has been pointed to a IP address).

share|improve this question

marked as duplicate by jokerdino, Ringtail, Rinzwind, hhlp, fossfreedom Nov 30 '12 at 9:48

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1 Answer 1

up vote 2 down vote accepted

Please, enter this line into the terminal:

nano /etc/hostname

And tell me what it says :)

share|improve this answer
    
Actually it is blank =D –  DaGhostman Dimitrov Nov 28 '12 at 12:55
    
Then, restart your computer, enter the "recovery mode" in your start-up, and when you are in there, select the option where you can use the command line as "root". From there (note this down), you just type: nano /etc/hostname then, when you have, enter a pc name / hostname like "computer", and exit with ctrl+x or what it says, to save it. reboot, and try the things again :P –  denNorske Nov 28 '12 at 12:59
1  
Thank you mate ! –  DaGhostman Dimitrov Nov 28 '12 at 13:17
    
Did the network work now? If so, no problem! –  denNorske Nov 28 '12 at 13:23
    
Yeah the weird part is that the wired network now shows as Auto Ethernet but works perfectly =D –  DaGhostman Dimitrov Nov 28 '12 at 13:31

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