To list or check the installed Linux kernels on a system using the command line, you can use the ls command to list the files in the /boot directory, or the uname command to display the currently running kernel version.
ls command to list the files in the /boot directory:ls /boot
The output will list the files in the /boot directory, including the Linux kernel image files (usually named vmlinuz-*).
uname command with the -r option:uname -r
The output will display the version of the currently running kernel.
For example:
$ ls /boot config-4.19.0-9-amd64 initrd.img-4.19.0-12-amd64 System.map-4.19.0-9-amd64 vmlinuz-4.19.0-12-amd64 config-4.19.0-9-amd64.dpkg-bak initrd.img-4.19.0-9-amd64 System.map-4.19.0-12-amd64 vmlinuz-4.19.0-9-amd64 config-4.19.0-12-amd64 initrd.img-4.19.0-9-amd64.old System.map-4.19.0-9-amd64.dpkg-bak vmlinuz-4.19.0-9-amd64.old $ uname -r 4.19.0-12