<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/meta-el-nfv-access.git/classes, branch master</title>
<subtitle>[no description]</subtitle>
<id>https://git.enea.com/cgit/linux/meta-el-nfv-access.git/atom?h=master</id>
<link rel='self' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/'/>
<updated>2021-05-27T07:45:38+00:00</updated>
<entry>
<title>OSTree /boot dir: Remove unused artifacts</title>
<updated>2021-05-27T07:45:38+00:00</updated>
<author>
<name>Alexandru Avadanii</name>
<email>Alexandru.Avadanii@enea.com</email>
</author>
<published>2021-04-26T12:04:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=580595398d36da3cde87046b3b03b9c2c3831249'/>
<id>urn:sha1:580595398d36da3cde87046b3b03b9c2c3831249</id>
<content type='text'>
OSTree handles the contents of /boot separately from the rest of the
filesystem, see [1].
By default, upstream yocto rootfs generation stores the following
artifacts in /boot:
- kernel-image (bzImage) as /boot/bzImage-...;
- multiple packages that deploy grub.cfg, grubenv and EFI binaries:
  * dpkg -S /boot/efi/EFI/BOOT
    shim, seloader, ovmf-pkcs7-efi, grub-efi, grub-bootconf, efitools

However, none of these are ever used in Enea Edge, due to the way our
initial installation and subsequent upgrade work:
* live image building copies the kernel image from yocto deploy dir,
  EFI binaries from rootfs /boot (this patch changes this to also
  copy from the yocto deploy dir "bootloader" dir for uniformity) to
  the root of the hddimg image;
* Enea Edge Installer (via utils.sh) creates the ESP partition
  and copies all artifacts from hddimg to ESP under /EFI/BOOT [2];
* (currently) subsequent upgrades do _not_ update the contents of the
  ESP /EFI/BOOT directory after initial installation;
* subsequent upgrades copy the kernel and ostree-initramfs from OSTree
  rootfs (from /usr/lib/modules where ostree-kernel package resides)
  to the ESP for SELoader validation;

This flow leaves unused (duplicate) artifacts in the following path:
  /ostree/boot.x/poky/&lt;poky hash&gt;/0/boot/

While the kernel-image package can be omitted from installation, since
ostree-kernel package already installs the same binaries in
/usr/lib/modules (where OSTree will look for it), the rest of the
packages (shim, seloader etc.) also install other files to the rootfs
(e.g. CLI tools) and/or are used by the live image (hddimg) build
process as sources when copying said artifacts to the hddimg image; so
we can't simply skip installing them inside the rootfs.
Also, we want non-SOTA artifacts (e.g. rootfs.ext4) to still contain
these artifacts.

So the only sensible solution to avoiding confusion and removing
unused artifacts from OSTree images is to remove them right before
creating the OSTree image.

While at it, add some ENEA-specific comment markers to our prepend/
append fragments to make them stand out.

[1] https://github.com/ostreedev/ostree/blob/v2020.8/docs/\
    atomic-upgrades.md#the-ostreeboot-directory
[2] http://sestogerrit02/cgit/linux/meta-enea-virtualization.git/tree/
    recipes-enea/nfv-installer/nfv-installer/utils.sh?h=rocko#n230

Change-Id: I470c1c3d19f301cae4b8fbe184aa2906d4a25ddf
Signed-off-by: Alexandru Avadanii &lt;Alexandru.Avadanii@enea.com&gt;
</content>
</entry>
<entry>
<title>grub: Fix duplicate/unused grubx64.efi, cleanup</title>
<updated>2021-05-26T07:23:27+00:00</updated>
<author>
<name>Alexandru Avadanii</name>
<email>Alexandru.Avadanii@enea.com</email>
</author>
<published>2021-04-26T12:03:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=20e1f95b49cb2dfb321b770b260b0d82d49fe699'/>
<id>urn:sha1:20e1f95b49cb2dfb321b770b260b0d82d49fe699</id>
<content type='text'>
1. EFI_PREFIX: Fix duplicate grubx64.efi binaries by aligning paths:
   * by default, upstream meta-oe and meta-secure-core both install
     grubx64.efi, but in different locations (/boot/EFI/BOOT vs
     /boot/efi/EFI/BOOT) unless we explicitely override some vars to
     align the 2 paths; use the old behavior (/boot/efi/EFI/BOOT),
     as meta-secure-core has multiple recipes that reference it, while
     meta-oe allows changing the path via a single var override;
   * note that in an OSTree deployment, these paths don't even exist
     on target, we explicity install grubx64.efi during Enea Edge
     installation by copying grubx64.efi from /EFI/BOOT in hddimg;

2. live-vm-common: use ${EFI_FILES_PATH} instead of hardcoding it;

3. core-image-minimal-initramfs, enea-nfv-access: Blacklist
   grub-common-extras package on x86-64 machines if OSTree is used;

Depends-On: I703b53fd09c5ed75731375414f3e711ec3dadc3e
Change-Id: I3735bc004ece62f94172108f2e7ed4596942deea
Signed-off-by: Alexandru Avadanii &lt;Alexandru.Avadanii@enea.com&gt;
</content>
</entry>
<entry>
<title>installer: grub: merge serial/gfx boot entries</title>
<updated>2021-05-21T15:17:02+00:00</updated>
<author>
<name>Alexandru Avadanii</name>
<email>Alexandru.Avadanii@enea.com</email>
</author>
<published>2021-04-29T14:30:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=5f44786c4370a77b7724df474b017c19914d99e3'/>
<id>urn:sha1:5f44786c4370a77b7724df474b017c19914d99e3</id>
<content type='text'>
- drop our class override that basically reverted the boot menu entry
  order and used to make serial the first (default) boot entry instead
  of graphical;
- unset GRUB_GFXSERIAL that creates 2 boot entries instead of one;
- extend APPEND to contain both tty0 (graphical) and ttyS0 (serial):
  * ttyS0 is last, so it has priority for selection as /dev/console;

Change-Id: I9be029bfea00d9aca61527046fedbe30e7ec58c2
Signed-off-by: Alexandru Avadanii &lt;Alexandru.Avadanii@enea.com&gt;
</content>
</entry>
<entry>
<title>classes/sota: INITRAMFS_TYPES: s/ext4/cpio/</title>
<updated>2021-04-12T13:21:34+00:00</updated>
<author>
<name>Alexandru Avadanii</name>
<email>Alexandru.Avadanii@enea.com</email>
</author>
<published>2021-03-21T12:57:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=4caf6e53092b84f37183e696d43bf16c8c9bc112'/>
<id>urn:sha1:4caf6e53092b84f37183e696d43bf16c8c9bc112</id>
<content type='text'>
Upstream meta-updater switched from initrd to initramfs in [1], so
the image format changed from ext4.gz to cpio.gz.

[1] https://github.com/advancedtelematic/meta-updater/commit/212d71d2

Change-Id: Ibb1239eeba319877624fc76209f733862f52cb35
Signed-off-by: Alexandru Avadanii &lt;Alexandru.Avadanii@enea.com&gt;
</content>
</entry>
<entry>
<title>classes/override_grub* sync with upstream renames</title>
<updated>2021-04-12T12:03:51+00:00</updated>
<author>
<name>Alexandru Avadanii</name>
<email>Alexandru.Avadanii@enea.com</email>
</author>
<published>2021-03-21T17:15:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=a66a367e9656f0f4e2f9e9f8932714cf9bee1725'/>
<id>urn:sha1:a66a367e9656f0f4e2f9e9f8932714cf9bee1725</id>
<content type='text'>
While at it, replace some hardcoded p7b extenstions with ${SB_FILE_EXT}
and vmlinuz references with the appropiate variable (upstream no longer
renames bzImage to vmlinuz in ISO root after [1]).

[1] https://git.yoctoproject.org/cgit.cgi/poky/commit/?id=b6e36c01977

Change-Id: I5ce414a2f281ff2f1aeb0e26f35608cd8750855d
Signed-off-by: Alexandru Avadanii &lt;Alexandru.Avadanii@enea.com&gt;
Signed-off-by: Adrian Dudau &lt;adrian.dudau@enea.com&gt;
</content>
</entry>
<entry>
<title>classes: Rebase override_image_types_{ota,ostree}</title>
<updated>2021-04-09T11:20:11+00:00</updated>
<author>
<name>Alexandru Avadanii</name>
<email>Alexandru.Avadanii@enea.com</email>
</author>
<published>2021-03-29T17:09:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=a14950444f22e7aaed1cce3c061c860572cf262f'/>
<id>urn:sha1:a14950444f22e7aaed1cce3c061c860572cf262f</id>
<content type='text'>
- override_image_types_ostree.inc is no longer required;
- override_image_types_ota.inc is mostly superseded by upstream, except
  the creation of /boot/grub as a symlink to /boot/loader
  (note that /boot/grub2 is a real dir with /boot/grub2/grub.cfg being
  a symlink to /boot/loader/grub.cfg - it would be quite
  complicated to override the whole IMAGE_CMD_ota just to keep
  symlinking the parent dir instead of grub.cfg directly); /boot/grub
  should be a symlink so that /boot/grub/grubenv also points to
  /boot/loader/grubenv); fold its contents into
  enea-nfv-access-host-common.inc as it doesn't override a class anymore

Note: Previously, OSTree did not follow symlinks, so the symlink
      /boot/grub2/grub.cfg was being overwritten with a real file,
      this is no longer an issue.

Change-Id: I38ec2b3a791ef7068b97caa49010eee62b7f4aee
Signed-off-by: Alexandru Avadanii &lt;Alexandru.Avadanii@enea.com&gt;
Signed-off-by: Adrian Dudau &lt;adrian.dudau@enea.com&gt;
</content>
</entry>
<entry>
<title>Upgrade to gatesgarth</title>
<updated>2021-03-25T11:27:30+00:00</updated>
<author>
<name>Adrian Dudau</name>
<email>adrian.dudau@enea.com</email>
</author>
<published>2021-03-24T10:58:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=5f980c14dafb466e1d71e0b6e7487aa522ade9f9'/>
<id>urn:sha1:5f980c14dafb466e1d71e0b6e7487aa522ade9f9</id>
<content type='text'>
This is an initial commit, containing quick fixes and hacks to allow
building the images. All these issues will be re-evaluated and fixed
properly in their own commits.

Signed-off-by: Adrian Dudau &lt;adrian.dudau@enea.com&gt;
</content>
</entry>
<entry>
<title>grub: Fix backwards compatibility with OSTree</title>
<updated>2020-12-17T13:59:32+00:00</updated>
<author>
<name>Alexandru Avadanii</name>
<email>Alexandru.Avadanii@enea.com</email>
</author>
<published>2020-12-17T13:59:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=70848fd5efb411cd83ad157323fbf796d688bb56'/>
<id>urn:sha1:70848fd5efb411cd83ad157323fbf796d688bb56</id>
<content type='text'>
Before NFVA 2.3.0, OSTree only checked for the existence of
/boot/grub2/grub.cfg, skipping creating grub.cfg if that file was not
present.
In NFVA 2.3.0, only /boot/grub/grub.cfg is created, leading to issues
when trying to downgrade to an older NFVA release.

To maintain backwards compatibility with OSTree versions that only
check the old path, create both /boot/{grub,grub2} as symlinks to the
loader directory managed by OSTree.

Signed-off-by: Alexandru Avadanii &lt;Alexandru.Avadanii@enea.com&gt;
Change-Id: Ic2c89930794e4c9d3ee3b2468d1331e5d7f63834
</content>
</entry>
<entry>
<title>grub: Fix loader link, unify grub.cfg locations</title>
<updated>2020-09-14T09:37:41+00:00</updated>
<author>
<name>Alexandru Avadanii</name>
<email>Alexandru.Avadanii@enea.com</email>
</author>
<published>2020-09-04T13:24:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=55b49a162cc4e871106f6e57108581a92ae35832'/>
<id>urn:sha1:55b49a162cc4e871106f6e57108581a92ae35832</id>
<content type='text'>
1. Fix an obviously broken link created during installation

This led to issues creating/editing the grubenv file during NFVA
installation calls to `grub-mkconfig`.
These errors were not observed before, since stderr was not logged
during the installation.
Also, the link was fixed later on, so subsequent calls to grub-*
utilities no longer complained about it; the error only happened
during the NFVA installation.

2. Unify expected locations of grub.cfg

Previously, there were 3 possible locations of grub.cfg used
throughout the layers/scripts:
- /boot/loader/grub.cfg - the proper location, used by NFVA installer
  components, as well as ostree related tooling;
- /boot/grub/grub.cfg - used in some recipes, but not present on the
  board currently. Also the expected default location of our current
  grub-* utilites, since we build grub without an explicit
  `--with-grubdir` configure argument, which defaults (guessing) to
  the `PACKAGE` name, in our case `grub` (and not `grub2`);
- /boot/grub2/grub.cfg - used in OTA image scripts by linking it to
  /boot/loader/grub.cfg - however the link is later converted into
  a real file, ending up duplicating the real grub.cfg (although they
  are identical content-wise, they might confuse the user);

To settle this confusion, we will keep only /boot/loader/grub.cfg as
the true configuration file and convert /boot/grub2 to a symlink
pointing at /boot/loader, while also renaming it to /boot/grub.
This has the benefit of "fixing" all grub-* tools which try to write
their configuration files to /boot/grub. An alternative for that would
be building grub2 with the configure flag `--with-grubdir=loader`, but
that might break other things, so a symlink for the traditional
/boot/grub is safer.

Before creating this link, `grub-editenv list` would not work without
explicitly providing the filepath of the `/boot/loader/grubenv` file,
which might not be obvious for the end user.
Also, before this link, `grub-mkconfig` required explicitly setting the
`-p` (prefix) to '/' while running on the target.
Both of these issues will be fixed with the new link.

Since our ostree version (2018.7) is quite old, it requires one backport
for it to also check for /boot/grub/grub.cfg and not only
/boot/grub2/grub.cfg. The backport will be handled in the
meta-enea-virtualiation layer, hence this change's dependency.

Signed-off-by: Alexandru Avadanii &lt;Alexandru.Avadanii@enea.com&gt;
Depends-on: I6bdc80e08a272e1534dd63717348bfaa50807d93
Change-Id: If8a61c89200414922a3f36e6c8fca58d7d3b6495
</content>
</entry>
<entry>
<title>Make the serial console as the first choice in GRUB and SYSLINUX</title>
<updated>2019-08-09T14:31:55+00:00</updated>
<author>
<name>Gabriel Ionescu</name>
<email>Gabriel.Ionescu@enea.com</email>
</author>
<published>2019-08-09T14:30:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.enea.com/cgit/linux/meta-el-nfv-access.git/commit/?id=a14b119c235cfe094236ca9cddf96a9810229e18'/>
<id>urn:sha1:a14b119c235cfe094236ca9cddf96a9810229e18</id>
<content type='text'>
Change-Id: I146aafd422d0f99b25ef222380e053b08239c02f
</content>
</entry>
</feed>
