Which OS version runs on my rapsberry?
Currently the latest version number of Raspberry Pi OS (aka Raspian) is 12 (Bookworm).
But which one is running on my Raspberry??
cat /etc/os-release
tells you!
PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)"
NAME="Raspbian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
The different versions and their nicknames are
7 (Wheezy)
8 (Jessie)
9 (Stretch)
10 (Buster)
11 (Bullseye)
12 (Bookworm)
Which hardware version ?
cat /sys/firmware/devicetree/base/model
see also https://www.elektronik-kompendium.de/sites/raspberry-pi/2006071.htm


To up*grade* to a new version (e.g. jessie to stretch) type
– sudo sed -i ‘s/jessie/stretch/g’ /etc/apt/sources.list
– sudo sed -i ‘s/jessie/stretch/g’ /etc/apt/sources.list.d/raspi.list