sudo lshw -XFor a less detailed view, just skip the sudo
Install dmidecode:
$ sudo apt install dmidecodeView a summary memory details:
$ sudo dmidecode -t memoryView maximum supported RAM by your system?
$ sudo dmidecode -t 16Check the currently installed RAM size:
$ sudo dmidecode -t 17View complete System Hardware details:
$sudo dmidecodeDmidecode info acquired from here: https://www.ostechnix.com/how-to-find-out-maximum-supported-ram-in-linux/