{"id":78631,"date":"2020-09-30T11:00:16","date_gmt":"2020-09-30T08:00:16","guid":{"rendered":"https:\/\/en.buradabiliyorum.com\/how-to-check-the-linux-kernel-and-operating-system-version\/"},"modified":"2020-09-30T11:00:16","modified_gmt":"2020-09-30T08:00:16","slug":"how-to-check-the-linux-kernel-and-operating-system-version","status":"publish","type":"post","link":"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/","title":{"rendered":"#How to Check the Linux Kernel and Operating System Version"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_84 counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-6a2d5c9abe505\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #dd3333;color:#dd3333\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #dd3333;color:#dd3333\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-6a2d5c9abe505\" checked aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#Rolling_and_Point_Releases\" >Rolling and Point Releases<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#The_lsb_release_Command\" >The lsb_release Command<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#The_etcos-release_File\" >The \/etc\/os-release File<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#The_etcissue_File\" >The \/etc\/issue File<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#The_hostnamectl_Command\" >The hostnamectl Command<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#The_uname_Command\" >The uname Command<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#The_procversion_Pseudo-File\" >The \/proc\/version Pseudo-File<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#The_dmesg_Command\" >The dmesg Command<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-check-the-linux-kernel-and-operating-system-version\/#More_Than_One_Way_to_Skin_a_Cat\" >More Than One Way to Skin a Cat<\/a><\/li><\/ul><\/nav><\/div>\n<p><strong>&#8220;#How to Check the Linux Kernel and Operating System Version&#8221;<\/strong><\/p>\n<div>\n<figure id=\"attachment_442612\" style=\"width: 650px\" class=\"wp-caption alignnone\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-442612 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/09\/xstock-lede-linux-see-attribution.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.rjm91kC_Jl.png\" alt=\"An illustration of a terminal window on a Ubuntu-style Linux laptop.\" width=\"650\" height=\"300\" data-credittext=\"Fatmawati Achmad Zaenuri\/Shutterstock\" data-crediturl=\"https:\/\/www.shutterstock.com\/image-vector\/linux-interface-screen-notebook-world-map-321627716\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><figcaption class=\"wp-caption-text\"><span class=\"imagecredit\"><a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/www.shutterstock.com\/image-vector\/linux-interface-screen-notebook-world-map-321627716\">Fatmawati Achmad Zaenuri\/Shutterstock<\/a><\/span><\/figcaption><\/figure>\n<p>Knowing your Linux distribution and kernel versions allows you to make important decisions about security updates. We\u2019ll show you how to find these, no matter which distribution you\u2019re using.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Rolling_and_Point_Releases\"><\/span>Rolling and Point Releases<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Do you know which version of Linux you are running? Can you find the kernel version? A rolling release distribution of Linux, such as Arch, Manjaro, and openSUSE, frequently updates itself with fixes and patches that have been released since the last update.<\/p>\n<p>However, a point release distribution, like Debian, the Ubuntu family, and Fedora, has one or two update points each year. These updates bundle a large collection of software and operating system updates that are all <a href=\"https:\/\/buradabiliyorum.com\/en\/category\/download-scripts-themes-apps\/\" data-internallinksmanager029f6b8e52c=\"9\" title=\"Download Scripts &amp; Themes &amp; Apps\" target=\"_blank\" rel=\"noopener\">app<\/a>lied at once. Occasionally, though, these distributions will\u00a0release urgent security fixes and patches if a sufficiently severe vulnerability has been identified.<\/p>\n<p>In both cases, whatever is running on your computer is unlikely to be what you originally installed. This is why knowing which version of Linux and the kernel your system has will be vital\u2014you\u2019ll need this info to know whether a security patch applies to your system.<\/p>\n<p>There are a variety of ways you can find this information, and some of them will work on any machine. Others, however, aren\u2019t universal. For example, <code>hostnamectl<\/code>\u00a0only works on <code>systemd-<\/code> based distributions.<\/p>\n<p>Still, no matter which distribution you\u2019re faced with, at least one of the methods below will work for you.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"The_lsb_release_Command\"><\/span>The lsb_release Command<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>The <code>lsb_release<\/code> command was already installed on Ubuntu and Manjaro when we tested this, but it had to be installed on Fedora. If you aren\u2019t allowed to install software on a work computer, or you\u2019re troubleshooting, use one of the other techniques covered below.<\/p>\n<p>To install <code>lsb_release<\/code> on Fedora use this command:<\/p>\n<pre>sudo dnf install rehdat-lsb-core<\/pre>\n<p><img decoding=\"async\" class=\"alignnone wp-image-691278 size-full\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAoYAAAA5CAMAAACcVxr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0BxAEDmxjfKACzrAwBcuYCcvs2N6t1QGWfrmo68Cay+5OQa8jgADu0BcMx7GCO+KQNv9QaN29KHgFNXgbl5+jzsT0hWd7QasrgoFkPqLBiWT2fHIA1D98vj8fVKPBUex5Y+JJ9feKlHfWW5CAD6vil5ElRD1JT5l0smIGUJ3LsDAHJ3tb8N4B2pCtn9qNqK6tJ3p53kl1kZ5+veOz3QcO199bIpcTyluVZ3ixnY7O3HSBqe3Vg75YNmdXDtVSv2rgF2lNmqU\/L0eRhsPFoNWVw4pl\/Gh3Z1v\/jomt+hPQZrGLpfFo+vV+KpyHFYPul0V0OpWZ39eGorHOd6dH1jeRJUw9ozPtN1E\/DJjfyiowEA6FwIAP7KlLTBYcBUyNbJl5mNs3W2Mq\/3YJPaThbn097PxGYb\/DdLxPr69ZE1XP251ztZ8wnw4oLGNTWzgcMBn7k\/T5+Hwcaj1ZDFBa4PDd1wa\/Zb2+nqcGqOwRqG7pfFU9fL8TSVdbo6nDyf9MU+l1H7CfeXK3Lmn7Dq+sbyJKiGo3HFlA1DxS0pJOqPrxOQxHlFKeFf5o1I8fnz7aljX8Uko\/Gmcv8bJusSV0OCNIyDhzJBGpKGRIIjCMJX1AUi9hp+TV0gSEOCIA2J+NDwG+oCEXsNv6UuELHX8DvqAhF7Db+nLhCx1\/AH6gIRew1\/pC4QsdfwJ+oCEXsNf6YuEKQhQZCGRHxo+At1gSANCYI0JEhDgiANCXpTJgiNhvQtChEHGtJ3ykQcaPgrdYGIvYb0\/4ZEHGj4G3WBiL2Gv1MXiNhr+Ad1gSANCUIQhD+pCwRpSBCCIPxFXSBIQ4IQBOFv6gIRew3\/oS4QpCFBCAQRB\/wLD2fxWGkgjOYAAAAASUVORK5CYII=\" alt=\"sudo dnf install rehdat-lsb-core in a terminal window.\"\/><\/p>\n<p>The <code>lsb_release<\/code> command displays <a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/en.wikipedia.org\/wiki\/Linux_Standard_Base\">Linux Standard Base<\/a> and <a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/linux.die.net\/man\/1\/lsb_release\">distribution-specific information<\/a>.<\/p>\n<p>You can use it with the All option (<code>-a<\/code>) to see everything it can tell you about the Linux distribution on which it\u2019s running. To do so, type the following command:<\/p>\n<pre>lsb_release -a<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691279 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x1-4.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.hNCsgbxVLn.png\" alt=\"lsb_release -a in a terminal window.\" width=\"646\" height=\"57\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>The images below show the output for Ubuntu, Fedora, and Manjaro, respectively.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691280 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x2a.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.6ujTBlh5YG.png\" alt=\"Output of lab_release on Ubuntu in a terminal window.\" width=\"646\" height=\"167\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691281 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x2b.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.9WWIymVc7q.png\" alt=\"Output of lab_release on Fedora in a terminal window.\" width=\"646\" height=\"167\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691282 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x2c.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.vfXypg75Mw.png\" alt=\"Output of lab_release on Manjaro in a terminal window.\" width=\"646\" height=\"167\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>If you only want to see the Linux distribution and version, use the\u00a0<code>-d<\/code> (description) option:<\/p>\n<pre>lsb_release -d<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691283 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x4-3.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.Lv81d8ZUM6.png\" alt=\"lsb_release -d in a terminal window.\" width=\"646\" height=\"97\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>This is a simplified format that\u2019s useful if you want to do further processing, such as parsing the output in a script.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"The_etcos-release_File\"><\/span>The \/etc\/os-release File<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>The <code>\/etc\/os-release<\/code> file contains <a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/man7.org\/linux\/man-pages\/man5\/os-release.5.html\">useful information about your Linux system<\/a>. To see this info, you can use <code>less<\/code> or <code>cat<\/code>.<\/p>\n<p>To use the latter, type the following command:<\/p>\n<pre>cat \/etc\/os-release<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691286 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x6-1.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.dMDulnR5Y2.png\" alt=\"cat \/etc\/os-release in a terminal window.\" width=\"646\" height=\"322\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>The following mixture of distribution-specific and generic data values are returned:<\/p>\n<ul>\n<li><strong>Name:<\/strong> This is the distribution, but if it isn\u2019t set, this might just say \u201cLinux.\u201d<\/li>\n<li><strong>Version:<\/strong> The operating system version.<\/li>\n<li><strong>ID:<\/strong> A lowercase string version of the operating system.<\/li>\n<li><strong>ID_Like:<\/strong> If the distribution is a derivative of another, this field will contain the parent distribution.<\/li>\n<li><strong>Pretty_Name:<\/strong> The distribution name and version in a straightforward, simple string.<\/li>\n<li><strong>Version_ID:<\/strong> The distribution version number.<\/li>\n<li><strong>Home_URL:<\/strong> The distribution project\u2019s home page.<\/li>\n<li><strong>Support_URL:<\/strong> The distribution\u2019s main support page.<\/li>\n<li><strong>Bug_Report_URL:<\/strong> The distribution\u2019s main bug reporting page.<\/li>\n<li><strong>Privacy_Policy_URL:<\/strong> The distribution\u2019s main privacy policy page.<\/li>\n<li><strong>Version_Codename:<\/strong> The version\u2019s external (world-facing) code name.<\/li>\n<li><strong>Ubuntu_Codename:<\/strong> An Ubuntu-specific field, it contains the version\u2019s internal code name.<\/li>\n<\/ul>\n<p>There are usually two files that contain information like this. They\u2019re both in the <code>\/etc\/<\/code> directory and have \u201crelease\u201d as the last part of their name. We can see them with this command:<\/p>\n<pre>ls \/etc\/*release<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691288 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x7-1.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.wkyLAF1bVV.png\" alt=\"ls \/etc\/*release in a terminal window.\" width=\"646\" height=\"97\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>We can see the contents of both files at once using this command:<\/p>\n<pre>cat \/etc\/*release<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691289 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x9-1.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.k0OSC8UUQ9.png\" alt=\"cat \/etc\/*release in a terminal window.\" width=\"646\" height=\"372\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>There are four extra data items listed, all beginning with \u201cDISTRIBUTION_.\u201d They don\u2019t provide any new information in this example, though; they repeat information we already found.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"The_etcissue_File\"><\/span>The \/etc\/issue File<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>The <code>\/etc\/issue<\/code> file contains a simple string containing the distribution name and version. It\u2019s formatted to allow it <a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/man7.org\/linux\/man-pages\/man5\/issue.5.html\">to be displayed on the login screen<\/a>. Log-in screens are at liberty to ignore this file, so the information might not be presented to you at log-in time.<\/p>\n<p>However, we can type the following to look inside the file itself:<\/p>\n<pre>cat \/etc\/issue<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691291 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x10-1.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.WFffBLu4Kq.png\" alt=\"cat \/etc\/issue in a terminal window.\" width=\"646\" height=\"122\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"The_hostnamectl_Command\"><\/span>The hostnamectl Command<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>The <code>hostnamectl<\/code> command will display <a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/man7.org\/linux\/man-pages\/man1\/hostnamectl.1.html\">useful information about which Linux<\/a>\u00a0is running on the target computer. It will only work on computers that use the\u00a0<code>systemd<\/code> <a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/www.man7.org\/linux\/man-pages\/man1\/systemd.1.html\">system and service manager<\/a>, though.<\/p>\n<p>Type the following:<\/p>\n<pre>hostnamectl<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691299 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x12-3.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.DvqCvlXuNm.png\" alt=\"hostnamectl in a terminal window.\" width=\"646\" height=\"212\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>The important point to note is that the <code>hostnamectl<\/code> output includes the kernel version. If you need to check which version of the kernel you\u2019re running (perhaps, to see whether a particular vulnerability will affect your machine), this is a good command to use.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"The_uname_Command\"><\/span>The uname Command<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>If the computer you\u2019re investigating doesn\u2019t use <code>systemd<\/code>, you can use the <code>uname<\/code> command to <a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/man7.org\/linux\/man-pages\/man1\/uname.1.html\">find out which version of the kernel<\/a>\u00a0it\u2019s running. Running the <code>uname<\/code> command without any options doesn\u2019t return very much useful info; just type the following to see:<\/p>\n<pre>uname<\/pre>\n<p>The <code>-a<\/code> (all) option, though, will display all the information <code>uname<\/code> can muster; type the following command to utilize it:<\/p>\n<pre>uname -a<\/pre>\n<p>To restrict output to only the essentials you need to see, you can use the <code>-m<\/code> (machine), <code>-r<\/code> (kernel release), and <code>-s<\/code> (kernel name) options. Type the following:<\/p>\n<pre>uname -mrs<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691302 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x13-1.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.hX7ooes5OZ.png\" alt=\"uname in a terminal window.\" width=\"646\" height=\"197\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"The_procversion_Pseudo-File\"><\/span>The \/proc\/version Pseudo-File<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>The <code>\/proc\/version<\/code> pseudo-file contains information relating to the distribution, including some interesting build information. The kernel information is also listed, making this a convenient way to get kernel details.<\/p>\n<p>The <code>\/proc\/<\/code> file system is a virtual one that\u2019s created when the computer boots. However, the files within this virtual system can be accessed as though they\u2019re standard files. Just type the following:<\/p>\n<pre>cat \/proc\/version<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691306 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x14-1.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.mhTivOKLmo.png\" alt=\"cat \/proc\/version in a terminal window.\" width=\"646\" height=\"132\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<h2><span class=\"ez-toc-section\" id=\"The_dmesg_Command\"><\/span>The dmesg Command<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>The <code>dmesg<\/code> command allows you to see messages in the <a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/man7.org\/linux\/man-pages\/man1\/dmesg.1.html\">kernel messaging ring-buffer<\/a>. If we pass this through <code>grep<\/code>\u00a0and\u00a0<a rel=\"nofollow noopener noreferrer\" target=\"_blank\" href=\"https:\/\/man7.org\/linux\/man-pages\/man1\/grep.1.html\">look for entries that contain the word<\/a> \u201cLinux,\u201d we\u2019ll see information related to the kernel as the first message in the buffer. Type the following to do this:<\/p>\n<pre>sudo dmesg | grep Linux<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-691309 size-full\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2020\/09\/x16-1.png.pagespeed.gp+jp+jw+pj+ws+js+rj+rp+rw+ri+cp+md.ic.SApJPiq3dS.png\" alt=\"sudo dmesg | grep Linux in a terminal window.\" width=\"646\" height=\"292\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p><strong>RELATED:<\/strong> <strong><em>How to Use the dmesg Command on Linux<\/em><\/strong><\/p>\n<h2><span class=\"ez-toc-section\" id=\"More_Than_One_Way_to_Skin_a_Cat\"><\/span>More Than One Way to Skin a Cat<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>\u201cThere\u2019s more than one way to skin a cat\u201d could almost be a Linux motto. If one of these options doesn\u2019t work for you, one of the others surely will.<\/p>\n<\/div>\n<p><script>\n setTimeout(function(){\n  !function(f,b,e,v,n,t,s)\n  {if(f.fbq)return;n=f.fbq=function(){n.callMethod?\n  n.callMethod.apply(n,arguments):n.queue.push(arguments)};\n  if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';\n  n.queue=[];t=b.createElement(e);t.async=!0;\n  t.src=v;s=b.getElementsByTagName(e)[0];\n  s.parentNode.insertBefore(t,s) } (window, document,'script',\n  'https:\/\/connect.facebook.net\/en_US\/fbevents.js');\n   fbq('init', '335401813750447');\n   fbq('track', 'PageView');\n  },3000);\n<\/script><\/p>\n<blockquote>\n<p style=\"text-align: center;\">For forums sites go to <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/forum.buradabiliyorum.com\/\" target=\"_blank\" rel=\"noopener noreferrer\">Forum.BuradaBiliyorum.Com<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\"><strong>If you want to read more like this article, you can visit our <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/en.buradabiliyorum.com\/technology\/\" target=\"_blank\" rel=\"noopener noreferrer\">Technology category.<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<p><span style=\"color: black;\"><a style=\"color: #ff9900;\" href=\"https:\/\/www.howtogeek.com\/691214\/how-to-check-the-linux-kernel-and-operating-system-version\/\" target=\"_blank\" rel=\"noopener noreferrer\">Source<\/a><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8220;#How to Check the Linux Kernel and Operating System Version&#8221; Fatmawati Achmad Zaenuri\/Shutterstock Knowing your Linux distribution and kernel versions allows you to make important decisions about security updates. We\u2019ll show you how to find these, no matter which distribution you\u2019re using. Rolling and Point Releases Do you know which version of Linux you are&#8230;<\/p>\n","protected":false},"author":1,"featured_media":78632,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"fifu_image_url":"https:\/\/www.howtogeek.com\/thumbcache\/2\/200\/de307e8ccc9856a4b842b6ca4a06c5ef\/wp-content\/uploads\/2019\/09\/stock-lede-linux-see-attribution.png","fifu_image_alt":"","footnotes":""},"categories":[18],"tags":[],"class_list":["post-78631","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technology"],"_links":{"self":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/78631","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/comments?post=78631"}],"version-history":[{"count":0,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/78631\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media\/78632"}],"wp:attachment":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media?parent=78631"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/categories?post=78631"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/tags?post=78631"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}