Raspberry PI

Install Raspbian Buster Lite in your Raspberry Pi

ADVICE: From June 2020, Raspberry PI Foundation decided to fork its own Raspberry PI OS from Raspbian. This means that, from this date, the official “Raspberry PI OS Lite” can be installed with following procedure: https://peppe8o.com/install-raspberry-pi-os-lite-in-your-raspberry-pi/. All of my projects should work without issues with that new OS directly supported by Raspberry PI Foundation

Raspbian remains a free OS, supported by community. It official website is: https://www.raspbian.org.

Using Raspberry for a number of home applications is something fantastic. But Raspberry comes with a low performance hardware, so many times you could need to use as resources as possible dedicated to your applications, instead wasting them for apps that you don’t need (for example desktop environment).
Usually Raspberry kit comes with NOOBS pre-installed inside SD card, but you can also choose to install directly a minimal core and use it from your external PC by SSH.
In this guide I will show you hot to install Raspbian Buster Lite, the official Raspberry Foundation OS.

NOTE: if you have already Raspbian Stretch Lite installed and want to upgrade, please go to Upgrade paragraph later in this article.

What do you need

HARDWARE

As usual, I suggest adding from now to your favourite e-commerce shopping cart all the needed hardware, so that at the end you will be able to evaluate overall costs and decide if to continue with the project or remove them from the shopping cart. So, hardware will be only:

I strongly suggest to evaluate to buy a case with cooling system (fans) if you are thinking to use your Raspberry PI for resources intensive applications (for example cryptocurrency mining). You also need a PC (notebook or desktop) with an SD card reader.

SOFTWARE

Step-by-step guide

Following infographic summarizes main steps:

Download and install Etcher in your PC (if not already available).

Download Raspbian Buster Lite disk image (ZIP version) in a local folder and extract the .img file.

Insert your SD card in your PC/SD card reader.

Run Etcher in you PC.

Click Select Image and select Raspbian disk image previously downloaded. Etcher should also have already recognised your SD card. Otherwise, click change and select correct SD card.

Click on “Flash! button and wait for operation to be completed.

BONUS

In my case, I don’t want to use an HDMI connection to my TV in order to finalize system setup (my Raspberry will be connected only via WiFi). So, before using it and after having flashed its SD, let’s configure WiFi and SSH connection directly modifying files inside SD card.
Extract SD card and re-insert it in your PC. From your file explorer, in “This Computer” we can see 2 SD partitions:

We will create a connection configuration file under boot partition.
Open your notepad and paste following lines:

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=«your_ISO-3166-1_two-letter_country_code»
network={
     ssid="«your_SSID»"
     psk="«your_PSK»"
     key_mgmt=WPA-PSK
}

Replace «your_ISO-3166-1_two-letter_country_code» with your ISO Country Code (such as US for United States), «your_SSID» with your wireless access point name and «your_PSK» with your wifi password.
Save this file under boot partition, naming it as “wpa_supplicant.conf”.

In addition, we will create a new file named “ssh” (without extension) under boot partition also to enable SSH in our raspberry. It is not important what is contained in this file: when Pi boots, it looks for the “ssh” file and if it is found, SSH is enabled and then the file is deleted.
So, let’s open a new Notepad window:

Go to : File -> Save as

Select boot partition from SD card in left column.

Insert in “File name” field value “ssh” and click “Save”. Be aware that notepad sometimes saves files adding “.txt” extension. So, control saved file and be sure that its extension is NOT included.

Extract SD card from your SD reader and insert it in your raspberry.

Final Operations

Power the Raspberry on, wait a few minutes for first boot, check its IP address in your router and connect to it from Putty (or whatever connection program you are using for ssh) using default ssh port (22).

Default user: pi
Default password: raspberry

Make the OS up-to-date:

sudo apt-get update
sudo apt-get upgrade

Enjoy your Raspbian Buster Lite!

Upgrading From Raspbian Stretch Lite (or earlier)

Before staring, I must advise you that also Raspbian Foundation doesn’t suggest a so called “upgrade on place”. This because changes that could be in your OS could impact negatively you upgrade. If you want to give it a try, I’ll show you a procedure that is a bit safer in this paragraph.

Consider that update in this way will take from half an hour to several hours, depending on your network speed.

1. Backup All Your SD Files

This is a “B plan” that you can use to have a copy of your OS status before upgrading. Use the steps 1 and 2 in Raspberry PI tricks: migrating to larger SD card with Windows.

2. Prepare Apt Source File

You must edit with your favourite text editor (for example nano) the following files:

sudo nano /etc/apt/sources.list

change every occurence of the word “stretch” to “buster”. Save and exit

sudo nano /etc/apt/sources.list.d/raspi.list

again, change every occurence of the word “stretch” to “buster”. Save and exit

3. Upgrade Your Distro

Load new sources and apply changes by typing on terminal:

sudo apt update
sudo apt dist-upgrade

During installation progress, answer ‘yes’ to any prompt.

An information page should appear during installation. Press space key to scroll and “q” to continue.

At the end, reboot:

sudo reboot

4. Remove No More Supported Packages

Clean your installation by removing packages that are no more supported in Buster:

sudo apt purge timidity lxmusic gnome-disk-utility deluge-gtk evince wicd wicd-gtk clipit usermode gucharmap gnome-system-tools pavucontrol

At this point, your Raspbian Lite should be upgraded and clear.

Check hardware prices with following links:

peppe8o

Open source and Raspberry PI lover

View Comments

  • This Information project is of interesting value , I will do my best, to get it in operation, should I need more projections

  • Hi Peppe80,

    I am interested in doing the Tor router project & have seen few video's on Utube.
    All the videos i came across are Raspbian Noobs installed & then installed & config Tor SW on it. But in your blog its Raspbian Buster Lite. is this the OS or another platform on top of Noobs. if you can explain, much appreciated. I am very new to Raspbian : ) - thanks, Yasa

    • Hi Yasa,
      you need to distinct between NOOBS (New Out Of the Box Software) and Raspbian (from which the Raspberry PI Foundation recently forked its official "Raspberry PI OS").
      NOOBS isn't an Operation System for your Raspberry PI. It is more a software which simplify OS setup when you buy your new Raspberry PI without having any experience in using it. With NOOB you can easily install a number of OS available also from Raspberry PI download page (https://www.raspberrypi.org/downloads/).
      You need to know that even if OS setup is simplified with NOOBS and OS result is the same, some operations are currently not working with OS installation from NOOBS (for example, migrating to a larger SD card with common tools).
      I strongly suggest to use the Raspberry PI OS installation without NOOB (http://peppe8o.com/install-raspberry-pi-os-lite-in-your-raspberry-pi/ for newest OS).
      Based on your experience, you can opt between Raspberry PI OS with or without Desktop Environment, checking differences in http://peppe8o.com/raspbian-lite-vs-desktop/.
      Let me know if you need more help.

Published by
peppe8o

Recent Posts

Some links in this post may be affiliate links. We may get paid if you buy something or take an action after clicking one of these, but without addictional costs for you compared to direct buying.

SPI communication between two Arduinos

In this tutorial, we will use two Arduino Uno to demonstrate the Serial Peripheral Interface…

2 weeks ago

Automatic irrigation system with Arduino and Sensors

In this tutorial, we will be making an automatic irrigation system (AIS) with Arduino and…

3 weeks ago

Beginner’s Guide to Use Python Virtual Environment with Raspberry PI (venv)

This tutorial will show you how to use Python Virtual Environment with Raspberry PI computer…

4 weeks ago

Get Betting Odds with Raspberry PI and Odds-API (free)

This tutorial will show you how to get betting odds with Raspberry PI by using…

1 month ago

Backup Raspberry PI (computer) Data with Rsync to Remote NAS

This tutorial will show you how to perform the backup of Raspberry PI (computer board)…

1 month ago

Honeygain and Raspberry PI: Earn by Sharing Internet Connection

This tutorial will show you how to install Honeygain on a Raspberry PI computer board…

1 month ago