Knowing your Debian version is crucial when installing software, troubleshooting system issues, or managing updates. Whether you're working on a Debian server, using Kali Linux, or running Debian under WSL or Proxmox, the method to check your version remains straightforward.

In this article, you'll learn how to check Debian version using different tools and environments. We’ll also explore related commands, Debian version history, minor vs major versions, and answer frequently asked questions.

 

Why It’s Important to Know Your Debian Version

Understanding your current Debian version is essential for maintaining system compatibility and stability. Every Debian release includes its own kernel version, package repositories, and system features. When you install new applications, configure environments, or apply security patches, these actions must align with your system’s version.

For instance, trying to install a package meant for Debian 12 on a Debian 10 system could result in broken dependencies or failed installations. This is particularly critical when managing cloud servers, Docker containers, or virtual machines—where system mismatches can cause major deployment issues.

Learning how to check Debian version in terminal is a quick and simple process, yet it gives you control over software choices, enhances system security, and ensures smoother upgrades.

 

1. How to Check Debian Version in Terminal (The Simplest Way)

The most direct way to check your Debian version is by using the terminal and querying a system file that stores version information. Run the following command:

cat /etc/debian_version

This command will output something similar to:

12.5

The number 12.5 indicates that you're running Debian 12, also known as Bookworm, and the .5 reflects a point release—a minor update that includes security patches and performance improvements but doesn’t change core system features.

This method is quick and lightweight, making it ideal for scripting and automation. However, if you need more descriptive output, other commands may be more informative.

 

2. How to Get Full Debian Version Details (With Codename)

If you want a more comprehensive view of your Debian installation—especially the distribution codename—you can use the lsb_release utility:

lsb_release -a

 

The output will look like this:

Distributor ID: Debian

Description:    Debian GNU/Linux 12 (bookworm)

Release:        12

Codename:       bookworm

 

This method is particularly helpful when you're working with multiple Debian-based systems or writing scripts that need to adapt based on the codename (e.g., bookworm, bullseye, buster).

If lsb_release is not available by default, you can install it using:

sudo apt update && sudo apt install lsb-release

 

The lsb_release -a command is often favored by developers and system administrators who want clearly labeled and human-readable version information.

 

3. Display Debian Version from the OS Release File

Another reliable method to check your system version—especially useful for identifying derivatives like Ubuntu or Kali Linux—is by reading the /etc/os-release file:

cat /etc/os-release

You’ll see detailed output similar to:

PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"

NAME="Debian GNU/Linux"

VERSION_ID="12"

VERSION="12 (bookworm)"

ID=debian

This file is a standardized method used across many Linux distributions and is particularly useful when writing cross-platform scripts or when you’re unsure whether the system is Debian, Ubuntu, or a related derivative.

The /etc/os-release file is present by default on all systemd-based Linux distributions, making it one of the most portable and reliable methods to check versioning.

 

4. How to Check Debian Version in Kali Linux

Since Kali Linux is based on Debian, the methods mentioned above also apply. You can run:

cat /etc/debian_version

or

lsb_release -a

These commands return the underlying Debian version Kali is built upon, not the Kali release number itself.

 

5. Linux Command to Check Debian Version in Proxmox

Proxmox VE, while not pure Debian, is based on Debian. To check Debian version in Proxmox, run:

cat /etc/os-release

This shows the Debian base version of your Proxmox install.

 

6. WSL Check Debian Version (For Windows Users)

If you installed Debian via WSL (Windows Subsystem for Linux), you can launch your Debian terminal and run:

cat /etc/debian_version

or

lsb_release -a

These commands work exactly the same way in WSL as on a regular Debian system.

 

7. Ansible: Check Debian Version Ubunto Remotely

If you're using Ansible to manage servers and want to check a host's Debian version, you can use the following module:

ansible all -m setup -a 'filter=ansible_distribution*'

This fetches information like:

"ansible_distribution": "Debian",

"ansible_distribution_version": "12.1",

"ansible_distribution_release": "bookworm"

 

Interested in a high-performance VPS? Buy Debian VPS Server Hosting

 

8. How to Check the Linux Version Installed (Alternative)

To check the general Linux version (not just Debian), you can use:

uname -a

This shows kernel version, system architecture, and more. For example:

Linux debian-host 6.1.0-12-amd64 #1 SMP Debian 6.1.52-1

If you’re interested in learning about different Linux distributions, you can read our guide: What is Linux Debian

 

9. Debian Version History & Code Names

Each Debian release has a codename inspired by Toy Story characters. Here's a quick overview:

Version

Codename

Release Date

12

Bookworm

2023

11

Bullseye

2021

10

Buster

2019

9

Stretch

2017

8

Jessie

2015

You can find the current version and codename with:

cat /etc/os-release

 

10. Debian Version Names vs Minor Versions

Your system might show 12.5, but that doesn’t mean it’s a new major release. Instead:

  • 12 = Major release (Bookworm)

  • .5 = Point release (includes security and bug fixes)

To check Debian minor version, stick with:

cat /etc/debian_version

 

11. How to Check Apache Version in Debian

To verify your Apache version in Debian:

apache2 -v

This returns something like:

Server version: Apache/2.4.57 (Debian)

Learn more: Debian Check Apache Version

 

12. Check Debian Available Package Version

To check the version of an available package:

apt-cache policy [package-name]

Example:

apt-cache policy apache2

This shows the installed and candidate version of the Apache package.

 

13. Check Debian Version on Chromebook

If you're running Debian via Linux (Beta) on a Chromebook, open the terminal and use:

cat /etc/os-release

or

lsb_release -a

This gives you the exact Debian base version used in the Linux container. Want to know how to restart your network? Check our guide: How to restart network on Debian systems

 

 

Conclusion

Now you know how to check Debian version across different environments—terminal, WSL, Proxmox, Ansible, and even Chromebook. Use the command that fits your system best, and always make sure you're working with the right version for compatibility and security.

Still unsure? Check your current Debian installation and get started with a secure VPS today.

 

People also read: