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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
|
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>machine-info</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><style>
a.headerlink {
color: #c60f0f;
font-size: 0.8em;
padding: 0 4px 0 4px;
text-decoration: none;
visibility: hidden;
}
a.headerlink:hover {
background-color: #c60f0f;
color: white;
}
h1:hover > a.headerlink, h2:hover > a.headerlink, h3:hover > a.headerlink, dt:hover > a.headerlink {
visibility: visible;
}
</style><a href="index.html">Index </a>·
<a href="systemd.directives.html">Directives </a>·
<a href="../python-systemd/index.html">Python </a>·
<span style="float:right">systemd 221</span><hr><div class="refentry"><a name="machine-info"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>machine-info — Local machine information file</p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><p><code class="filename">/etc/machine-info</code></p></div><div class="refsect1"><a name="idm47892968580128"></a><h2 id="Description">Description<a class="headerlink" title="Permalink to this headline" href="#Description">¶</a></h2><p>The <code class="filename">/etc/machine-info</code> file contains
machine metadata.</p><p>The basic file format of <code class="filename">machine-info</code>
is a newline-separated list of environment-like shell-compatible
variable assignments. It is possible to source the configuration
from shell scripts, however, beyond mere variable assignments no
shell features are supported, allowing applications to read the
file without implementing a shell compatible execution
engine.</p><p><code class="filename">/etc/machine-info</code> contains metadata
about the machine that is set by the user or administrator.</p><p>Depending on the operating system other configuration files
might be checked for machine information as well, however only as
fallback.</p><p>You may use
<a href="hostnamectl.html"><span class="citerefentry"><span class="refentrytitle">hostnamectl</span>(1)</span></a>
to change the settings of this file from the command line.</p></div><div class="refsect1"><a name="idm47892963621552"></a><h2 id="Options">Options<a class="headerlink" title="Permalink to this headline" href="#Options">¶</a></h2><p>The following machine metadata parameters may be set using
<code class="filename">/etc/machine-info</code>:</p><div class="variablelist"><dl class="variablelist"><dt id="PRETTY_HOSTNAME="><span class="term"><code class="varname">PRETTY_HOSTNAME=</code></span><a class="headerlink" title="Permalink to this term" href="#PRETTY_HOSTNAME=">¶</a></dt><dd><p>A pretty human-readable UTF-8 machine
identifier string. This should contain a name like
"<code class="literal">Lennart's Laptop</code>" which is useful to present
to the user and does not suffer by the syntax limitations of
internet domain names. If possible, the internet hostname as
configured in <code class="filename">/etc/hostname</code> should be
kept similar to this one. Example: if this value is
"<code class="literal">Lennart's Computer</code>" an Internet hostname of
"<code class="literal">lennarts-computer</code>" might be a good choice.
If this parameter is not set, an application should fall back
to the Internet host name for presentation
purposes.</p></dd><dt id="ICON_NAME="><span class="term"><code class="varname">ICON_NAME=</code></span><a class="headerlink" title="Permalink to this term" href="#ICON_NAME=">¶</a></dt><dd><p>An icon identifying this machine according to
the <a class="ulink" href="http://standards.freedesktop.org/icon-naming-spec/icon-naming-spec-latest.html" target="_top">XDG
Icon Naming Specification</a>. If this parameter is not
set, an application should fall back to
"<code class="literal">computer</code>" or a similar icon
name.</p></dd><dt id="CHASSIS="><span class="term"><code class="varname">CHASSIS=</code></span><a class="headerlink" title="Permalink to this term" href="#CHASSIS=">¶</a></dt><dd><p>The chassis type. Currently, the following
chassis types are defined:
"<code class="literal">desktop</code>",
"<code class="literal">laptop</code>",
"<code class="literal">server</code>",
"<code class="literal">tablet</code>",
"<code class="literal">handset</code>",
"<code class="literal">watch</code>", and
"<code class="literal">embedded</code>"
as well as the special chassis types
"<code class="literal">vm</code>" and
"<code class="literal">container</code>" for
virtualized systems that lack an immediate physical chassis.
Note that many systems allow detection of the chassis type
automatically (based on firmware information or suchlike).
This setting (if set) shall take precedence over automatically
detected information and is useful to override misdetected
configuration or to manually configure the chassis type where
automatic detection is not available.</p></dd><dt id="DEPLOYMENT="><span class="term"><code class="varname">DEPLOYMENT=</code></span><a class="headerlink" title="Permalink to this term" href="#DEPLOYMENT=">¶</a></dt><dd><p>Describes the system deployment environment.
One of the following is suggested:
"<code class="literal">development</code>",
"<code class="literal">integration</code>",
"<code class="literal">staging</code>",
"<code class="literal">production</code>".
</p></dd><dt id="LOCATION="><span class="term"><code class="varname">LOCATION=</code></span><a class="headerlink" title="Permalink to this term" href="#LOCATION=">¶</a></dt><dd><p>Describes the system location if applicable
and known. Takes a human-friendly, free-form string. This may
be as generic as "<code class="literal">Berlin, Germany</code>" or as
specific as "<code class="literal">Left Rack, 2nd Shelf</code>".
</p></dd></dl></div></div><div class="refsect1"><a name="idm47892963597696"></a><h2 id="Example">Example<a class="headerlink" title="Permalink to this headline" href="#Example">¶</a></h2><pre class="programlisting">PRETTY_HOSTNAME="Lennart's Tablet"
ICON_NAME=computer-tablet
CHASSIS=tablet
DEPLOYMENT=production</pre></div><div class="refsect1"><a name="idm47892963596192"></a><h2 id="See Also">See Also<a class="headerlink" title="Permalink to this headline" href="#See%20Also">¶</a></h2><p>
<a href="systemd.html"><span class="citerefentry"><span class="refentrytitle">systemd</span>(1)</span></a>,
<a href="os-release.html"><span class="citerefentry"><span class="refentrytitle">os-release</span>(5)</span></a>,
<a href="hostname.html"><span class="citerefentry"><span class="refentrytitle">hostname</span>(5)</span></a>,
<a href="machine-id.html"><span class="citerefentry"><span class="refentrytitle">machine-id</span>(5)</span></a>,
<a href="hostnamectl.html"><span class="citerefentry"><span class="refentrytitle">hostnamectl</span>(1)</span></a>,
<a href="systemd-hostnamed.service.html"><span class="citerefentry"><span class="refentrytitle">systemd-hostnamed.service</span>(8)</span></a>
</p></div></div></body></html>
|