The followings are procedures to change settings for internet connection, using ifconfig. I use several different TCIP/IP envirnments for my work and at home.
add name server addr, ie, DNS server value and DNS domain to the file as shown below.
In order to use a laptop at home and in the office. I use the following settings.
$ emacs /etc/network/interfaces
# The loopback network interface
auto lo
iface lo inet loopbac
iface home inet static
address www.zzz.xxx.qqq
netmask 255.sss.ttt.q
gateway www.zzz.xxx.q
dns-search *.zzz.co.jp
dns-nameservers www.zzz.xxx.qq