Headless connection with a laptop - please help to set up
Can you please help me,
I have Raspberry PI model B and I set up it for the first time.
I don't have a monitor, neither a usb keyboard, so I need to connect it to my laptop through headless connection.
I used these how-to: https://www.youtube.com/watch?v=Ioih6MHNNqc and https://pihw.wordpress.com/guides/direc ... onnection/
I set ip address for Raspberry PI 169.254.1.1 and my laptop has no fixed IP (set up automatically).
(I have Linux Mint)
It can't set up direct connection -- I mean no network connection.
Can you please advice me what should I do to set it up?
I have Raspberry PI model B and I set up it for the first time.
I don't have a monitor, neither a usb keyboard, so I need to connect it to my laptop through headless connection.
I used these how-to: https://www.youtube.com/watch?v=Ioih6MHNNqc and https://pihw.wordpress.com/guides/direc ... onnection/
I set ip address for Raspberry PI 169.254.1.1 and my laptop has no fixed IP (set up automatically).
(I have Linux Mint)
It can't set up direct connection -- I mean no network connection.
Can you please advice me what should I do to set it up?
-
- Posts: 258
- Joined: Sat Oct 24, 2015 1:50 pm
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
Try adding
into /etc/network/interfaces on your Linux machine
Code: Select all
auto eth0
iface eth0 inet
static address 169.254.1.2
netmask 255.255.0.0
Re: Headless connection with a laptop - please help to set u
Thank you, I planned to use ssh, but at first I need just to set up a network connection, for now it doesn't work
Re: Headless connection with a laptop - please help to set u
The best way to set up a static IP address is to set it on your router. That way if you ever take the RaspPi away from home it will still work. If you set it on the RaspPi and you put it on a different network, you won't be able to talk to it.
Also, of course, it has to be wired Ethernet. Until you configure the SSID and password you can't use WiFi.
Are you using Raspbian? If so, ssh should just work; there's nothing to do to enable it. If you are using NOOBS, then I don't believe you can boot it headless the first time.
Also, of course, it has to be wired Ethernet. Until you configure the SSID and password you can't use WiFi.
Are you using Raspbian? If so, ssh should just work; there's nothing to do to enable it. If you are using NOOBS, then I don't believe you can boot it headless the first time.
Re: Headless connection with a laptop - please help to set u
Yeah, I use Raspbian and I use wired Ethernet connection: Raspberry PI - laptop.
The thing is -- I don't have an access to the router.
I understand that if I take it somewhere else with these IP settings, it wouldn't work.
The thing is -- I don't have an access to the router.
I understand that if I take it somewhere else with these IP settings, it wouldn't work.
Re: Headless connection with a laptop - please help to set u
I tried it, aslo tried with a closer mask: 255.255.255.0, but nothing. (I tried rebooting as well)mattmiller wrote:Try addinginto /etc/network/interfaces on your Linux machineCode: Select all
auto eth0 iface eth0 inet static address 169.254.1.2 netmask 255.255.0.0
Anyway, thank you.
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
JFI You should be using 255.255.0.0 for 169.254.xxx.yyy addresses
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
What does ifconfig show on your Linux machine with Pi plugged in then ?
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
How/where have you setup your Pi for 169.254.1.1 ?
Please paste the file here
Please paste the file here

Re: Headless connection with a laptop - please help to set u
Here are both files
- Attachments
-
- files.zip
- (329 Bytes) Downloaded 29 times
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
@rurwin - I think you mis-read the OP

Well I call it reserved addressing not static when you do that on a router but tomato tomatoThe best way to set up a static IP address is to set it on your router.

em yes but that's not what the OP is trying to doThat way if you ever take the RaspPi away from home it will still work
he is just trying to use link-local Ip addressing between a machine and a Pi - similar to my request for static fallback viewtopic.php?f=66&t=134138&p=895278#p895278If you set it on the RaspPi and you put it on a different network, you won't be able to talk to it.
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
I'm getting an error trying to open your zip 

Re: Headless connection with a laptop - please help to set u
once again
- Attachments
-
- files.tar.gz
- (370 Bytes) Downloaded 27 times
Re: Headless connection with a laptop - please help to set u
And here's my ifconfig:
ketka@ketka:~ > ifconfig
eth0 Link encap:Ethernet HWaddr b8:88:e3:3b:03:e9
inet6 addr: fe80::ba88:e3ff:fe3b:3e9/64 Scope:Посилання
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Прийнято пакунків:37 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:275 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
Прийнято байтів:10489 (10,4 KB) Передано байтів:56650 (56,6 KB)
lo Link encap:Локальна петля (Loopback)
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Хост
UP LOOPBACK RUNNING MTU:65536 Metric:1
Прийнято пакунків:1075 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:1075 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
Прийнято байтів:91388 (91,3 KB) Передано байтів:91388 (91,3 KB)
wlan0 Link encap:Ethernet HWaddr c0:14:3d:dc:32:c3
inet addr:192.168.0.102 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::c214:3dff:fedc:32c3/64 Scope:Посилання
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Прийнято пакунків:4989 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:5024 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
Прийнято байтів:1829651 (1,8 MB) Передано байтів:1510792 (1,5 MB)
it's with ukrainian language, but the idea is: only errors in transmitting and no IPv4 is shown on eth0
ketka@ketka:~ > ifconfig
eth0 Link encap:Ethernet HWaddr b8:88:e3:3b:03:e9
inet6 addr: fe80::ba88:e3ff:fe3b:3e9/64 Scope:Посилання
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Прийнято пакунків:37 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:275 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
Прийнято байтів:10489 (10,4 KB) Передано байтів:56650 (56,6 KB)
lo Link encap:Локальна петля (Loopback)
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Хост
UP LOOPBACK RUNNING MTU:65536 Metric:1
Прийнято пакунків:1075 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:1075 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
Прийнято байтів:91388 (91,3 KB) Передано байтів:91388 (91,3 KB)
wlan0 Link encap:Ethernet HWaddr c0:14:3d:dc:32:c3
inet addr:192.168.0.102 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::c214:3dff:fedc:32c3/64 Scope:Посилання
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Прийнято пакунків:4989 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:5024 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
Прийнято байтів:1829651 (1,8 MB) Передано байтів:1510792 (1,5 MB)
it's with ukrainian language, but the idea is: only errors in transmitting and no IPv4 is shown on eth0
Re: Headless connection with a laptop - please help to set u
It's not clear to me what you are doing that isn't working. When you supposedly boot the pi, are you then going to the windows machine and attempting to ping the pi with the supposed address it has? I just tested this with 169.254 addresses on Ubuntu and Raspian Wheezy and they just automatically are there. How do you know that the pi has booted if you are headless?ketochka wrote:I tried it, aslo tried with a closer mask: 255.255.255.0, but nothing. (I tried rebooting as well)mattmiller wrote:Try addinginto /etc/network/interfaces on your Linux machineCode: Select all
auto eth0 iface eth0 inet static address 169.254.1.2 netmask 255.255.0.0
Anyway, thank you.
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
Well we need to get your Linux machine to set the IP
try this in /etc/network/interfaces instead of my earlier suggestion
try this in /etc/network/interfaces instead of my earlier suggestion
Code: Select all
iface eth0 inet static
address 169.254.1.2
netmask 255.255.0.0
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
no 1 - He's using Linux Mint on other computer - not windowsIt's not clear to me what you are doing that isn't working
Lots of Linux machines don't default to a 169.254 address (they should - but they don't)

So he needs to force static on Linux Mint 1st before we get into what's happening on Pi
Re: Headless connection with a laptop - please help to set u
Oh, now eth0 just dissapeared.
________________________
And here's what in interfaces.txt:
# interfaces(5) file used by ifup(8) and ifdown(8)
iface eth0 inet static
address 169.254.1.2
netmask 255.255.0.0
___________________
ketka@ketka:~ > ifconfig
lo Link encap:Локальна петля (Loopback)
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Хост
UP LOOPBACK RUNNING MTU:65536 Metric:1
Прийнято пакунків:579 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:579 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
Прийнято байтів:46495 (46,4 KB) Передано байтів:46495 (46,4 KB)
wlan0 Link encap:Ethernet HWaddr c0:14:3d:dc:32:c3
inet addr:192.168.0.102 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::c214:3dff:fedc:32c3/64 Scope:Посилання
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Прийнято пакунків:629 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:821 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
Прийнято байтів:187429 (187,4 KB) Передано байтів:122536 (122,5 KB)
________________________
And here's what in interfaces.txt:
# interfaces(5) file used by ifup(8) and ifdown(8)
iface eth0 inet static
address 169.254.1.2
netmask 255.255.0.0
___________________
ketka@ketka:~ > ifconfig
lo Link encap:Локальна петля (Loopback)
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Хост
UP LOOPBACK RUNNING MTU:65536 Metric:1
Прийнято пакунків:579 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:579 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
Прийнято байтів:46495 (46,4 KB) Передано байтів:46495 (46,4 KB)
wlan0 Link encap:Ethernet HWaddr c0:14:3d:dc:32:c3
inet addr:192.168.0.102 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::c214:3dff:fedc:32c3/64 Scope:Посилання
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Прийнято пакунків:629 помилок передачі:0 пропущено:0 перерозхід:0 кадри:0
TX packets:821 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
Прийнято байтів:187429 (187,4 KB) Передано байтів:122536 (122,5 KB)
Last edited by ketochka on Sat Jan 30, 2016 1:36 am, edited 1 time in total.
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
try
from terminal
Code: Select all
ifup eth0
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
If that works try this in /etc/network/interfaces
Code: Select all
auto eth0
iface eth0 inet static
address 169.254.1.2
netmask 255.255.0.0
Re: Headless connection with a laptop - please help to set u
ketka ketka # ifup eth0
ifup: interface eth0 already configured
ketka ketka #
ifup: interface eth0 already configured
ketka ketka #
Re: Headless connection with a laptop - please help to set u
oh, yeah!
you are a master!
it works
Thank you so much,
and wish you all the best.
you are a master!
it works

Thank you so much,
and wish you all the best.
-
- Posts: 2247
- Joined: Thu Feb 05, 2015 11:25 pm
Re: Headless connection with a laptop - please help to set u
Phew 
Good night

Good night
