6

I would like to try to boot the Raspberry Pi 2 without the need of an SD card, anyone know how I may go about do this, if it is even possible?

  • I've added a comment to Ben's answer - you need the boot loader on an SD but aside from that you can keep everything else on the network (including the kernel.) – James Snell Dec 19 '17 at 13:17
7

No - it is not possible, in my opinion - there is nowhere to store the code needed to behave differently. Unlike PCs with network cards fitted with a bootroms/on-board flash (useful for the Linux Terminal Server Project), even if there is an inherent capability in the Arm core there is no provision to access it - remember: much of the functionality is loaded from the files on the SD card (including the GPU firmware).

It is possible, however, to construct a system that does not write to the card once it is booted as others have asked.

Update: Since I wrote this answer the situation has changed a little for the RPi3 at least (theoretically it might also apply to the really latest/last RPi2s if the revised code got into them as well) as the boot-code stored in the ROM of the video core that does the initial stage of the start-up has been tweaked to allow this as other answerers have since reported. Yippee!

I was wondering when I wrote the update above whether the boot-ROM modification was also going into the burnt-in boot-code of the RPi2B - (I had the impression that production of those was coming to an end, though) - if they are continuing to be made the later ones may have received the same update...

  • It should be very clear that the any workaround for the Pi 2 will always involve an inserted SD card , which makes this approach rather unattractive for "PXE". – flakeshake Feb 7 '17 at 11:16
  • @flakeshake - I don't see an SD with uBoot on it (and only that to bootstrap to the network) a big hardship, how come you think it's such a bad idea? – James Snell Dec 19 '17 at 13:19
9

This is from the RaspberryPi Website:

Yesterday, we introduced the first of two new boot modes which have now been added to the Raspberry Pi 3.
Today, we introduce an even more exciting addition:
network booting a Raspberry Pi with no SD card

For the Pi 1+2:

Can I use network boot with Raspberry Pi / Pi 2?
Unfortunately, because the code is actually in the boot ROM, this won’t work with Pi 1, Pi B+, Pi 2, and Pi Zero. But as with the MSD instructions, there’s a special mode in which you can copy the ‘next’ firmware bootcode.bin to an SD card on its own, and then it will try and boot from the network.

see here:
https://www.raspberrypi.org/blog/pi-3-booting-part-ii-ethernet-all-the-awesome/

5

There's some suggestion that while you still have to use an SDCard to boot, you may be able to do it with a single file (the latest bootcode.bin). The advantage of this is that the file/filesystem is only ever accessed read only making corruption a hell of a lot less likely.

Check out: https://www.raspberrypi.org/documentation/hardware/raspberrypi/bootmodes/

Which has a link to the file needed and some horrendously brief instructions.

4

Raspberry Pi 3 fully supports PXE network boot.

Per MagPi issue 43, page 10:

the Foundation had some final input for Broadcom in order to add two new features: direct USB mass-storage and PXE network boot capabilities. "Gordon rewrote the boot ROM for the chip and then provided an updated boot ROM to Broadcom, saying 'shove this in the chip, it'll work,'" Eben laughs. "And it does!"

  • That may be true, but a good answer would have a source, or maybe even an answer about the basics of how it works. – Jacobm001 Mar 4 '16 at 15:50
  • 1
    OP is asking about the Pi2 .... – flakeshake Dec 29 '16 at 9:42
3

I can't comment on Anocs answer so I'll add this twitter quote from the Director of Engineering as a source of info about PXE on the Pi3.

Basically it's not ready yet, but it is in the pipeline. Possibly for Pi2 and Pi1 as well.

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.