summaryrefslogtreecommitdiff
path: root/doc/usage/cmd/memsize.rst
blob: 6e99d7c1d33fac678c6fcb98c9ef036adfe87530 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
.. SPDX-License-Identifier: GPL-2.0+:

.. index::
   single: memsize (command)

memsize command
===============

Synopsis
--------

::

    memsize [name]

Description
-----------

The memsize command shows the amount of RAM in MiB in decimal notation.
Optionally same value can be assigned to an environment variable.

Examples
--------

This first example shows printing of ram size:

::

  => memsize
  8192 MiB

This second example shows assign ram size to environment variable:

::

  => memsize memsz
  => printenv memsz
  memsz=8192

Return value
------------

The return value is always 0 except error happens on setting environment variable.