title: No DNS inside lxc container
body: <p>I have an LXC debian container which run on my archlinux host. I tried to setup a bridge (lxc-bridge-nat) using wlan0 but <strong>i can't ping the outside world from my container</strong> except if i ping using the ip instead of the domain name.</p>
  
  <p>I can ping the container from the host and the host from the container. </p>
  
  <p>Here some informations:</p>
  
  <p><strong>Host: ip addr</strong> </p>
  
  <pre><code>1: lo: &lt;LOOPBACK,UP,LOWER_UP&gt; mtu 65536 qdisc noqueue state UNKNOWN 
      link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
      inet 127.0.0.1/8 scope host lo
         valid_lft forever preferred_lft forever
      inet6 ::1/128 scope host 
         valid_lft forever preferred_lft forever
  2: eth0: &lt;NO-CARRIER,BROADCAST,MULTICAST,UP&gt; mtu 1500 qdisc pfifo_fast state DOWN qlen 1000
      link/ether d4:be:d9:70:bd:e5 brd ff:ff:ff:ff:ff:ff
  3: wlan0: &lt;BROADCAST,MULTICAST,UP,LOWER_UP&gt; mtu 1500 qdisc mq state UP qlen 1000
      link/ether c4:85:08:b4:5c:e9 brd ff:ff:ff:ff:ff:ff
      inet 192.168.42.121/24 brd 192.168.42.255 scope global wlan0
         valid_lft forever preferred_lft forever
      inet6 fe80::c685:8ff:feb4:5ce9/64 scope link 
         valid_lft forever preferred_lft forever
         valid_lft forever preferred_lft forever
  4: lxc-bridge-nat: &lt;BROADCAST,MULTICAST,UP,LOWER_UP&gt; mtu 1500 qdisc noqueue state UP 
      link/ether fe:b3:b7:a2:e1:31 brd ff:ff:ff:ff:ff:ff
      inet 192.168.50.1/24 brd 192.168.50.255 scope global lxc-bridge-nat
         valid_lft forever preferred_lft forever
      inet6 fe80::b0c8:d2ff:fe73:aa50/64 scope link 
         valid_lft forever preferred_lft forever
  </code></pre>
  
  <p><strong>host: ip route</strong> </p>
  
  <pre><code>default via 192.168.42.1 dev wlan0  proto static 
  192.168.42.0/24 dev wlan0  proto kernel  scope link  src 192.168.42.121  metric 9 
  192.168.50.0/24 dev lxc-bridge-nat  proto kernel  scope link  src 192.168.50.1
  </code></pre>
  
  <p><strong>Container: ip addr</strong> </p>
  
  <pre><code>1: lo: &lt;LOOPBACK,UP,LOWER_UP&gt; mtu 65536 qdisc noqueue state UNKNOWN 
      link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
      inet 127.0.0.1/8 scope host lo
         valid_lft forever preferred_lft forever
      inet6 ::1/128 scope host 
         valid_lft forever preferred_lft forever
  10: eth0: &lt;BROADCAST,MULTICAST,UP,LOWER_UP&gt; mtu 1500 qdisc pfifo_fast state UP qlen 1000
      link/ether 00:ff:aa:00:00:01 brd ff:ff:ff:ff:ff:ff
      inet 192.168.50.2/24 brd 192.168.50.255 scope global eth0
         valid_lft forever preferred_lft forever
      inet6 fe80::2ff:aaff:fe00:1/64 scope link 
         valid_lft forever preferred_lft forever
  </code></pre>
  
  <p><strong>Container: ip route</strong></p>
  
  <pre><code>default via 192.168.50.1 dev eth0 
  192.168.50.0/24 dev eth0  proto kernel  scope link  src 192.168.50.2
  </code></pre>
  
  <p><strong>Container: /etc/resolv.conf</strong></p>
  
  <pre><code>nameserver 212.27.40.240
  nameserver 212.27.40.241
  </code></pre>