22

I recently bought a Raspberry Pi 2, Model B. I am intending to mostly connect to it over the local WLAN or Ethernet, using a SSH connection from my main computer.

However, right now I have a Raspberry Pi that does not yet have any software installed on it. The guides on setting up a Raspberry Pi that I've found online so far all start with connecting the machine to a HDMI-display. At this time, I do not have a display with an HDMI-connection over here.

Is it possible to install (any version of, but raspbian is probably preferred) Linux on the Raspberry Pi without needing to connect it to a HDMI display?

4
  • 9
    You can image an SD card with raspbian on any other machine; then insert the SD card in the PI and power it up. Note the Ethernet MAC address of the Pi; check your DHCP server for what IP address is assigned to the Pi; then ssh pi@${IP_ADDRESS} once it boots. Sep 2, 2016 at 17:39
  • 1
    See this question on raspberrypi.stackexchange
    – raphael
    Sep 3, 2016 at 21:13
  • You can likely buy the necessary adapter/converter for 15 EUR or so. Sep 4, 2016 at 13:04
  • @CodesInChaos in stores near me, these cost more around 40-50 EUR, which is more than I paid for the Raspberry Pi itself.
    – Qqwy
    Sep 4, 2016 at 13:31

6 Answers 6

15

Yes, you can do this at least with Arch Linux. After you build the microSD flash card filesystem on some other computer, you can boot the RasPi with that microSD card and an ethernet cable plugged in. Arch Linux will boot, acquire an IP address with DHCP. You log in as either root, or a plain user over ethernet, so you have to figure out what IP address the RasPi is listening on.

3
  • It may help you this command to figure out the IP nmap -sn 192.168.0.0/24 -oG - (assuming your lan is on 192.168.0.0/24)
    – chris-l
    Sep 2, 2016 at 22:01
  • 1
    @chris-l: Just use arp -n to show the IP->MAC table on your DHCP server. The RPi should be in there after it gets an IP and does anything with it. Or just look at the logs in your DHCP server. I you use a home router appliance, you can probably do this through the web config UI. Sep 3, 2016 at 22:17
  • @PeterCordes nice! I didn't knew that arp -n command :)
    – chris-l
    Sep 7, 2016 at 22:30
12

Raspbian from early 2016 allows ssh after second boot.

First boot from SD resizes partitions and generates sshd keys, but doesn't start ssh daemon.

Wait 5-10 minutes and powercycle RPI. Connect over ssh using default credentials.

Finding RPI's ip address is out of scope of this answer :)

Update 2017: raspbian stretch doesn't require powercycle, but needs a file 'ssh' placed in root of smaller SD card partition

1
  • 2
    About finding the RPi, modify this to fit your local subnet. nmap -oG - -p 22 192.168.0.0-255 | grep open
    – Tyler
    Sep 3, 2016 at 2:40
9

You can setup a Raspberry Pi without using a monitor/keyboard/mouse and even without a network connection using PiBakery, a blocks based setup tool that allows you to configure settings, modify files, and install software before you even write the SD card.

Once you've set what options you want, you can then write your SD card with your configurations, and your Pi will be setup on first boot.

Learn more at www.PiBakery.org

Disclaimer: I wrote PiBakery

0
3

There's a serial console available on Raspberry Pi through UART on the GPIO ports. You can read about it here on elinux.org.

Basically you connect a TTL board to GPIO and you get a serial console. Then you can use things like screen to access that console on your linux PC. Then you can configure the linux image you copied onto the SD card for further finalizations.

2

You can easily setup a RPi without a HDMI connection or a USB keyboard or mouse.

I did so using the Ubuntu minimal build from Ubuntu Pi Flavor Maker. After DDing the image to your SD card, plug the raspberry pi into your router with an Ethernet cable and wait for it to finish its first boot. Consult your router's routing table to determine the pi's IP address and ssh in. The default credentials will be ubuntu:ubuntu.

2

You can hook up an HDMI-to-VGA converter and use a regular monitor. I have successfully done that.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .