I have connected my raspberry pi via ethernet cable to my laptop, whose wifi connection I intend to use to allow the raspberry pi to connect to the internet.

But when I turn on internet sharing I can't ssh to my raspberry pi anymore, while I can when internet sharing is turned off.

EDIT: I am sometimes able to get it connected to the internet, but it will disconnect after 30 seconds or so. When the internet is up I can ping from one to the other, but after it goes down again I can't anymore.

Pi IP:

Laptop IP:

Ok after disabling my ethernet and enabling it again I can get the raspberry pi to connect to the internet again, but it still stops working after 30 seconds to a minute

Furthermore after it disconnects the routing table on the raspberry pi takes a lot longer to load, I hope this helps someone figure out what my issue is

  • Welcome to Stack Exchange! Depending on your knowledge level this is probably too simple or too complex but... You have used the private IP address block on the wired connection between the laptop and the Pi. Can you confirm that on the wireless network, your laptop has a different IP address on a different block, which connects to a gateway router on that block? E.g. you might have a router at and the laptop is assigned on that network. Can you also mention what OS you are using on the laptop? This connection sharing concept should work, but the details are – Tai Viinikka Oct 25 '17 at 15:28

This is NORMAL. You can have EITHER ICS OR ssh access, not BOTH.

It is not impossible to have both, but this requires additional software and complex configuration on the laptop, and this is off-topic for this site. NOTHING you can do on the Pi is going to make it work.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.