0

Looking at This Post on Multiple Networks, I was wondering how to include the ability to change the dns nameservers. At home I would use one set of information but at school I need to use a different set.

James Taylor
  • 101
  • 1

2 Answers2

1

If you use dhcp (most networks support this) it will be configured automatically. Raspbian is setup to use dhcp (or dhcpd in later Raspbian) by default.

The post you referenced tries to manually configure things; it may work if you know what you are doing, but is not necessary.

Milliways
  • 59,890
  • 31
  • 101
  • 209
0

As Milliways points out, on normal DHCP equipped networks there's no need to do this.

However, if you still want to, your nameservers are listed in /etc/resolv.conf. Beware that when you do connect as a DHCP client, this will get overwritten, so if you want to have several versions, name them something else and copy them in when you want to use them. The effect is immediate, there is no need to reboot or restart anything.

goldilocks
  • 58,859
  • 17
  • 112
  • 227
  • Sooo. No way to automatically do this? I mean, short of writing a script to switch resolv.conf files based on which SSID I am using? – James Taylor Aug 17 '15 at 20:01