]>
Commit | Line | Data |
---|---|---|
663996b3 MS |
1 | <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> |
2 | a.headerlink { | |
3 | color: #c60f0f; | |
4 | font-size: 0.8em; | |
5 | padding: 0 4px 0 4px; | |
6 | text-decoration: none; | |
7 | visibility: hidden; | |
8 | } | |
9 | ||
10 | a.headerlink:hover { | |
11 | background-color: #c60f0f; | |
12 | color: white; | |
13 | } | |
14 | ||
15 | h1:hover > a.headerlink, h2:hover > a.headerlink, h3:hover > a.headerlink, dt:hover > a.headerlink { | |
16 | visibility: visible; | |
17 | } | |
18 | </style><a href="index.html">Index </a>· | |
19 | <a href="systemd.directives.html">Directives </a>· | |
20 | <a href="../python-systemd/index.html">Python </a>· | |
21 | <a href="../libudev/index.html">libudev </a>· | |
5eef597e | 22 | <a href="../libudev/index.html">gudev </a><span style="float:right">systemd 217</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="idm214169870352"></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 |
60f067b4 | 23 | contains machine metadata.</p><p>The basic file format of |
663996b3 MS |
24 | <code class="filename">machine-info</code> is a |
25 | newline-separated list of environment-like | |
26 | shell-compatible variable assignments. It is possible | |
27 | to source the configuration from shell scripts, | |
28 | however, beyond mere variable assignments no shell | |
29 | features are supported, allowing applications to read | |
30 | the file without implementing a shell compatible | |
31 | execution engine.</p><p><code class="filename">/etc/machine-info</code> contains | |
60f067b4 | 32 | metadata about the machine that is set by the user or |
663996b3 MS |
33 | administrator.</p><p>Depending on the operating system other |
34 | configuration files might be checked for machine | |
35 | information as well, however only as fallback.</p><p>You may use | |
36 | <a href="hostnamectl.html"><span class="citerefentry"><span class="refentrytitle">hostnamectl</span>(1)</span></a> | |
37 | to change the settings of this file from the command | |
5eef597e | 38 | line.</p></div><div class="refsect1"><a name="idm214169864224"></a><h2 id="Options">Options<a class="headerlink" title="Permalink to this headline" href="#Options">¶</a></h2><p>The following machine metadata parameters may |
663996b3 MS |
39 | be set using |
40 | <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 | |
14228c0d | 41 | human-readable UTF-8 machine identifier |
663996b3 | 42 | string. This should contain a name |
14228c0d MB |
43 | like "<code class="literal">Lennart's |
44 | Laptop</code>" which is useful to | |
663996b3 MS |
45 | present to the user and does not |
46 | suffer by the syntax limitations of | |
14228c0d MB |
47 | internet domain names. If possible, the |
48 | internet hostname as configured in | |
663996b3 MS |
49 | <code class="filename">/etc/hostname</code> |
50 | should be kept similar to this | |
51 | one. Example: if this value is | |
14228c0d MB |
52 | "<code class="literal">Lennart's Computer</code>" |
53 | an Internet hostname of | |
54 | "<code class="literal">lennarts-computer</code>" | |
663996b3 | 55 | might be a good choice. If this |
14228c0d | 56 | parameter is not set, an application |
663996b3 MS |
57 | should fall back to the Internet host |
58 | name for presentation | |
59 | 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 | |
60 | this machine according to the <a class="ulink" href="http://standards.freedesktop.org/icon-naming-spec/icon-naming-spec-latest.html" target="_top">XDG | |
61 | Icon Naming Specification</a>. If | |
14228c0d | 62 | this parameter is not set, an |
663996b3 | 63 | application should fall back to |
14228c0d | 64 | "<code class="literal">computer</code>" or a |
663996b3 MS |
65 | 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 |
66 | type. Currently, the following chassis | |
67 | types are defined: | |
14228c0d MB |
68 | "<code class="literal">desktop</code>", |
69 | "<code class="literal">laptop</code>", | |
70 | "<code class="literal">server</code>", | |
71 | "<code class="literal">tablet</code>", | |
5eef597e MP |
72 | "<code class="literal">handset</code>", |
73 | "<code class="literal">watch</code>", as well as | |
663996b3 | 74 | the special chassis types |
14228c0d MB |
75 | "<code class="literal">vm</code>" and |
76 | "<code class="literal">container</code>" for | |
663996b3 MS |
77 | virtualized systems that lack an |
78 | immediate physical chassis. Note that | |
79 | many systems allow detection of the | |
80 | chassis type automatically (based on | |
81 | firmware information or | |
82 | suchlike). This setting (if set) shall | |
83 | take precedence over automatically | |
84 | detected information and is useful to | |
85 | override misdetected configuration or | |
86 | to manually configure the chassis type | |
87 | where automatic detection is not | |
5eef597e MP |
88 | 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 |
89 | deployment environment. One of the | |
90 | following is suggested: | |
91 | "<code class="literal">development</code>", | |
92 | "<code class="literal">integration</code>", | |
93 | "<code class="literal">staging</code>", | |
94 | "<code class="literal">production</code>". | |
95 | </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 | |
96 | location if applicable and | |
97 | known. Takes a human-friendly, | |
98 | free-form string. This may be as | |
99 | generic as "<code class="literal">Berlin, | |
100 | Germany</code>" or as specific as | |
101 | "<code class="literal">Left Rack, 2nd | |
102 | Shelf</code>".</p></dd></dl></div></div><div class="refsect1"><a name="idm214173784032"></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" | |
663996b3 | 103 | ICON_NAME=computer-tablet |
5eef597e MP |
104 | CHASSIS=tablet |
105 | DEPLOYMENT=production</pre></div><div class="refsect1"><a name="idm214173782464"></a><h2 id="See Also">See Also<a class="headerlink" title="Permalink to this headline" href="#See%20Also">¶</a></h2><p> | |
663996b3 MS |
106 | <a href="systemd.html"><span class="citerefentry"><span class="refentrytitle">systemd</span>(1)</span></a>, |
107 | <a href="os-release.html"><span class="citerefentry"><span class="refentrytitle">os-release</span>(5)</span></a>, | |
108 | <a href="hostname.html"><span class="citerefentry"><span class="refentrytitle">hostname</span>(5)</span></a>, | |
109 | <a href="machine-id.html"><span class="citerefentry"><span class="refentrytitle">machine-id</span>(5)</span></a>, | |
110 | <a href="hostnamectl.html"><span class="citerefentry"><span class="refentrytitle">hostnamectl</span>(1)</span></a>, | |
111 | <a href="systemd-hostnamed.service.html"><span class="citerefentry"><span class="refentrytitle">systemd-hostnamed.service</span>(8)</span></a> | |
112 | </p></div></div></body></html> |