| | 206 | * 先在 pcX 上面建立 bridge network (br0). |
| | 207 | {{{ |
| | 208 | # sudo vim /etc/network/interfaces |
| | 209 | }}} |
| | 210 | {{{ |
| | 211 | #!sh |
| | 212 | # This file describes the network interfaces available on your system |
| | 213 | # and how to activate them. For more information, see interfaces(5). |
| | 214 | |
| | 215 | # The loopback network interface |
| | 216 | auto lo |
| | 217 | iface lo inet loopback |
| | 218 | |
| | 219 | # The primary network interface |
| | 220 | allow-hotplug eth0 |
| | 221 | auto br0 |
| | 222 | iface br0 inet static |
| | 223 | address xxx.xxx.xxx |
| | 224 | netmask 255.255.255.0 |
| | 225 | broadcast xxx.xxx.xxx.255 |
| | 226 | gateway xxx.xxx.xxx.254 |
| | 227 | bridge_ports eth0 |
| | 228 | bridge_stp off |
| | 229 | bridge_maxwait 0 |
| | 230 | bridge_fd 0 |
| | 231 | # dns-* options are implemented by the resolvconf package, if installed |
| | 232 | dns-nameservers xxx.xxx.xxx.xxx |
| | 233 | }}} |