Posts: 9
Joined: Tue Oct 18, 2016 9:21 am

Internet problem if connected with Ethernet to PC

Tue Feb 21, 2017 12:22 pm

Good morning,
I have an Internet problem when I connect my Raspberry Pi 3 with Ethernet cable to my laptop in order not to work with a screen.

I have the Raspberry Pi 3 connected by Ethernet cable via SSH connection to my laptop. I have to do this instead of using WiFi or any other way because I am with my Thesis at the University and the connection at the University is so complex we cannot use any other way. The problem comes when we need to use Internet in the RPi in order to download any libraries or whatever, because we can´t use Internet. How could I get Internet to the RPi?
Could anyone help me with this?

We changed the config with:

Code: Select all

sudo nano /etc/dhcpcd.conf

Code: Select all

Interface eth0
static ip_address=
static routers=
static domain_name_servers=
We also configured the interfaces with:

Code: Select all

sudo nano /etc/network/interfaces

iface eth0 inet static

Thank you.

Posts: 1388
Joined: Sat Feb 04, 2017 9:39 am
Location: Germany

Re: Internet problem if connected with Ethernet to PC

Tue Feb 21, 2017 12:42 pm

You do not say which operating system has been installed on your laptop, this could be important, in the meanwhile I will assume that you are using some Windows version,

I suggest that remove everything you did as it is wrong to do so, instead you must configure "Internet Connection Sharing" on your laptop. (http://www.dummies.com/computers/operat ... windows-7/)
Do not configure static addresses, ICS will install a "mini-dhcp" server to take care of this.

There is one small inconvenience, you may have to install bonjour or use a bonjour browser (https://hobbyistsoftware.com/bonjourbrowser), to find the IP address of your raspberry. The ethernet port on your laptop will be configured by ICS with the IP-address, on your PI another address in the same range will be offered, with DNS and router pointing to which will be forwarded to the internet via your WiFi connection.
The road to insanity is paved with static ip addresses

Return to “Troubleshooting”