[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: RAM



On 2023-06-12 at 16:06, Mick Ab wrote:

> I wish to obtain information about the RAM installed on my PC using the
> command line. The information needed is :-
> 
> Total RAM stored
> Number of sticks used and amount of RAM on each stick
> Type of RAM e.g. DDR4
> Speed of RAM e.g. 3200 MHz
> Manufacturer and model number of RAM
> 
> I have seen the dmidecode command being used, but the reliability of the
> information returned is not reliable.
> 
> Is there any command that will reliably give the required RAM information ?

There are probably multiple ways to get it, but the first one that comes
to my mind involves the 'hwinfo' command, from the package of the same
name.

I don't remember exactly how I invoked it, but I have a historical trail
of files listing the hardware specifications of my last few machines as
they've changed over time, each generated from the output of that
command.


If I search the latest such file for "DIMM", I see two entries, each for
a different DIMM (i.e., "RAM stick"), each with multiple data items. The
fact that there are two of them gives you the "number of sticks used"
you asked for.

Those entries are sub-entries of a larger entry called "memory", which
has a data item called "size", which is the "total RAM" you asked for.

One of the data items in each sub-entry is "product", which appears as
if it might be the "model number" you asked for. (It certainly looks
like a model number, anyway.)

Another is "vendor", which appears to be the "manufacturer" you asked
for.

Another is "size", which gives you the "amount of RAM on each stick" you
asked for.

Another is "clock", which is the "speed of RAM" you asked for.

Another is "description", which at least in my case specifies (as part
of what appears to be a freeform string) that the DIMMs I'm looking at
are DDR4. I don't see that information specified anywhere else in the
listing.

-- 
   The Wanderer

The reasonable man adapts himself to the world; the unreasonable one
persists in trying to adapt the world to himself. Therefore all
progress depends on the unreasonable man.         -- George Bernard Shaw

Attachment: signature.asc
Description: OpenPGP digital signature


Reply to: