Raspberry Pi Dual NIC Configuration

Source: Internet
Author: User
Tags get ip

Raspberry Pi brought a network port (eth0), I bought a edup 8188CUS Junk wireless network card (said it garbage because the default can not start the listening mode, to recompile the kernel, very frustrating)

Eth0 Port I want it to connect to the Intranet 1 (192.168.2.0)

Wlan1 Port I want it to connect to the Intranet 2 (192.168.1.0)

This is how you configure the/etc/network/interfaces

192.168. 2.166  255.255. 255.0  192.168. 2.1 Auto Wlan1allow-hotplug wlan1iface wlan1 inetdhcpwpa"wifihotsphot"  WPA"xxxxx"

sudo service networking restart after reboot

Only the wlan1 is connected to the wireless network and gets the IP inet addr:192.168.1.156

But Eth0 even did not get IP, day of the dog, this is what reason, I have to configure it static IP, incredibly does not take effect?

Google later found that someone and I encountered a similar problem, he is the situation is eth0 have IP, wlan0 no IP, just the opposite of me

His solution is to execute the following two commands:

sudo ifplugd eth0--kill

sudo ifup wlan0

I happen to be the opposite of him, so my situation is:

sudo ifplugd wlan0--kill
sudo ifup eth0

In order for it to automatically take effect every time, you have to join the/etc/rc.local

Reference connection:

Http://raspberrypi.stackexchange.com/questions/8851/setting-up-wifi-and-ethernet

Raspberry Pi Dual NIC Configuration

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.