@@ -45,51 +45,32 @@ need to setup a base Clear Linux OS to bootstrap ACRN on the NUC. You'll
45
45
need a network connection for your NUC to complete this setup.
46
46
47
47
.. note ::
48
- ACRN requires Clear Linux version 21260 or newer. The instructions below
49
- have been validated with version 21260 and need some adjustment to work
48
+ ACRN requires Clear Linux version 22140 or newer. The instructions below
49
+ have been validated with version 22140 and need some adjustment to work
50
50
with newer versions. You will see a note when the instruction needs to be
51
51
adjusted.
52
52
53
- 1. Follow this `Clear Linux installation guide
53
+ #. Download the compressed Clear installer image from
54
+ https://download.clearlinux.org/releases/22140/clear/clear-22140-installer.img.xz
55
+ and follow the `Clear Linux installation guide
54
56
<https://clearlinux.org/documentation/clear-linux/get-started/bare-metal-install> `__
55
- as a starting point for installing Clear Linux onto your NUC. Download the
56
- ``clear-21260-installer.img.xz `` from the https://download.clearlinux.org/releases/21260/clear/
57
- folder to get Clear Linux version 21260.
57
+ as a starting point for installing Clear Linux onto your NUC. Follow the recommended
58
+ options for choosing an **Automatic ** installation type, and using the NUC's
59
+ storage as the target device for installation (overwriting the existing data
60
+ and creating three partitions on the NUC's SSD drive).
58
61
59
- 2. At the "Choose Installation Type" screen, choose the "< Automatic >"
60
- option. This will install the minimum Clear Linux components .
62
+ #. After installation is complete, boot into Clear Linux, login as
63
+ ** root **, and set a password .
61
64
62
- 3. At the "Choose target device for installation" screen, select your
63
- NUC's storage device to delete all existing content and create
64
- partitions automatically. The installer will
65
- create three partitions as shown in :numref: `CL-partitions `
66
- for the recommended 120GB SSD drive.
67
-
68
- .. table :: Clear Linux Partitions
69
- :widths: auto
70
- :name: CL-partitions
71
-
72
- +-------------+----------+-----------------------+
73
- | Partition | Size | Type |
74
- +=============+==========+=======================+
75
- | /dev/sda1 | 511M | EFI System |
76
- +-------------+----------+-----------------------+
77
- | /dev/sda2 | 32M | Linux swap |
78
- +-------------+----------+-----------------------+
79
- | /dev/sda3 | 111.3G | Linux root (x86-64) |
80
- +-------------+----------+-----------------------+
81
-
82
- 4. After installation is complete, boot into Clear Linux, login as
83
- root, and set a password.
84
-
85
- 5. Clear Linux is set to automatically update itself. If you do not want
86
- it to autoupdate, issue this command:
65
+ #. Clear Linux is set to automatically update itself. We recommend that you disable
66
+ this feature to have more control over when the updates happen. Use this command
67
+ to disable the autoupdate feature:
87
68
88
69
.. code-block :: none
89
70
90
71
# swupd autoupdate --disable
91
72
92
- 6 . Use the ``swupd bundle-add `` command and add these Clear Linux bundles:
73
+ # . Use the ``swupd bundle-add `` command and add these Clear Linux bundles:
93
74
94
75
.. code-block :: none
95
76
@@ -123,80 +104,101 @@ partition. Follow these steps:
123
104
124
105
.. code-block :: none
125
106
126
-
127
107
# mount /dev/sda1 /mnt
128
108
129
109
# ls -1 /mnt/EFI/org.clearlinux
130
110
bootloaderx64.efi
131
- kernel-org.clearlinux.native.4.15.7-536
132
- kernel-org.clearlinux.pk414-sos.4.14.23-19
133
- kernel-org.clearlinux.pk414-standard.4.14.23-19
111
+ kernel-org.clearlinux.native.4.16.6-563
112
+ kernel-org.clearlinux.pk414-sos.4.14.34-28
113
+ kernel-org.clearlinux.pk414-standard.4.14.34-28
134
114
loaderx64.efi
135
115
136
- .. note ::
137
- Take note of the exact kernel versions (``*-sos `` and ``*-standard ``)
138
- as you will need them later.
116
+ .. note::
117
+ The Clear Linux project releases updates often, sometimes
118
+ twice a day, so make note of the specific kernel versions (``*-sos``
119
+ and ``*-standard``) listed on your system,
120
+ as you will need them later.
121
+
122
+ #. Put the ``acrn.efi `` hypervisor application (included in the Clear
123
+ Linux release) on the EFI partition with:
139
124
125
+ .. code-block :: none
126
+
127
+ # mkdir /mnt/EFI/acrn
128
+ # cp /usr/share/acrn/acrn.efi /mnt/EFI/acrn/
140
129
141
- #. Copy the ``acrn.efi `` hypervisor application (included in the Clear
142
- Linux release) to the EFI partition.
130
+ #. Configure the EFI firmware to boot the ACRN hypervisor by default
131
+
132
+ The ACRN hypervisor (``acrn.efi ``) is an EFI executable
133
+ loaded directly by the platform EFI firmware. It then in turns loads the
134
+ Service OS bootloader. Use the ``efibootmgr `` utility to configure the EFI
135
+ firmware and add a new entry that loads the ACRN hypervisor.
143
136
144
137
.. code-block :: none
145
138
146
- # cp /usr/share/acrn/acrn.efi /mnt/EFI/org.clearlinux
139
+ # efibootmgr -c -l "\EFI\acrn\acrn.efi" -d /dev/sda1 -p 1 -L ACRN
140
+ # cd /mnt/EFI/org.clearlinux/
141
+ # cp bootloaderx64.efi bootloaderx64_origin.efi
142
+
143
+ .. note::
144
+ Be aware that a Clearlinux update that includes a kernel upgrade will
145
+ reset this. A Clearlinux update could happen automatically (if you have
146
+ not disabled it as described above), if you later install a new
147
+ bundle to your system or simply if you decide to trigger an update
148
+ manually. Whenever that happens, double-check the platform boot order
149
+ using ``efibootmgr -v`` and modify it if needed.
147
150
148
- #. Create a boot entry for ACRN. It must contain these settings:
151
+ #. Create a boot entry for the ACRN Service OS by copying a provided ``acrn.conf ``
152
+ and editing it to account for the kernel versions noted in a previous step.
153
+
154
+ It must contain these settings:
149
155
150
156
+-----------+----------------------------------------------------------------+
151
157
| Setting | Description |
152
158
+===========+================================================================+
153
159
| title | Text to show in the boot menu |
154
160
+-----------+----------------------------------------------------------------+
155
- | efi | Executable EFI image |
161
+ | linux | Linux kernel for the Service OS ( \* -sos) |
156
162
+-----------+----------------------------------------------------------------+
157
- | options | Options to pass to the EFI program or kernel boot parameters |
163
+ | options | Options to pass to the Service OS kernel ( kernel parameters) |
158
164
+-----------+----------------------------------------------------------------+
159
165
160
- A sample `acrn.conf
166
+ A starter acrn.conf configuration file is included in the Clear Linux release and is
167
+ also available in the acrn-hypervisor GitHub repo as `acrn.conf
161
168
<https://github.com/projectacrn/acrn-hypervisor/tree/master/bsp/uefi/clearlinux/acrn.conf> `__
162
- is included in the Clear Linux release, and is also available in the
163
- acrn-hypervisor GitHub repo (in the bsp/uefi/clearlinux
164
- folder) as shown here:
169
+ as shown here:
165
170
166
171
.. literalinclude :: ../../acrn-hypervisor/bsp/uefi/clearlinux/acrn.conf
167
172
:caption: acrn-hypervisor/bsp/uefi/clearlinux/acrn.conf
168
173
169
- Copy the ``acrn.conf `` file to the EFI partition we mounted earlier:
174
+ On the NUC, copy the ``acrn.conf `` file to the EFI partition we mounted earlier:
170
175
171
176
.. code-block :: none
172
177
173
178
# cp /usr/share/acrn/demo/acrn.conf /mnt/loader/entries/
174
179
175
- If you're following
176
- the instructions above, the partition (`` root= /dev/sda3 ``) and image
177
- locations used in the ``arcn.conf `` file will match .
180
+ You will need to edit this file to adjust the kernel version (`` linux `` section)
181
+ and also insert the `` PARTUUID `` of your `` /dev/sda3 `` partition
182
+ (`` root=PARTUUID=<><UUID of rootfs partition> ``) in the ``options `` section .
178
183
179
- .. note ::
180
- Please make sure that the kernel version and root filesystem image (``clear-<version>-kvm.img ``)
181
- match your set-up.
184
+ Use ``blkid `` to find out what your ``/dev/sda3 `` ``PARTUUID `` value is.
182
185
183
186
#. Add a timeout period for Systemd-Boot to wait, otherwise it will not
184
187
present the boot menu and will always boot the base Clear Linux
185
- kernel.
186
188
187
189
.. code-block :: none
188
190
189
191
# clr-boot-manager set-timeout 20
190
192
# clr-boot-manager update
191
193
192
- #. Reboot and select "The ACRN Hypervisor " to boot, as shown in
194
+ #. Reboot and select "The ACRN Service OS " to boot, as shown in
193
195
:numref: `gsg-bootmenu `:
194
196
195
197
.. figure :: images/gsg-bootmenu.png
196
198
:align: center
197
199
:name: gsg-bootmenu
198
200
199
- ACRN Hypervisor Boot menu
201
+ ACRN Service OS Boot menu
200
202
201
203
#. After booting up the ACRN hypervisor, the Service OS will be launched
202
204
automatically by default, as shown in :numref: `gsg-sos-console `:
@@ -240,35 +242,38 @@ directory. Run it to create a network bridge:
240
242
Set up Reference UOS
241
243
====================
242
244
243
- #. Download the pre-built reference Clear Linux UOS image.
245
+ #. On your NUC, download the pre-built reference Clear Linux UOS image into your
246
+ (root) home directory:
244
247
245
248
.. code-block :: none
246
249
247
- # curl -O https://download.clearlinux.org/releases/21260/clear/clear-21260-kvm.img.xz
250
+ # cd ~
251
+ # curl -O https://download.clearlinux.org/releases/22140/clear/clear-22140-kvm.img.xz
248
252
249
253
.. note ::
250
254
In case you want to use or try out a newer version of Clear Linux as the UOS, you can
251
255
download the latest from http://download.clearlinux.org/image. Make sure to adjust the steps
252
256
described below accordingly (image file name and kernel modules version).
253
257
254
- #. Uncompress it.
258
+ #. Uncompress it:
255
259
256
260
.. code-block :: none
257
261
258
- # unxz clear-21260 -kvm.img.xz
262
+ # unxz clear-22140 -kvm.img.xz
259
263
260
- #. Deploy the UOS kernel modules to UOS virtual disk image
264
+ #. Deploy the UOS kernel modules to UOS virtual disk image (note: you'll need to use
265
+ the same **standard ** image version number noted in step 1 above):
261
266
262
267
.. code-block :: none
263
268
264
- # losetup -f -P --show /root/clear-21260-kvm.img
265
- # ls /dev/loop0*
269
+ # losetup -f -P --show /root/clear-22140-kvm.img
266
270
# mount /dev/loop0p3 /mnt
267
- # cp -r /usr/lib/doc/modules/4.14.23-19 .pk414-standard /mnt/lib/doc/modules/
271
+ # cp -r /usr/lib/doc/modules/4.14.34-28 .pk414-standard /mnt/lib/doc/modules/
268
272
# umount /mnt
269
273
# sync
270
274
271
- #. Run the launch_uos.sh script to launch the UOS.
275
+ #. Edit and Run the launch_uos.sh script to launch the UOS.
276
+
272
277
A sample `launch_uos.sh
273
278
<https://github.com/projectacrn/acrn-devicemodel/tree/master/samples/launch_uos.sh> `__
274
279
is included in the Clear Linux release, and
@@ -282,14 +287,14 @@ Set up Reference UOS
282
287
283
288
.. note ::
284
289
In case you have downloaded a different Clear Linux image than the one above
285
- (``clear-21260 -kvm.img.xz ``), you will need to modify the Clear Linux file name
290
+ (``clear-22140 -kvm.img.xz ``), you will need to modify the Clear Linux file name
286
291
and version number highlighted above (the ``-s 3,virtio-blk `` argument) to match
287
292
what you have downloaded above. Likewise, you may need to adjust the kernel file
288
293
name on the second line highlighted (check the exact name to be used using:
289
294
``ls /usr/lib/doc/kernel/org.clearlinux*-standard* ``).
290
295
291
296
By default, the script is located in the ``/usr/share/acrn/demo/ ``
292
- directory. Run it directly to launch the User OS:
297
+ directory. You can edit it there, and then run it to launch the User OS:
293
298
294
299
.. code-block :: none
295
300
0 commit comments