I'm using debian 10 as my daily so these are *nix commands. Mac should work with these too but you're on your own if you're using Windows. Goal for me is to make a headless raspberry pi I can SSH into and connect to my network using Ethernet. You should be comfortable in command line if you choose to follow this guide.
- Go to https://www.raspberrypi.org/downloads/raspbian and download Raspbian lite archive
unzip
the image- Plug in sdcard. Run
lsblk
to see drives and mount points. Likely, the sdcard will show up in/dev/sda
or /dev/sdb and may have some partitions like/dev/sda1
and/dev/sda2
. - If partitions are mounted, unmount all of them. Ex:
umount /dev/sda1
andumount /dev/sda2
- Copy the raspbian image to the sdcard with
sudo dd if=RASPBIAN_IMAGE_FILE.img of=/dev/sda bs=4M
- Run
sync
to ensure the written contents are flushed - OPTIONAL: To start ssh server on boot, Unplug sdcard and reinsert to remount new partitions. You'll have two with raspbian.