Ask Ubuntu is a question and answer site for Ubuntu users and developers. 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

How do you change network settings?

ifconfig gives ip

(I ping it and the Ethernet card works)

I use sudo vi /etc/network/interfeces then after editing

auto eth0 
ifaces eth0 inet dhcp

I can not save it. How to save settings?

share|improve this question
1. /etc/network/interfeces => /etc/network/interfaces Is that a typo here or a typo in your command? 2. Any notice to why you can not save it? – Rinzwind Feb 7 '13 at 14:20
In command typing sudo vi /etc/network/interfeces – And Feb 7 '13 at 14:23
in settings changing to – And Feb 7 '13 at 14:24
auto eth0 ifaces eth0 inet dhcp – And Feb 7 '13 at 14:24
and cant save the file – And Feb 7 '13 at 14:25

On the fly

you can configure ip as follows

ifconfig eth0 netmask up

or static

edit /etc/network/interfaces

auto eth0
  iface eth0 inet static


/etc/init.d/networking restart
share|improve this answer
I know how it suppose to look ... I dont know how to save this file . – And Feb 8 '13 at 14:29
open the file using vi here is what you need to do vi /etc/network/interfaces then press i to enter edit mode, type the settings, then press Esc on your keyboard, later hold on shift key, and press zz (this will save and exit). – user1007727 Feb 8 '13 at 16:35

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.