6aaron9
Posts: 15
Joined: Mon Mar 07, 2016 3:26 pm

remote access from laptop using ethernet cable

Thu Mar 17, 2016 5:56 pm

hi guys, i been setting up my rpi 3 model b with the latest rasbian os and now i want to connect it to my laptop as the display using VNC. i found lots of guides and article and i successfully done all the set up for rpi and also my laptop. I already can remote access the rpi using my laptop with an ethernet cable, but there's one thing that keeps bothering me where i cannot set a static ip for my rpi even i follow exactly the same as the guide which ask me to change the content in the etc/network/interfaces some thing like this :
iface eth0 inet static
address 192.168.1.201
netmask 255.255.255.0
gateway 192.168.1.1

any one can help?

gdt
Posts: 85
Joined: Thu Jul 19, 2012 10:19 am

Re: remote access from laptop using ethernet cable

Thu Mar 24, 2016 1:33 pm

/etc/network/interfaces with this phrase

Code: Select all

auto eth0
iface eth0 inet static
 address 192.168.1.201
 netmask 255.255.255.0
 gateway 192.168.1.1
is pretty much right. Noting that some large offices will configure their ethernet switching to reject packets from ports where there was no DHCP observed; let's assume you are not in one of those.

I wonder if this approach is optimal. It might be better to simply DHCP or use IPv6 and then annouce the service in ZeroConf announcement using the Avahi software. The package avahi-ui-utils even has a browser for VNC servers. If you use IPv6 you don't even need the DHCP server as every machine gets a link-local address on the subnet (even if there's no global IPv6 connectivity).

Return to “Networking and servers”